- 1
- 0
how to fix this error on monetloader
[13: 47: 47.715546] (system) Loading script: '/storage/emulated/0/Android/media/ro.alyn_sampmobile.game/monetloader/GetCrate v1.1.0.lua'...
[13: 47: 47.810601] (error) GetCrate: ... /ro.alyn_sampmobile.game/monetloader/GetCrate v1.1.0.lua: 37: attempt to index local 'new_config' (a nil value)
stack trackback:
.../ro.alyn_sampmobile.game/monetloader/GetCrate v1.1.0.lua: 37: in main chunk
[13: 47: 47.810667] (error) GetCrate: Script died due to an error.
[CODE lang = "lua" title = "getcrate"] require 'moonloader'
require 'sampfuncs'
local sampev = require 'lib.samp.events'
local inicfg = require 'inicfg'
dir = getWorkingDirectory () .. "\\ config\\"
config = dir .. "getcrate.ini"
if not doesDirectoryExist (dir) then createDirectory (dir) end
if not doesFileExist (config) then
print ("The script failed to load. Read the instructions and make sure to install correctly. ")
thisScript (): unload ()
end
directIni = config
mainIni = inicfg.load (nil, directIni)
script_name ("getcrate") [/ CODE]
[13: 47: 47.715546] (system) Loading script: '/storage/emulated/0/Android/media/ro.alyn_sampmobile.game/monetloader/GetCrate v1.1.0.lua'...
[13: 47: 47.810601] (error) GetCrate: ... /ro.alyn_sampmobile.game/monetloader/GetCrate v1.1.0.lua: 37: attempt to index local 'new_config' (a nil value)
stack trackback:
.../ro.alyn_sampmobile.game/monetloader/GetCrate v1.1.0.lua: 37: in main chunk
[13: 47: 47.810667] (error) GetCrate: Script died due to an error.
[CODE lang = "lua" title = "getcrate"] require 'moonloader'
require 'sampfuncs'
local sampev = require 'lib.samp.events'
local inicfg = require 'inicfg'
dir = getWorkingDirectory () .. "\\ config\\"
config = dir .. "getcrate.ini"
if not doesDirectoryExist (dir) then createDirectory (dir) end
if not doesFileExist (config) then
print ("The script failed to load. Read the instructions and make sure to install correctly. ")
thisScript (): unload ()
end
directIni = config
mainIni = inicfg.load (nil, directIni)
script_name ("getcrate") [/ CODE]