Posts: 135
Threads: 59
Joined: May 2013
Reputation:
0
And how would I get a players name to appear in one of them?
Posts: 1,801
Threads: 27
Joined: Mar 2009
Reputation:
0
There's no difference between %d and %i, and you can't put a player name in them, but you can in a %s.
Posts: 1,130
Threads: 181
Joined: Jan 2009
Reputation:
0
new name[MAX_PLAYER_NAME];
GetPlayerName(playerid, name, sizeof(name));
format(string, sizeof(string), "%s", name);
SendClientMessage(playerid, 0xFFFFFFFFF, string);
Hope this is what you need
Posts: 1,130
Threads: 181
Joined: Jan 2009
Reputation:
0
edit i forgot to use new string[128];
(In this case you could use string[MAX_PLAYER_NAME] Because its only outputting your name. In case of any other values or strings use [128] or any string size that you need)
Posts: 6,236
Threads: 310
Joined: Jan 2011
Reputation:
0
%i and %d are exactly the same - which one you use is down to personal preference. I personally prefer %i as i stands for 'integer' (which is what it displays). I don't like %d at all - decimals make me think of floats, and %d doesn't show a float..