NED
Well-known member
In my project, enemies randomly go to a dizzy anim from rise anim.
The code is OK, but there is few settings I want to edit.
during this particular dizzy anim, there is a display of a dizzy effect (stars + loop sound.
How can I make this effect (sprite and sound) disapear if enemy is hit during this dispaly?
this is the rise to dizzy code:
How can I fix it?
Thanks
The code is OK, but there is few settings I want to edit.
during this particular dizzy anim, there is a display of a dizzy effect (stars + loop sound.
How can I make this effect (sprite and sound) disapear if enemy is hit during this dispaly?
this is the rise to dizzy code:
Code:
anim rise
loop 0
offset 96 177
bbox 0 0 0 0
delay 15#11
@script
void self = getlocalvar("self");
if( frame == 0){
int r = rand()%30;
if( r >= 9){
changeentityproperty(self, "animation", openborconstant("ANI_FOLLOW1"));
}
}
@end_script
frame data/chars/mex/rise1.gif
delay 18
frame data/chars/mex/rise2.gif
delay 18
frame data/chars/mex/rise3.gif
anim follow1# dizzy anim - randomly from rise
offset 96 177
bbox 67 58 61 122
subentity stun0001
# #spawnframe {frame} {x} {z} {a} {relative} # position est par rapport a l'offset du perso
spawnframe 1 0 2 90 0#1 0 0 0 0
# summonframe 1 0 2 90 0#1 0 0 0 0
# unsummonframe 4
delay 20#30#100#15
frame data/chars/mex/pain2.gif
delay 25#40
frame data/chars/mex/pain1.gif
delay 30
frame data/chars/mex/pain2.gif
delay 25
frame data/chars/mex/pain1.gif
delay 60
frame data/chars/mex/pain2.gif
How can I fix it?
Thanks