generic image
Processing...
  • Games
  • Catalog
  • Develop
  • Robux
  • Search in Players
  • Search in Games
  • Search in Catalog
  • Search in Groups
  • Search in Library
  • Log In
  • Sign Up
  • Games
  • Catalog
  • Develop
  • Robux
   
ROBLOX Forum » Game Creation and Development » Scripting Helpers
Home Search
 

Re: problem with loadstring

Previous Thread :: Next Thread 
breuning is not online. breuning
Joined: 30 Oct 2008
Total Posts: 4268
10 Jan 2014 10:09 AM
loadstring("return _G.DataBase['Weapons']['M1891/30']")()

returns nil
this table is existent and the index names are right
help

function:

function _GETITEM(...)
local tabofentr = {...}
local str = "return _G.DataBase"
for _,v in next, tabofentr do
if _ > 1 then
print(v)
str = str.."['"..v.."']"
end
end
if str ~= "return _G.DataBase" then
print("loadstring") -- prints
print(str) -- this is right
return loadstring(str)()
else
print("nil")
return nil
end
end
Report Abuse
YEGGOR is not online. YEGGOR
Joined: 02 Apr 2013
Total Posts: 1150
10 Jan 2014 10:18 AM
sorry man i gtg to school now
Report Abuse
breuning is not online. breuning
Joined: 30 Oct 2008
Total Posts: 4268
10 Jan 2014 10:19 AM
rly
got time to criticize me but not to hlp me

not cool man
not cool
Report Abuse
breuning is not online. breuning
Joined: 30 Oct 2008
Total Posts: 4268
10 Jan 2014 10:26 AM
i hate it when my own scripting level surpasses scripting helper's forum level but is lower than scripter's forum level
Report Abuse
breuning is not online. breuning
Joined: 30 Oct 2008
Total Posts: 4268
10 Jan 2014 10:46 AM
got it:

i had this as OnServerInvoke:

function script._GETDBITEM.OnServerInvoke(...)
if not _GETITEM(...) == nil then
return _GETITEM(...)
else
return _ERROR(1)
end
end

and now I did

function script._GETDBITEM.OnServerInvoke(...)
if _GETITEM(...) then
return _GETITEM(...)
else
return _ERROR(1)
end
end


works fine
Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripting Helpers
   
 
   
  • About Us
  • Jobs
  • Blog
  • Parents
  • Help
  • Terms
  • Privacy

©2017 Roblox Corporation. Roblox, the Roblox logo, Robux, Bloxy, and Powering Imagination are among our registered and unregistered trademarks in the U.S. and other countries.



Progress
Starting Roblox...
Connecting to Players...
R R

Roblox is now loading. Get ready to play!

R R

You're moments away from getting into the game!

Click here for help

Check Remember my choice and click Launch Application in the dialog box above to join games faster in the future!

Gameplay sponsored by:
Loading 0% - Starting game...
Get more with Builders Club! Join Builders Club
Choose Your Avatar
I have an account
generic image