07.06.2014, 08:10
This shit of code, I will explain to you, all it can do for Array and cut a lot, nice total.
PHP Code:
enum e_TELEPORT {
tName[27],
Float:tPos[3]
}
new
aTeleport[][e_TELEPORT] = {
{"/Race",{1.1,1.1,1.1}}
};
public OnPlayerCommandText(playerid,cmdtext[])
{
for(new i; i != sizeof(aTeleport); i++)
{
if(!strcmp(cmdtext,aTeleport[i][tName],true))
{
SetPlayerPos(playerid,aTeleport[i][tPos][0],aTeleport[i][tPos][1],aTeleport[i][tPos][2]);
GameTextForPlayer...
}
}
return 1;
}