OnNPCConnect: Difference between revisions

From NPC for VCMP 0.4 Servers
Jump to navigation Jump to search
(Created page with "{{Welcome| desc=This function is called when an NPC successfully connect to a server.| params=<syntaxhighlight lang="lua">(myplayerid)</syntaxhighlight> ::myplayerid::The play...")
 
No edit summary
 
(4 intermediate revisions by the same user not shown)
Line 2: Line 2:
desc=This function is called when an NPC successfully connect to a server.|
desc=This function is called when an NPC successfully connect to a server.|
params=<syntaxhighlight lang="lua">(myplayerid)</syntaxhighlight>
params=<syntaxhighlight lang="lua">(myplayerid)</syntaxhighlight>
::myplayerid::The player id the NPC has been given.|
<poem>::myplayerid : The player id the NPC has been given.</poem>|
retvals=This function does not return any specific values.
retvals=This function does not return any specific values.|
example=<source lang="lua">
example=<source lang="lua">
function OnNPCConnect(myplayerid)  
function OnNPCConnect(myplayerid)  

Latest revision as of 10:21, 9 March 2022


Description:
This function is called when an NPC successfully connect to a server.


Parameters:

(myplayerid)

myplayerid : The player id the NPC has been given.


Return Values:
This function does not return any specific values.


Example

function OnNPCConnect(myplayerid) 
{ 
     print("I have been connected with ID:"+myplayerid+"\n");
}