Code: Select all
{
INCREASETIMER [0]
TIMERAMOUT [0.5]
Spawn[ ()
{
Console(true);
LowLevel("Keycheck");
} ]
Keycheck[ ()
{
if(INCREASETIMER < self.time)
{
if (GetAttribute("health","Player") < 30)
{
PlaySound("healthlow.wav");
}
else
{
PlaySound("silent.wav");;
}
INCREASETIMER = self.time + StringCopy(TIMERAMOUT);
}
debug(GetAttribute("INCREASETIMER", "HC"));
} ]
}