10.06.2012, 17:41
preciso de mais ajuda :O
< no caso quando aperto enter mata o player e nao tira 10 de hp dele e outra como faзo para que o dano so funcione contra humano? valeu gente
pawn Код:
public OnPlayerKeyStateChange(playerid, newkeys, oldkeys)
{
if(Equipes[playerid] == 2)
{
if(newkeys & KEY_SECONDARY_ATTACK)
{
new Float:X, Float:Y, Float:Z,vida;
for(new i = 0; i<MAX_PLAYERS; ++i){
if(i != playerid){
GetPlayerPos(i,X,Y,Z);
if(IsPlayerInRangeOfPoint(playerid,3.0,X,Y,Z))
{
SetPlayerHealth(i,vida -10);
}
}
}
}
}
return 1;
}
![Cheesy](images/smilies/biggrin.png)