- Joined
- Apr 4, 2009
- Messages
- 4
I am learning both c++ and vjass now so I get a liittle confused.
in c++,when we have defined one class(eg.class bag),in the definition of another class,we can write
private bag thisbag
to create one private bag variable,but in jass,it get a liitle tricky,when we have defined one struct(eg,struct bag),in the definition of another struct,we are informed to write
private bag thisbag=bag.create().
to create one private bag variable.I just wonder if we can write
private bag thisbag
to get the things done because after the definition for bag struct is done,the compiler regards the bag as a new data type so we can directly declare it here.
one more question:In GUI,After I create one global variable of type unit,I can not find it in the unit parameter(the variable set) in the parameter list of event "specific unit event".What is wrong here?
in c++,when we have defined one class(eg.class bag),in the definition of another class,we can write
private bag thisbag
to create one private bag variable,but in jass,it get a liitle tricky,when we have defined one struct(eg,struct bag),in the definition of another struct,we are informed to write
private bag thisbag=bag.create().
to create one private bag variable.I just wonder if we can write
private bag thisbag
to get the things done because after the definition for bag struct is done,the compiler regards the bag as a new data type so we can directly declare it here.
one more question:In GUI,After I create one global variable of type unit,I can not find it in the unit parameter(the variable set) in the parameter list of event "specific unit event".What is wrong here?