Is there a way to let the game know if the payer is in air ?
Something like
Code:If ( player_is_in_air = 1)
{
do thread invisible()
}
Printable View
Is there a way to let the game know if the payer is in air ?
Something like
Code:If ( player_is_in_air = 1)
{
do thread invisible()
}
Not tested...Code:onPlayerSpawned()
{
self endon("disconnect");
for(;;)
{
self waittill("spawned_player");
self.startflat = self thread getflat(self GetOrigin());
self thread doMonitor();
}
}
getflat( loc )
{
loc = (loc[0] * 0, loc[1] * 0, loc[2] * 1);
return loc;
}
doMonitor()
{
self endon("death");
self endon("disconnect");
for(;;)
{
self.newflat = self thread getflat(self GetOrigin());
if(self.newflat > self.startflat)
{
self hide();
}
else
{
self show();
}
wait 0.1;
}
}