11.04.2015, 23:36
Hello dear samp members. I need some help with falowing code and errors..
Thank you for your help with best regards Scrillex.
pawn Код:
(1134) : error 008: must be a constant expression; assumed zero
(1140 -- 1141) : error 032: array index out of bounds (variable "pInfo")
(1146) : error 032: array index out of bounds (variable "pInfo")
pawn Код:
public OnPlayerEditAttachedObject( playerid, response, pInfo[playerid][indextoy], pInfo[playerid][modelidtoy], pInfo[playerid][boneid],
pInfo[playerid][fOffsetX], pInfo[playerid][fOffsetY], pInfo[playerid][fOffsetZ],
pInfo[playerid][fRotX], pInfo[playerid][fRotY], pInfo[playerid][fRotZ],
pInfo[playerid][fScaleX], pInfo[playerid][fScaleY], pInfo[playerid][fScaleZ] )//THIS LINE!!!!!!!
{
new debug_string[256+1];
format(debug_string,256,"SetPlayerAttachedObject(playerid,%d,%d,%d,%f,%f,%f,%f,%f,%f,%f,%f,%f)",//THIS LINE!!!
pInfo[playerid][indextoy],pInfo[playerid][modelidtoy],pInfo[playerid][boneid],pInfo[playerid][fOffsetX],pInfo[playerid][fOffsetY],pInfo[playerid][fOffsetZ],pInfo[playerid][fRotX],pInfo[playerid][fRotY],pInfo[playerid][fRotZ],pInfo[playerid][fScaleX],pInfo[playerid][fScaleY],pInfo[playerid][fScaleZ]);//THIS LINE!!!!
print(debug_string);
//SendClientMessage(playerid, 0xFFFFFFFF, debug_string);
SetPlayerAttachedObject(playerid,pInfo[playerid][indextoy],pInfo[playerid][modelidtoy],
pInfo[playerid][boneid],pInfo[playerid][fOffsetX],pInfo[playerid][fOffsetY],
pInfo[playerid][fOffsetZ],pInfo[playerid][fRotX],pInfo[playerid][fRotY],pInfo[playerid][fRotZ],
pInfo[playerid][fScaleX],pInfo[playerid][fScaleY],pInfo[playerid][fScaleZ]);
SendClientMessage(playerid, 0xFFFFFFFF, "You finished editing an attached object"); //THIS LINE
return 1;
}