26.05.2011, 16:17
There is still flawed logic here, I don't understand what you're trying to achieve by having a variable that never changes which contains 0 and calling it playerid2? What is that going to achieve? It will just mean that everytime this piece of code is run, playerid 0 will always get 500 dollars and be announced in chat as a medic, which doesn't make much sense unless ID 0 is always a medic in your server?
All of the code is actually doing this:
So what's the point of the variable at all?
All of the code is actually doing this:
pawn Код:
if(gTeam[0] == TEAM_MEDICS)
{
if(GetPlayerState(0) == PLAYER_STATE_DRIVER && GetPlayerState(playerid) == PLAYER_STATE_PASSENGER)
{
// And so on