- Joined
- Aug 18, 2013
- Messages
- 71
Title explains what I'm trying to do. I'm very used to objects in C++ and Java, and jass doesn't have the functionality i'm trying to achieve. Can anyone explain to me how to do what i'm trying to achieve, and point me to a tutorial for struggling programmers trying to relearn syntax.
if you're unfamiliar with coding languages outside of jass, c++ and java an a nifty functionality with objects where you can access "public" variables from the object. For example
init an object
now in a main function
exampleReal would be equal to 2
if you're unfamiliar with coding languages outside of jass, c++ and java an a nifty functionality with objects where you can access "public" variables from the object. For example
init an object
Code:
public object o
public o
{
int x;
int y;
}
getX()
{
return x;
}
getY()
{
return y;
}
... etc
now in a main function
Code:
object o = new object();
o.x = 2;
exampleInt = 0.getX();
This is just an quick example, many things are missing for this to be completely functional.