Attack reaction

vision

Member
here is the situation. need help with enemy reactions to being hit. how to  make the enemy move in a desired direction during an attack. just that simple. freespecial3 and above seem to push the enemy away during a series of attacks that dont knock the enemy down, while freespecial1& 2 keeps the enemy stationary. lil help ??? 
 
put

move -1
or
move -5

or the amount that you think is ok to your game,  you can set one move command per frame of your animation if you desire

 
It goes to pain animation
@script
                void self = getlocalvar("self");
if ((getentityproperty(self, "direction")==1)&&(frame == 0)){
changeentityproperty(self, "velocity", -2, 0, 0);
}
if ((getentityproperty(self, "direction")==0)&&(frame == 0)){
changeentityproperty(self, "velocity", 2, 0, 0);
}
if(frame == 3){
void self = getlocalvar("self");
changeentityproperty(self, "velocity", 0, 0, 0);
}
@end_script
 
thanks, I didn't expect that to be a scripted reaction. but after looking through the scrips that are already in the game this is already present and only has to be addressed to a specific character's move. thanks for being so prompted. The deal is I'm working on a game that was abandoned and it has some script that I don't know how or what makes it work.

the mp bar has OK flashing when its full and its stationed in a specific spot for each char. I cant move it or get rid of it so now I'm guessing its somewhere in the script file. let the hunt begin.   
 
vision said:
the mp bar has OK flashing when its full and its stationed in a specific spot for each char. I cant move it or get rid of it so now I'm guessing its somewhere in the script file. let the hunt begin. 

Not sure which module you are working on, but for a flashing OK when MP is full I'd wager the code is in the global update script. Find it @ "data/scripts/update.c". It might also be an entity update, which is simply labeled "script" in the model. That is user defined, so you'll have to find the path in the model header. Look for "script data/..." and you'll know where to find it.
 
Hmmm... are you sure the OK icon is flashing? if it's just pops in when MP bar is full, probably it's just iconmphigh.

Do you mind telling us what mod would that be?
 
Back
Top Bottom