need help with function - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: need help with function (
/showthread.php?tid=422187)
need help with function -
mineralo - 12.03.2013
well, I need to make a genelar function but I don't know how to do it.
pawn Код:
enum pInfo
{
pShit,pSux
};
new ShitInfo[MAX_PLAYERS][pInfo];
stock GetPlayerInfoEx(playerid,str[])
{
return ShitInfo[playerid][str];
}
like this, trhough script I need to use it. Any idea how to make it in real?
Re: need help with function -
MP2 - 12.03.2013
#define GetPlayerInfo(%0,%1) pInfo[%0][%1]
should do it.
But isn't easier to just do the
pInfo[playerid][...]
?
Re: need help with function -
mineralo - 12.03.2013
Quote:
Originally Posted by MP2
#define GetPlayerInfo(%0,%1) pInfo[%0][%1]
should do it.
But isn't easier to just do the
pInfo[playerid][...]
?
|
I want to make and function GivePlayerInfo because I getting boring by typing
PlayerInfo[playerid][pShit]=PlayerInfo.... also I want to put some message and song, better to use a function