Mp bar help

elisf2

Member
Hi guys quick ? I am incorporating super moves in the game I am working on and i want to make it so u can only use it when u are bellow half life I've tried everything I know we the mp command but can't figure it out I am hoping someone here can help thanks in advance for any help guys
 
There is nothing built in to the engine to do this. You will have to write a script to check hp on the move and if it is above the required amount force the animation back to idle.
 
You'd need to use script for that elisf2. Here's a script that might help:

Code:
anim	freespecial2
@script
    if(frame==0){
      void self = getlocalvar("self");
      int MHealth = getentityproperty(self,"maxhealth");
      int Health = getentityproperty(self,"health");

      if(Health > MHealth/2){
        setidle(self, openborconstant("ANI_IDLE"));
      }
    }
@end_script
...

If you pasted this on FREESPECIAL2, then the animation cannot be played until HP falls below half of max
 
Back
Top Bottom