if( cmd == "aeroport" ){ player.Pos = Vector( -1498.3, -915.4, 11.11 );}
Hi, I have problem for teleport to go aeroportQuoteif( cmd == "aeroport" ){ player.Pos = Vector( -1498.3, -915.4, 11.11 );}I use a location with "mypos", Screen ERROR :Thank's all!
Code: [Select] if ( szCommand == "airport" ) { if ( pPlayer.Spawned ) { if ( !szParams ) { local v = pPlayer.Pos; v.x = -1566; v.y = -951; v.z = 11; pPlayer.Pos = v; MessagePlayer( "*PM* You teleported to: /" + szCommand, pPlayer, Colour( 0, 255, 0 ) ); } else MessagePlayer( "*PM* Error: Argument is not needed for this command", pPlayer, Colour( 255, 0, 0 ) ); } else MessagePlayer( "*PM* Error: You are not spawned. Press CTRL to spawn", pPlayer, Colour( 255, 0, 0 ) );}This is the one used on lolmortuary so please just change messages.
if ( szCommand == "airport" ) { if ( pPlayer.Spawned ) { if ( !szParams ) { local v = pPlayer.Pos; v.x = -1566; v.y = -951; v.z = 11; pPlayer.Pos = v; MessagePlayer( "*PM* You teleported to: /" + szCommand, pPlayer, Colour( 0, 255, 0 ) ); } else MessagePlayer( "*PM* Error: Argument is not needed for this command", pPlayer, Colour( 255, 0, 0 ) ); } else MessagePlayer( "*PM* Error: You are not spawned. Press CTRL to spawn", pPlayer, Colour( 255, 0, 0 ) );}
Quote from: GuenosNoLife on January 24, 2013, 10:02:39 pmHi, I have problem for teleport to go aeroportQuoteif( cmd == "aeroport" ){ player.Pos = Vector( -1498.3, -915.4, 11.11 );}I use a location with "mypos", Screen ERROR :Thank's all!Is that under onPlayerCommand?
What tutorial?
Thank's but what is function ? I write : function onPlayerCommand( player, cmd )
@SugarD Thank's for code@Svenko Thank's for Function