- Joined
- Jan 6, 2008
- Messages
- 2,627
Hello everyone, Im learning Structs at the moment, but i cant figure out which structs to make. Ill tell you what a struct is if you dont know.
A struct is like a shortcut for a long script, like GUI is a shortcut to JASS, so if i do
and then it will do ALL these actions in a single call, There are some advanced structs that i will try to learn later.
but the problem is i dont know how, so if you got an idea (the idea can also be a somewhat request), i would appriciate it. Since i find structs fun to make, but dont know what i should make.
A struct is like a shortcut for a long script, like GUI is a shortcut to JASS, so if i do
JASS:
call MYSTRUCT.MYMETHOD(variabledata, variabledata2)
and then it will do ALL these actions in a single call, There are some advanced structs that i will try to learn later.
JASS:
struct MYSTRUCT
static method MYMETHOD takes variable variabletype, variable2 variabletype2 returns thistype
// Lots of actions can be added here :D
call CreateUnit(variable, variable2) // for example
endmethod
endstruct
but the problem is i dont know how, so if you got an idea (the idea can also be a somewhat request), i would appriciate it. Since i find structs fun to make, but dont know what i should make.