- Joined
- Jan 5, 2007
- Messages
- 652
- Reaction score
- 7
i use these variables in my script
but for some reason out of my knowlages they give arrors
and wont drop numbers inside the variables + it wont make an
array
can anyone tell me why they wont work and tell me how to fix this
im trying to figger this out for 3 hours now and google wont rly help me T_T
thx in advance
but for some reason out of my knowlages they give arrors
and wont drop numbers inside the variables + it wont make an
array
can anyone tell me why they wont work and tell me how to fix this
im trying to figger this out for 3 hours now and google wont rly help me T_T
thx in advance
Code:
struct stats {
int *wep;
int *dmg;
int *health;
};
void main() {
//variables used in script
stats player;
*player.health = 100;
stats enemy;
*enemy.health = 100;
player.wep = new int[6];
*player.wep = 1;
player.dmg = new int[6];
*player.dmg = 1;
enemy.wep = new int[6];
*enemy.wep = 1;
enemy.dmg = new int[6];
*enemy.dmg = 1;
//end of script
delete enemy.wep;
delete enemy.dmg;
delete player.dmg;
delete player.wep;
system("PAUSE");
}