Format strings...
#7

This code should work, but does not work.

/aap command was defined in gamemode.

In addition, these works:

pawn Код:
public SetPlayerPos(playerid, Float:x, Float:y, Float:z)
{
new anas[256];
format(anas,sizeof(anas),"/setplayerpos %d %f %f %f", playerid, x, y, z);
SendCommand(anas);
return 1;
}

public SetPlayerHealth(playerid, Float:health)
{
new anas[256];
format(anas,sizeof(anas),"/setplayerhealth %d %f", playerid, health);
SendCommand(anas);
return 1;
}

public SetPlayerArmour(playerid, Float:armour)
{
new anas[256];
format(anas,sizeof(anas),"/setplayerarmour %d %f", playerid, armour);
SendCommand(anas);
return 1;
}

public SetPlayerName(playerid, name[])
{
new anas[256];
format(anas,sizeof(anas),"/setplayername %d %s", playerid, name);
SendCommand(anas);
return 1;
}

public SetPlayerSpecialAction(playerid, actionid)
{
new anas[256];
format(anas,sizeof(anas),"/spsa %d %i", playerid, actionid);
SendCommand(anas);
return 1;
}

public SetMySpecialAction(actionid)
{
new anas[256];
format(anas,sizeof(anas),"/smsa %i", actionid);
SendCommand(anas);
return 1;
}

Reply


Messages In This Thread
Format strings... - by erorcun - 14.09.2009, 17:49
Re: Format strings... - by Sergei - 14.09.2009, 18:04
Re: Format strings... - by erorcun - 14.09.2009, 18:15
Re: Format strings... - by erorcun - 16.09.2009, 09:50
Re: Format strings... - by Mikep. - 16.09.2009, 11:13
Re: Format strings... - by dugi - 16.09.2009, 11:38
Re: Format strings... - by erorcun - 16.09.2009, 17:50
Re: Format strings... - by BigJayMalcolm - 16.09.2009, 20:52
Re: Format strings... - by saiberfun - 16.09.2009, 21:00
Re: Format strings... - by erorcun - 16.09.2009, 21:54

Forum Jump:


Users browsing this thread: 2 Guest(s)