Manual Rise issue

Aerisetta

Active member
Hi,

I am currently creating a feature where the player needs to press a button to get up after getting knocked down. If the player does not press anything, the player will stay on the ground, and enemies could grab them into a strangle hold.

I am using riseattack as the way for the player to get back up.

Code:
anim    rise
@script
  if(frame==1){
    void self = getlocalvar("self");
    int DedSt = getentityvar(self, "DedSt");

    if(DedSt!=0){
      performattack(self, openborconstant("ANI_FOLLOW25"));
    }
  }
@end_script
    delay    6
    offset    800 650
    frame    data/chars/Aerisetta/fall203.png
    move    10
    @cmd    setglobalvar "zoomentity" NULL()
    frame    data/chars/Aerisetta/fall203.png
    move    -10
    frame    data/chars/Aerisetta/fall203.png
    move    10
    frame    data/chars/Aerisetta/fall203.png
    move    -10
    frame    data/chars/Aerisetta/fall203.png
    move    10
    @cmd    setglobalvar "zoomentity" NULL()
    frame    data/chars/Aerisetta/fall203.png
    move    -10
    
anim    riseattack
@script
  if(frame==1){
    void self = getlocalvar("self");
    int DedSt = getentityvar(self, "DedSt");

    if(DedSt!=0){
      performattack(self, openborconstant("ANI_FOLLOW25"));
    }
  }
@end_script
    delay    6
    offset    800 650
    frame    data/chars/Aerisetta/fall203.png
    move    10
    @cmd    setglobalvar "zoomentity" NULL()
    frame    data/chars/Aerisetta/fall203.png
    move    -10
    frame    data/chars/Aerisetta/fall203.png
    move    10
    frame    data/chars/Aerisetta/fall203.png
    move    -10
    frame    data/chars/Aerisetta/fall203.png
    move    10
    @cmd    setglobalvar "zoomentity" NULL()
    frame    data/chars/Aerisetta/fall203.png
    move    -10

Here is the header
riseinv 1 1
risetime -99999 0
riseattacktype 0
makeinv 2 0

One issue I am having is in this way, the player is immediately vulnerable to attack when they get back up because the riseinv does not apply to risattack.

Is there a way for me to create this feature and get riseinv to still work?
 
Hi,

I am currently creating a feature where the player needs to press a button to get up after getting knocked down. If the player does not press anything, the player will stay on the ground, and enemies could grab them into a strangle hold.

I am using riseattack as the way for the player to get back up.

Code:
anim    rise
@script
  if(frame==1){
    void self = getlocalvar("self");
    int DedSt = getentityvar(self, "DedSt");

    if(DedSt!=0){
      performattack(self, openborconstant("ANI_FOLLOW25"));
    }
  }
@end_script
    delay    6
    offset    800 650
    frame    data/chars/Aerisetta/fall203.png
    move    10
    @cmd    setglobalvar "zoomentity" NULL()
    frame    data/chars/Aerisetta/fall203.png
    move    -10
    frame    data/chars/Aerisetta/fall203.png
    move    10
    frame    data/chars/Aerisetta/fall203.png
    move    -10
    frame    data/chars/Aerisetta/fall203.png
    move    10
    @cmd    setglobalvar "zoomentity" NULL()
    frame    data/chars/Aerisetta/fall203.png
    move    -10
   
anim    riseattack
@script
  if(frame==1){
    void self = getlocalvar("self");
    int DedSt = getentityvar(self, "DedSt");

    if(DedSt!=0){
      performattack(self, openborconstant("ANI_FOLLOW25"));
    }
  }
@end_script
    delay    6
    offset    800 650
    frame    data/chars/Aerisetta/fall203.png
    move    10
    @cmd    setglobalvar "zoomentity" NULL()
    frame    data/chars/Aerisetta/fall203.png
    move    -10
    frame    data/chars/Aerisetta/fall203.png
    move    10
    frame    data/chars/Aerisetta/fall203.png
    move    -10
    frame    data/chars/Aerisetta/fall203.png
    move    10
    @cmd    setglobalvar "zoomentity" NULL()
    frame    data/chars/Aerisetta/fall203.png
    move    -10

Here is the header
riseinv 1 1
risetime -99999 0
riseattacktype 0
makeinv 2 0

One issue I am having is in this way, the player is immediately vulnerable to attack when they get back up because the riseinv does not apply to risattack.

Is there a way for me to create this feature and get riseinv to still work?
@Aerisetta I had a similar problem some time ago but solved by applying invincibility status manually.

C:
anim riseattack
    loop    0
    delay    2
    offset    62 125
    @cmd invincible 1 1
    @cmd dasher 2 0 0
    @cmd copyMove
    frame    data/chars/heroes/axel/dodge00.png
        delay    8
    @cmd pasteMove
    frame    data/chars/heroes/axel/dodge01.png
    @cmd pasteMove
    frame    data/chars/heroes/axel/dodge02.png
    @cmd pasteMove
    frame    data/chars/heroes/axel/dodge03.png
    @cmd pasteMove
    frame    data/chars/heroes/axel/dodge04.png
        delay    20
    @cmd dasher 0 0 0
    frame    data/chars/heroes/axel/dodge05.png

C:
void invincible(int flag, float duration)
{//Turns invincible status, used on riseattack and aerial recovery animations
    void self    = getlocalvar("self");
    float time    = openborvariant("elapsed_time");
    float mult    = 200;
    float end    = duration*mult;

    if(flag == 1){
        changeentityproperty(self, "aiflag", "invincible", 1);
        changeentityproperty(self, "invinctime", time+end);
    }
    else
    {
        changeentityproperty(self, "aiflag", "invincible", 0);
    }
}
 
Back
Top Bottom