Trouble with structures

patmo98

New member
1) I found an example somewhere that implys this code should work. Anyone know what I'm doing wrong?

Code:
struct MyStruct
{
	int myInt;
}

void main()
{
	MyClass test;
	test.myInt = 5;
}

I'm getting this error "Expected ;, found { (test.ash, line 2)"


2) Is there a way to ask mafia what a weapon's power is?
 
Last edited:

Veracity

Developer
Staff member
And, assuming you are writing in ASH rather than C, you need to declare a "record", not a "struct".
 
Top