Posts: 121
Threads: 28
Joined: Oct 2010
Reputation:
0
Hey guys,
Here is the code:
new vardas[128], stringas[128];
GetPlayerName(playerid, vardas, sizeof(vardas));
format(stringas, sizeof(stringas), "%s says I need help!", vardas,);
SendClientMessageToAll(0xE6E6FAFF, stringas);
return 1;
}
And there is two teams. Blue team and Green team. All I want is how to do that stringas says: from (playerteam) Team (playername) says I need help!
I hope you understand me. Thanks for helping!
Posts: 121
Threads: 28
Joined: Oct 2010
Reputation:
0
Someone? Then just please give me an example how can i do it by myself!
Posts: 918
Threads: 148
Joined: Sep 2010
Reputation:
0
I don't get what you want :/ explain better please
Posts: 484
Threads: 49
Joined: Feb 2011
How you define your teams in your gamemod?
Posts: 121
Threads: 28
Joined: Oct 2010
Reputation:
0
Like this:
#define TEAM_GREEN 1
#define TEAM_BLUE 2
Posts: 121
Threads: 28
Joined: Oct 2010
Reputation:
0
What's wrong? Please, help:
new vardas[128], komanda[128], stringas[128];
GetPlayerName(playerid, vardas, sizeof(vardas));
GetPlayerTeam(playerid, komanda, sizeof(komanda));
if(GetPlayerTeam == 1) komanda = "Green";
if(GetPlayerTeam == 2) komanda = "Blue";
format(stringas, sizeof(stringas), "From %s Team %s says I need help!", komanda, vardas);
SendClientMessageToAll(0xE6E6FAFF, stringas);
return 1;
}
The error:
D:\GTA SA\USA vs MEC\gamemodes\map4.pwn(522) : warning 202: number of arguments does not match definition
D:\GTA SA\USA vs MEC\gamemodes\map4.pwn(522) : warning 202: number of arguments does not match definition
D:\GTA SA\USA vs MEC\gamemodes\map4.pwn(523) : error 076: syntax error in the expression, or invalid function call
D:\GTA SA\USA vs MEC\gamemodes\map4.pwn(524) : error 076: syntax error in the expression, or invalid function call
Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase
2 Errors.