


Login Issues
Forgot password?Activate Issues
Account activation email not received? Wrong account activation email used?Other Problems?
Contact Support - Help Center Get help on the UGX Discord. Join it now!


![]() | Benevolent Soul who has our eternal gratitude and exclusive access to betas and the donator section of the forum. |
![]() | Has shown excellence and experience in the area of custom scripting in the UGX-Mods community. |
![]() Oil Rig Beta Access |
thread teleport_think(self);teleport_think( zombie )
{
zombie endon( "death" );
iprintln( "teleport think threaded" );
target = getent( "teleport_target" , "targetname" );
teleport_radius = 122500; // 350 squared
while(1)
{
rand = randomintrange( 1, 101 );
if( rand < 51 )
{
players = get_players();
for ( i = 0; i < players.size; i++ )
{
if ( DistanceSquared( zombie.origin, players[i].origin ) < teleport_radius )
{
Iprintln( " Can teleport " );
nw_ori = target.origin;
iprintln( "new origin: ["+ nw_ori +"] " );
zombie teleport( target.origin, zombie.angles );
break;
}
else
{
Iprintln( " DO NOT teleport " );
wait 0.05;
}
}
}
Iprintln( " Recharging teleport function" );
wait 10;
}
}
![]() | Benevolent Soul who has our eternal gratitude and exclusive access to betas and the donator section of the forum. |
![]() | Has shown excellence and experience in the area of custom scripting in the UGX-Mods community. |
![]() Oil Rig Beta Access |
Does it print the origin? Because you said you used a script_struct, but in your script you use GetEnt(). script_structs need to be acquired by GetStruct().
- Phil.

![]() | Benevolent Soul who has our eternal gratitude and exclusive access to betas and the donator section of the forum. |
![]() | Has shown excellence and experience in the area of custom scripting in the UGX-Mods community. |
![]() Oil Rig Beta Access |