16.08.2015, 01:03
PHP код:
public OnPlayerKeyStateChange(playerid, newkeys)
{
if(newkeys == KEY_CROUCH) {
if(GetPlayerSpecialAction(playerid) != SPECIAL_ACTION_DUCK) return true;
for(new i = 0; i < MAX_SERVER_ITENS; i++) {
if(mundoItens[i][mItem_ativo] == false) continue;
if(!IsPlayerInRangeOfPoint(playerid, 1.0, mundoItens[i][mItem_x], mundoItens[i][mItem_y], mundoItens[i][mItem_z])) continue;
for(new i = 0; i < 13; i++){
if(Inventario[playerid][i] == 0)
Inventario[playerid][i] = itemid
PlayerTextDrawSetPreviewModel(playerid, ITENS_INV[i][playerid], serverItens[mundoItens[i][mItem_index]][sItem_modelo]);
break;
}
DestroyObject(mundoItens[GetPVarInt(playerid, "mundoItens_index_ativo")][mItem_createObject]);
Delete3DTextLabel(mundoItens[GetPVarInt(playerid, "mundoItens_index_ativo")][mItem_text3d]);
SendClientMessage(playerid, -1,"Voce Pegou 1 Item Esta em Seu Inventario !");
SetPVarInt(playerid, "mundoItens_index_ativo", i);
ApplyAnimation(playerid, "BOMBER", "BOM_PLANT_IN", 10000.0, 0, 0, 0, 0, 0);
break;
}
return 1;
}
PHP код:
C:\Users\Usuario\Desktop\THE DM\gamemodes\criarportao.pwn(432) : warning 219: local variable "i" shadows a variable at a preceding level
C:\Users\Usuario\Desktop\THE DM\gamemodes\criarportao.pwn(434) : error 001: expected token: ";", but found ")"
C:\Users\Usuario\Desktop\THE DM\gamemodes\criarportao.pwn(434) : error 029: invalid expression, assumed zero
C:\Users\Usuario\Desktop\THE DM\gamemodes\criarportao.pwn(434) : warning 215: expression has no effect
Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase
2 Errors.