28.06.2012, 08:21
Function:
Errors:
Lines:
pawn Код:
stock LoadAttachment(playerid)
{
new str[50];
GetPlayerName(playerid,str,50);
format(str,50,"attachment/%s.ini",str);
new File:f =fopen(str,io_read);
new string[256+1];
fread(string,256);
new tmp[12][128];
split(string, tmp, ',');
new index, modelid, boneid,
Float:fOffsetX, Float:fOffsetY, Float:fOffsetZ,
Float:fRotX, Float:fRotY, Float:fRotZ,
Float:fScaleX, Float:fScaleY, Float:fScaleZ;
index = strval(tmp[0]);
modelid = strval(tmp[1]);
boneid = strval(tmp[2]);
fOffsetX = floatstr(tmp[3]);
fOffsetY = floatstr(tmp[4]);
fOffsetZ = floatstr(tmp[5]);
fRotX = floatstr(tmp[6]);
fRotY = floatstr(tmp[7]);
fRotZ = floatstr(tmp[8]);
fScaleX = floatstr(tmp[9]);
fScaleY = floatstr(tmp[10]);
fScaleZ = floatstr(tmp[11]);
SetPlayerAttachedObject(playerid,index,modelid,boneid,fOffsetX,fOffsetY,fOffsetZ,fRotX,fRotY,fRotZ,fScaleX,fScaleY,fScaleZ);
SendClientMessage(playerid, 0xFFFFFFFF, "Your Saved Attachement Loaded!");
return 1;
}
pawn Код:
D:\Lucru\1.3 samp 0.3e\gamemodes\MAPA PALAMINO.pwn(397) : error 035: argument type mismatch (argument 1)
D:\Lucru\1.3 samp 0.3e\gamemodes\MAPA PALAMINO.pwn(395) : warning 204: symbol is assigned a value that is never used: "f"
pawn Код:
397: fread(string,256);
395: new File:f =fopen(str,io_read);