Guten Abend,
folgende Meldung erhalte ich als Warnung, es geht um den public content.
selfmade.pwn(59986) : warning 219: local variable "modelid" shadows a variable at a preceding level
public OnPlayerEditAttachedObject(playerid, response, index, modelid, boneid, Float:fOffsetX, Float:fOffsetY, Float:fOffsetZ, Float:fRotX, Float:fRotY, Float:fRotZ, Float:fScaleX, Float:fScaleY, Float:fScaleZ)
{
if(GetPVarInt(playerid, "EditingNow") == 1)
{
new i = GetPVarInt(playerid, "EditingSlot");
if(response)
{
dynClothesInfo[playerid][i][cOffsetX] = fOffsetX;
dynClothesInfo[playerid][i][cOffsetY] = fOffsetY;
dynClothesInfo[playerid][i][cOffsetZ] = fOffsetZ;
dynClothesInfo[playerid][i][cRotX] = fRotX;
dynClothesInfo[playerid][i][cRotY] = fRotY;
dynClothesInfo[playerid][i][cRotZ] = fRotZ;
dynClothesInfo[playerid][i][cScaleX] = fScaleX;
dynClothesInfo[playerid][i][cScaleY] = fScaleY;
dynClothesInfo[playerid][i][cScaleZ] = fScaleZ;
}
DeletePVar(playerid, "EditingSlot");
DeletePVar(playerid, "EditingNow");
ReplaceClothing(playerid, i);
}
if(GetPVarInt(playerid, "SelectedItem") == 1 && GetPVarInt(playerid, "EditingNow") == 0)
{
new i = GetPVarInt(playerid, "ItemIndex");
new slot = GetPVarInt(playerid, "FreeSlot");
if(response)
{
OnBuyClothes(playerid, slot, ModelsInfo[i][modelID], ModelsInfo[i][modelBone], fOffsetX, fOffsetY, fOffsetZ, fRotX, fRotY, fRotZ, fScaleX, fScaleY, fScaleZ);
ACMoney(playerid, -ModelsInfo[i][modelPrice]);
format(clothesmsg, sizeof(clothesmsg), "Du hast dir ein(e) {FFFF00}%s{FFFFFF} für {FFFF00}%d${FFFFFF} gekauft.", ModelsInfo[i][modelName], ModelsInfo[i][modelPrice]);
SendClientMessage(playerid, -1, clothesmsg);
dynClothesInfo[playerid][slot][cModelID] = ModelsInfo[i][modelID];
dynClothesInfo[playerid][slot][cBoneID] = ModelsInfo[i][modelBone];
dynClothesInfo[playerid][slot][cOffsetX] = fOffsetX;
dynClothesInfo[playerid][slot][cOffsetY] = fOffsetY;
dynClothesInfo[playerid][slot][cOffsetZ] = fOffsetZ;
dynClothesInfo[playerid][slot][cRotX] = fRotX;
dynClothesInfo[playerid][slot][cRotY] = fRotY;
dynClothesInfo[playerid][slot][cRotZ] = fRotZ;
dynClothesInfo[playerid][slot][cScaleX] = fScaleX;
dynClothesInfo[playerid][slot][cScaleY] = fScaleY;
dynClothesInfo[playerid][slot][cScaleZ] = fScaleZ;
dynClothesInfo[playerid][slot][cOn] = true;
}
else
{
SendClientMessage(playerid, ROT, "Du hast den Kauf diesen Artikels abgebrochen.");
RemovePlayerAttachedObject(playerid, index);
}
DeletePVar(playerid, "SelectedItem");
DeletePVar(playerid, "ItemIndex");
DeletePVar(playerid, "FreeSlot");
}
return 1;
}