Jump to content

Recommended Posts

  • Administrators
Posted
  On 7/20/2017 at 10:32 PM, circleous said:

Any documentation to GG script library yet?

Expand  

Will be in future. Now only short help in first post and button help in execute script dialog in latest test builds/ next releases.

Posted (edited)
  Reveal hidden contents
  Reveal hidden contents

An example for File I/O operation still primitive, but you could use your own wrapper for that. since GG will add lua import in future so that table.save and table.load can be used thus the complex File I/O wrapper somewhat not needed.

Edited by circleous
  • Administrators
Posted
  On 7/21/2017 at 12:44 AM, circleous said:

Please add somehthing like Kill the script process.

Expand  

Already present if UI open. Stop button at left top corner.

 

scr_1500498032.jpg

_______________________________________________
added 3 minutes later
  On 7/21/2017 at 2:48 AM, circleous said:

since GG will add lua import in future so that table.save and table.load can be used thus the complex File I/O wrapper somewhat not needed.

Expand  

Do not make sense. Format of file can be any.

Posted
gg.clearResults()
if gg.isVisible(true) then 
  
   gg.setVisible(false) 
  --[===[ is gg.isvisible and gg.setVisible supported in GG ?
end 
::novalue::
gg.toast('Candy Crush Soda Lua Script By Ankit007')
data = gg.prompt({[1]='Enter Your Score'}, {[1]''})
if data == nil then
   gg.toast ('Please enter a value')
   goto novalue
end 
gg.searchNumber(data[1], gg.TYPE_DWORD, false, gg.SIGN_EQUAL, 0, -1)
if gg.getResultCount() < 6 then
	data = gg.editAll('2117483647', gg.TYPE_DWORD))
	gg.toast (' Enjoy the game')
else
gg.toast( 'to many values found update the value and try  again')
end

As i am new in lua scripting just started yesterday, and after understanding the lua first i started with Candy Crush Soda Score Increase Script

I want this script to hide the main gg and show only the script screen and

also 2 if conditions one to check that user should not enter the a null value and second that if to many values found then it should say that update the value

but to update and search again the user should close the script, i tried t add the sleep function but don't know much about it

Any thing required to be changed in the code ?

new 1.luaFetching info...

Posted (edited)
  On 7/21/2017 at 4:08 AM, Enyby said:

Do not make sense. Format of file can be any.

Expand  

:/ I just started learning LUA this morning. Community Documentation said File format was .lua. dont bully plox. Thanks for info tho.

But the table.load and table.save isn't usable right? Tried it many times, but seems like its just an empty function (nil)

Edited by circleous
grammad fix
Posted (edited)
  On 7/21/2017 at 6:12 AM, circleous said:

prompt(table, [table, [table]])

Default value for input table is nil, you don't need to add [1]''

Expand  

thx but still it will be nil as i didn't passed any value to it

anyway thanks , don't know much about lua, still in learning stage

Edited by ankit007
  • Administrators
Posted
  On 7/21/2017 at 6:05 AM, ankit007 said:

--[===[ is gg.isvisible and gg.setVisible supported in GG ?

Expand  

 

  On 7/20/2017 at 4:20 PM, Enyby said:
Expand  

 

_______________________________________________
added 0 minutes later
  On 7/21/2017 at 6:05 AM, ankit007 said:

{[1]''})

Expand  

error. Skipped '='.

_______________________________________________
added 2 minutes later
  On 7/21/2017 at 6:05 AM, ankit007 said:

I want this script to hide the main gg and show only the script screen and

Expand  

use isVisible, setVisible.

_______________________________________________
added 2 minutes later
  On 7/21/2017 at 6:05 AM, ankit007 said:

to check that user should not enter the a null value

Expand  

Make check in your code.

_______________________________________________
added 3 minutes later
  On 7/21/2017 at 6:05 AM, ankit007 said:

if to many values found then it should say that update the value

Expand  

getResultCount() and do anything with this number.

  • Administrators
Posted
  On 7/21/2017 at 6:05 AM, ankit007 said:

to update and search again the user should close the script, i tried t add the sleep function but don't know much about it

Expand  

Use loop like I do in my scripts: https://gameguardian.net/forum/topic/17447-lua-scripting/?do=findComment&comment=58903

 

_______________________________________________
added 2 minutes later
  On 7/21/2017 at 6:06 AM, circleous said:

Community Documentation said File format was .lua.

Expand  

It is not format. It is only extension.

Hat can be red. but it doesn't say anything useful about people below it. Same with file. extension of file and file internal structure AKA format not connected. You can rename .txt to .exe but this not make text file executable.

_______________________________________________
added 2 minutes later
  On 7/21/2017 at 6:06 AM, circleous said:

But the table.load and table.save isn't usable right? Tried it many times, but seems like its just an empty function (nil)

Expand  

This functions not exists.

Posted

 

  On 7/21/2017 at 10:09 AM, Enyby said:

Hat can be red. but it doesn't say anything useful about people below it. Same with file. extension of file and file internal structure AKA format not connected. You can rename .txt to .exe but this not make text file executable.

Expand  

I know about this file format thingy, while I'm reversing a crackme, need to dump some memory region and analyze it, you can't see file name but only structure, yep. Well, I've dealt with a silly C library enforcing the full path name and file format to follow the docs style. Thats where my faithful to example in docs begin, lol.

  • Administrators
Posted

If you fear 5 lines of code - I have bad news to you.

open
for
write
end
close

Is typical for any lang. Nothing complicated.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

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.