BosenXD Posted May 26, 2020 Share Posted May 26, 2020 Hello i learning to create a basic script for a game. So i created a file it works correctly and below is my code. gg.searchNumber("559910;4800", gg.TYPE_DWORD, false, gg.SIGN_EQUAL, 0, -1) for i, v in ipairs(t) do if v.flags == gg.TYPE_DWORD then v.value = "4800" v.freeze = true end end gg.addListItems(t) t = nil So how do i seach for multiple values and freeze it i did like below one but getting error. gg.searchNumber("559910;4800", gg.TYPE_DWORD, false, gg.SIGN_EQUAL, 0, -1) for i, v in ipairs(t) do if v.flags == gg.TYPE_DWORD then v.value = "4800" v.freeze = true end end gg.addListItems(t) t = nil gg.searchNumber("559910;6800", gg.TYPE_DWORD, false, gg.SIGN_EQUAL, 0, -1) for i, v in ipairs(t) do if v.flags == gg.TYPE_DWORD then v.value = "6800" v.freeze = true end end gg.addListItems(t) t = nil Link to comment Share on other sites More sharing options...
BosenXD Posted May 26, 2020 Author Share Posted May 26, 2020 Also i tried to record a script and it works fine but if i run that recorded script game crashes. So any idea what's happening in my script ? Link to comment Share on other sites More sharing options...
Administrators Enyby Posted May 26, 2020 Administrators Share Posted May 26, 2020 I have ten assumptions about what's wrong there. Any idea which one is right for you? Link to comment Share on other sites More sharing options...
BosenXD Posted May 26, 2020 Author Share Posted May 26, 2020 1 hour ago, Enyby said: I have ten assumptions about what's wrong there. Any idea which one is right for you? Can you tell me the problem were i can fix game crashing. Also my every posting is going for pending approval Is this for everyone? Link to comment Share on other sites More sharing options...
Question
BosenXD
Hello i learning to create a basic script for a game. So i created a file it works correctly and below is my code.
gg.searchNumber("559910;4800", gg.TYPE_DWORD, false, gg.SIGN_EQUAL, 0, -1)
for i, v in ipairs(t) do
if v.flags == gg.TYPE_DWORD then
v.value = "4800"
v.freeze = true
end
end
gg.addListItems(t)
t = nil
So how do i seach for multiple values and freeze it i did like below one but getting error.
gg.searchNumber("559910;4800", gg.TYPE_DWORD, false, gg.SIGN_EQUAL, 0, -1)
for i, v in ipairs(t) do
if v.flags == gg.TYPE_DWORD then
v.value = "4800"
v.freeze = true
end
end
gg.addListItems(t)
t = nil
gg.searchNumber("559910;6800", gg.TYPE_DWORD, false, gg.SIGN_EQUAL, 0, -1)
for i, v in ipairs(t) do
if v.flags == gg.TYPE_DWORD then
v.value = "6800"
v.freeze = true
end
end
gg.addListItems(t)
t = nil
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.