so the idea is, when i check for example FoV it will first search the value and save it to the table and then automatically check the "[DO NOT CHECK] FoV Value",
and now i want to press fov again and it will check if "[DO NOT CHECK] FoV Value" is checked and it will proceed to the FoV() function
but i end up with an error and i dont know how to fix it
"Script ended:
Script error: luaj.LuaError: load /storage/emulated/0/Download/Lua/Scripts/My Scripts/CriticalOpsTrainer.lua: luaj.LuaError: /storage/emulated/0/Download/Lua/Scripts/My Scripts/CriticalOpsTrainer.lua:87
`pm[4] == true`
syntax error near '=='
at luaj.LuaValue.error(LuaValue.java:1083)
at luaj.Globals.loadfile(Globals.java:219)
at android.ext.Script.runScript(Script.java:5244)
at android.ext.Script$ScriptThread.run(Script.java:5081)
Caused by: luaj.LuaError: /storage/emulated/0/Download/Lua/Scripts/My Scripts/CriticalOpsTrainer.lua:87
`pm[4] == true`
syntax error near '=='
at luaj.compiler.LexState.lexerror(LexState.java:289)
at luaj.compiler.LexState.syntaxerror(LexState.java:293)
at luaj.compiler.LexState.check_condition(LexState.java:878)
at luaj.compiler.LexState.exprstat(LexState.java:2045)
at luaj.compiler.LexState.statement(LexState.java:2139)
at luaj.compiler.LexState.statlist(LexState.java:2156)
at luaj.compiler.LexState.body(LexState.java:1315)
at luaj.compiler.LexState.funcstat(LexState.java:2029)
at luaj.compiler.LexState.statement(LexState.java:2112)
at luaj.compiler.LexState.statlist(LexState.java:2156)
at luaj.compiler.LexState.block(LexState.java:1655)
at luaj.compiler.LexState.whilestat(LexState.java:1798)
at luaj.compiler.LexState.statement(LexState.java:2094)
at luaj.compiler.LexState.statlist(LexState.java:2156)
at luaj.compiler.LexState.mainfunc(LexState.java:2172)
at luaj.compiler.LuaC$CompileState.luaY_parser(LuaC.java:129)
at luaj.compiler.LuaC.compile(LuaC.java:99)
at luaj.Globals.compilePrototype(Globals.java:278)
at luaj.Globals.loadPrototype(Globals.java:265)
at luaj.Globals.load(Globals.java:231)
at luaj.Globals.loadfile(Globals.java:213)
... 2 more"
can someone help me or Improove the code?
thanks in advance.
"function playerMenu()
local pm = gg.prompt({
"FoV",
"Crosshair Always Visible",
"Chams",
"[DO NOT CHECK] FoV Value",
"[DO NOT CHECK] Crosshair Value",
"[DO NOT CHECK] Chams Value"
}, nil, {"checkbox", "checkbox", "checkbox", "checkbox", "checkbox", "checkbox"},{[1]=false, [2]=false, [3]=false, [4]=false, [5]=false, [6]=false})
if pm[1] == true
and
pm[4] == false
then
fovS()
end
if pm[1] == true
and
pm[4] == true
then
FoV()
end
if pm[2] == true
and
pm[5] == false
then
crosshairS()
end
if pm[2] == true
and
pm[5] == true
then
crosshair()
end
if pm[3] == true
and
pm[6] == false
then
chamsS()
end
if pm[3] == true
and
pm[6] == true
then
Chams()
end
UI =-1
end
function fovS()
gg.toast("test")
pm[4] == true
playerMenu()
end
function FoV()
gg.toast("test")
end
function crosshairS()
gg.toast("test")
pm[5] == true
playerMenu()
end
function crosshair()
gg.toast("test")
end
function chamsS()
gg.toast("test")
pm[6] == true
playerMenu()
end
We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.
Question
YeetMeister
hello,
i need help with this function here
so the idea is, when i check for example FoV it will first search the value and save it to the table and then automatically check the "[DO NOT CHECK] FoV Value",
and now i want to press fov again and it will check if "[DO NOT CHECK] FoV Value" is checked and it will proceed to the FoV() function
but i end up with an error and i dont know how to fix it
"Script ended:
Script error: luaj.LuaError: load /storage/emulated/0/Download/Lua/Scripts/My Scripts/CriticalOpsTrainer.lua: luaj.LuaError: /storage/emulated/0/Download/Lua/Scripts/My Scripts/CriticalOpsTrainer.lua:87
`pm[4] == true`
syntax error near '=='
at luaj.LuaValue.error(LuaValue.java:1083)
at luaj.Globals.loadfile(Globals.java:219)
at android.ext.Script.runScript(Script.java:5244)
at android.ext.Script$ScriptThread.run(Script.java:5081)
Caused by: luaj.LuaError: /storage/emulated/0/Download/Lua/Scripts/My Scripts/CriticalOpsTrainer.lua:87
`pm[4] == true`
syntax error near '=='
at luaj.compiler.LexState.lexerror(LexState.java:289)
at luaj.compiler.LexState.syntaxerror(LexState.java:293)
at luaj.compiler.LexState.check_condition(LexState.java:878)
at luaj.compiler.LexState.exprstat(LexState.java:2045)
at luaj.compiler.LexState.statement(LexState.java:2139)
at luaj.compiler.LexState.statlist(LexState.java:2156)
at luaj.compiler.LexState.body(LexState.java:1315)
at luaj.compiler.LexState.funcstat(LexState.java:2029)
at luaj.compiler.LexState.statement(LexState.java:2112)
at luaj.compiler.LexState.statlist(LexState.java:2156)
at luaj.compiler.LexState.block(LexState.java:1655)
at luaj.compiler.LexState.whilestat(LexState.java:1798)
at luaj.compiler.LexState.statement(LexState.java:2094)
at luaj.compiler.LexState.statlist(LexState.java:2156)
at luaj.compiler.LexState.mainfunc(LexState.java:2172)
at luaj.compiler.LuaC$CompileState.luaY_parser(LuaC.java:129)
at luaj.compiler.LuaC.compile(LuaC.java:99)
at luaj.Globals.compilePrototype(Globals.java:278)
at luaj.Globals.loadPrototype(Globals.java:265)
at luaj.Globals.load(Globals.java:231)
at luaj.Globals.loadfile(Globals.java:213)
... 2 more"
can someone help me or Improove the code?
thanks in advance.
"function playerMenu()
local pm = gg.prompt({
"FoV",
"Crosshair Always Visible",
"Chams",
"[DO NOT CHECK] FoV Value",
"[DO NOT CHECK] Crosshair Value",
"[DO NOT CHECK] Chams Value"
}, nil, {"checkbox", "checkbox", "checkbox", "checkbox", "checkbox", "checkbox"},{[1]=false, [2]=false, [3]=false, [4]=false, [5]=false, [6]=false})
if pm[1] == true
and
pm[4] == false
then
fovS()
end
if pm[1] == true
and
pm[4] == true
then
FoV()
end
if pm[2] == true
and
pm[5] == false
then
crosshairS()
end
if pm[2] == true
and
pm[5] == true
then
crosshair()
end
if pm[3] == true
and
pm[6] == false
then
chamsS()
end
if pm[3] == true
and
pm[6] == true
then
Chams()
end
UI =-1
end
function fovS()
gg.toast("test")
pm[4] == true
playerMenu()
end
function FoV()
gg.toast("test")
end
function crosshairS()
gg.toast("test")
pm[5] == true
playerMenu()
end
function crosshair()
gg.toast("test")
end
function chamsS()
gg.toast("test")
pm[6] == true
playerMenu()
end
function Chams()
gg.toast("test")
end"
Link to comment
Share on other sites
3 answers to this question
Recommended Posts
Archived
This topic is now archived and is closed to further replies.