NED
Well-known member
Hi,
I have few problem making keyint working.
I use it for a chain throws system.
To avoid consuming freespecials, I use keyint to cancel to follow anims
This is the part(frame) where cancel should occur:
But is there a way to make it working with just a normal "hit button imput" ? (instead of hold... or release)
Any help is welcome
Thanks
The actual keyint script I used
I edited it a bit with my low skills to allow other buttons imputs A3, A4...
I have few problem making keyint working.
I use it for a chain throws system.
To avoid consuming freespecials, I use keyint to cancel to follow anims
This is the part(frame) where cancel should occur:
Code:
#-----------------------CANCEL FROM HERE
delay 9#8
@cmd keyint "ANI_FOLLOW43" 0 "A" 0 0#{animation} {frame} {key} {hold0/release1} {minhealth}-----Cancel to arm lock
frame data/chars/rachel/swingneck11.gif
#-----------------------CANCEL FROM HERE
But is there a way to make it working with just a normal "hit button imput" ? (instead of hold... or release)
Any help is welcome
Thanks
The actual keyint script I used
I edited it a bit with my low skills to allow other buttons imputs A3, A4...
Code:
void keyint(void Ani, int Frame, void Key, int Hflag, int Limit)
{// Change current animation if proper key is pressed or released provided HP is more than limit (J'ai ajouté A3 et A4 dispo)
void self = getlocalvar("self");
void Health = getentityproperty(self,"health");
int iPIndex = getentityproperty(self,"playerindex"); //Get player index
void iRKey;
if (Key=="U"){ //Up Required?
iRKey = playerkeys(iPIndex, 0, "moveup"); // "Up"
}
if (Key=="D"){ //Down Required?
iRKey = playerkeys(iPIndex, 0, "movedown"); // "Down"
}
if (Key=="J"){ //Jump Required?
iRKey = playerkeys(iPIndex, 0, "jump"); // "Jump"
}
if (Key=="A"){ //Attack Required?
iRKey = playerkeys(iPIndex, 0, "attack"); // "Attack"
}
if (Key=="S"){ //Special Required?
iRKey = playerkeys(iPIndex, 0, "special"); // "Special"
}
if (Key=="A2"){ //Attack2 Required?
iRKey = playerkeys(iPIndex, 0, "attack2"); // "Attack2"
}
if (Key=="A3"){ //Attack3 Required?
iRKey = playerkeys(iPIndex, 0, "attack3"); // "Attack3"
}
if (Key=="A4"){ //Attack4 Required?
iRKey = playerkeys(iPIndex, 0, "attack4"); // "Attack4"
}
if (Key=="UJ"){ //Up and Jump Required?
iRKey = playerkeys(iPIndex, 0, "moveup", "jump"); // "Up" + "Jump"
}
if (Hflag==1){ //Not holding the button case?
iRKey = !iRKey; //Take the opposite condition
}
if ((Health > Limit)&&iRKey){
changeentityproperty(self, "animation", openborconstant(Ani)); //Change the animation
changeentityproperty(self, "animpos", Frame);
if (Key=="UJ"){
// This is copy of dethrown
changeentityproperty(self, "attacking", 0);
changeentityproperty(self, "damage_on_landing", 0);
changeentityproperty(self, "projectile", 0);
}
}
}