Kick Stamina
Forum rules
Before asking on how to use a ZDoom feature, read the ZDoom wiki first. If you still don't understand how to use a feature, then ask here.
Please bear in mind that the people helping you do not automatically know how much you know. You may be asked to upload your project file to look at. Don't be afraid to ask questions about what things mean, but also please be patient with the people trying to help you. (And helpers, please be patient with the person you're trying to help!)
Before asking on how to use a ZDoom feature, read the ZDoom wiki first. If you still don't understand how to use a feature, then ask here.
Please bear in mind that the people helping you do not automatically know how much you know. You may be asked to upload your project file to look at. Don't be afraid to ask questions about what things mean, but also please be patient with the people trying to help you. (And helpers, please be patient with the person you're trying to help!)
Kick Stamina
How would I add stamina to this kick? I'm not great at Zscript or Decorate.
- Attachments
-
kick.pk3- (89.81 KiB) Downloaded 19 times
Re: Kick Stamina
You'd have to define a stamina actor first. Something like this:
And then modify the Kick script to check for the stamina actor and take away an amount of it:
Code: Select all
ACTOR StaminaActor : Inventory
{
Inventory.MaxAmount 20 //Replace 20 with maximum stamina for the player
}Spoiler:You will also need a script to restore stamina to the player. (Unless it's supposed to be restored another way) This script does that:
Spoiler:
Re: Kick Stamina
That was very simple, thank you!
Re: Kick Stamina
So, I added it to the linked pk3, and modified it so every kick takes all stamina, and 4 seconds later stamina is completely full. It doesn't seem to work
http://www.mediafire.com/file/rel0on0la ... 2.pk3/file
http://www.mediafire.com/file/rel0on0la ... 2.pk3/file
Re: Kick Stamina
Sorry for not specifying, that part in the Kick script had to be replaced, not added.
The scripts should look like this:

You will also need to specify a path to ACC to compile it properly.
The scripts should look like this:
Spoiler:Also don't forget to compile the script, you will have to press this blue arrow in upper right corner of the editor in SLADE:

You will also need to specify a path to ACC to compile it properly.
