#library "SKILLS"
#include "zcommon.acs"
Script 599 ENTER //This changes the TID of all players to 1666.
{
Thing_ChangeTID(0, 1666);
}
Script 600 (void) //This adds a 10% increase to the Player's speed.
{
if (CheckInventory("SP") > 0)
{
TakeInventory("SP", 1);
SetActorProperty(1666, APROP_SPEED, 1.10);
HudMessage(s: "Your SPEED increased!";
0, 1, CR_YELLOW, 905, 605, 0.5);
}
else
{
HudMessage(s: "You do not have enough Skill Points!";
0, 1, CR_RED, 905, 605, 0.5);
}
Delay(1);
}
Hi everyone! I have this first passive skill, which increases the player's speed each time it is upgraded.
I was wondering if there is a way to check the player's speed (set to a sort of capacity limit), and stop the script from trying to add more speed increase to the player with a notification saying "You are already fast enough!".
How will I go about doing this? I would not want the player to get to 1000 times speed.
Question
Dragoon
#library "SKILLS" #include "zcommon.acs" Script 599 ENTER //This changes the TID of all players to 1666. { Thing_ChangeTID(0, 1666); } Script 600 (void) //This adds a 10% increase to the Player's speed. { if (CheckInventory("SP") > 0) { TakeInventory("SP", 1); SetActorProperty(1666, APROP_SPEED, 1.10); HudMessage(s: "Your SPEED increased!"; 0, 1, CR_YELLOW, 905, 605, 0.5); } else { HudMessage(s: "You do not have enough Skill Points!"; 0, 1, CR_RED, 905, 605, 0.5); } Delay(1); }
Hi everyone! I have this first passive skill, which increases the player's speed each time it is upgraded.
I was wondering if there is a way to check the player's speed (set to a sort of capacity limit), and stop the script from trying to add more speed increase to the player with a notification saying "You are already fast enough!".
How will I go about doing this? I would not want the player to get to 1000 times speed.
Share this post
Link to post
1 answer to this question
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.