g1doz Posted August 31, 2019 Share Posted August 31, 2019 What the difference between this function test(a) end and this function test() end What to do function if we add a character in parentheses ? Link to comment Share on other sites More sharing options...
ItsSC Posted August 31, 2019 Share Posted August 31, 2019 test(a) is a preset function. a is a variable. for example you are lazy to type gg.searchNumber(x,y) then you can do this -- Preset function function SD(x) --search dword gg.searchNumber(x,gg.TYPE_DWORD) end then you can now use SD(any value) to search for dword. X is just an unknown, you can input any value inside or any variable. Link to comment Share on other sites More sharing options...
Administrators Enyby Posted August 31, 2019 Administrators Share Posted August 31, 2019 It is called function arguments. Try read some basic tutorial about programming. http://lua-users.org/wiki/FunctionsTutorial Link to comment Share on other sites More sharing options...
g1doz Posted August 31, 2019 Author Share Posted August 31, 2019 ok enyby and thx you ItsSC Link to comment Share on other sites More sharing options...
Question
g1doz
What the difference between this
function test(a)
end
and this
function test()
end
What to do function if we add a character in parentheses ?
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.