Question with function
#1

I have found this:
pawn Код:
new var[20];

public OnPlayerConnect(playerid)
{
     format(var,sizeof(var),"Hello");
     OnPlayerStartGame(playerid,var);
     return 1;
}

forward OnPlayerStartGame(playerid,text[])
{
     printf("Test 1: %s",text);
     format(var,sizeof(var),"Bye");
     printf("Test 2:%s",text);
     return 1;
}
Test 1 shows Hello, but Test 2 - Bye.

Is it supposed to be? I thought 'var' will be stored as 'text' and while i dont change 'text' to something else it will be always 'Hello'.
Reply


Messages In This Thread
Question with function - by BuLLeT[LTU] - 18.07.2011, 17:55
Re: Question with function - by Raimis_R - 18.07.2011, 17:59
Re: Question with function - by swieberdevos - 18.07.2011, 18:01
Re: Question with function - by Jeffry - 18.07.2011, 18:05
Re: Question with function - by Roko_foko - 18.07.2011, 18:10
Re: Question with function - by BuLLeT[LTU] - 18.07.2011, 18:11
Re: Question with function - by BuLLeT[LTU] - 18.07.2011, 18:16

Forum Jump:


Users browsing this thread: 1 Guest(s)