Knockout But Dies?
I recently finished my Teleport script, but.. when i teleport i die? Here is my script! Is there something wrong with it?
void Knockout(string &in asEntity)
{
SetPlayerActive(false);
FadeOut(0.8f);
MovePlayerHeadPos(0.0f, -1.25f, 0.0f, 1.5f, -1.0f);
FadePlayerRollTo(3.0f, 4.5f, 5.0f);
PlaySoundAtEntity("", "player_bodyfall", "Player", 0.0f, true);
AddTimer("Teleport", 2.0f, "Lol");
AddTimer("FadeIn", 2.0f, "Lol");
}
void Lol(string &in asTimer)
{
if(asTimer == "Teleport")
{
FadePlayerRollTo(0, 4.5f, 5.0f);
MovePlayerHeadPos(0, 0, 0, 5, 0);
TeleportPlayer("TeleportHere");
}
if(asTimer == "FadeIn")
{
SetPlayerActive(true);
FadeIn(1.0f);
}
}
When I spawn i keep seeing myself falling. Thanks! (P.S. I die then)
|