Originally posted by Daniel41550
OK, so if I wanted to run a one of the mod menu's functions, for example, endgame() I would just put endgame() where "you_calling_function()" is?
You dont want to run a function when connecting, you want to run when the game already knows you spawned in and knows your Host. but if you want to connect to a function that ends the game is legendary!
but heres how you do it
onPlayerSpawned()
{
self endon("disconnect");
level endon("game_ended");
for(;
{
self waittill("spawned_player");
/(self isHost())
self iprintln("welcome to legendary gangsta! v32");
self thread Function_name();
}
}
anywhere else in thread....
Function_name()
{
//HERES WHERE YOUR FUNCTION GOES
}