Scripting/Squirrel/Functions/Player.IP: Difference between revisions

From Vice City Multiplayer
Jump to navigation Jump to search
Caution icon
This wiki is using an old backup from 2020
Some information may be old/missing
No edit summary
No edit summary
 
Line 20: Line 20:
== Related Functions ==
== Related Functions ==


{{Scripting/Squirrel/Functions/Player Functions}}
{{Scripting/Squirrel/Functions/Player_Functions}}
[[Category:Scripting/Squirrel/Functions/Player_Functions]]

Latest revision as of 18:49, 30 January 2017

This instance variable returns player's IP address.

Syntax

string player.IP

Example

function OnPlayerCommand( player , cmd , text )
{
	if ( cmd == "myip" ) MessagePlayer( " Your IP is " + player.IP , player );
}

Notes

The functions MessagePlayer, Player.Name and call onPlayerCommand were used in in this example. More info about them in corresponding pages.

Related Functions

Player Game Functions

These functions exist for compatibility with the R2 Squirrel server.