Error when compile. -
deltapro - 22.02.2012
Hello i just make /fcar park commands which means that just leader (boss) of factions can park faction vehicle.
And WHen i comppile i get this:
pawn Код:
(28594) : error 004: function "SetCarPos" is not implemented
And here is the lines:
pawn Код:
if(strcmp(cmd, "/fcar", true) == 0)
{
if(IsPlayerConnected(playerid))
{
if(IsAMember(playerid) || IsACop(playerid) || PlayerInfo[playerid][pMember] == 10 || PlayerInfo[playerid][pMember] == 3)
{
new fam = PlayerInfo[playerid][pMember];
new x_job[256];
x_job = mystrtok(cmdtext, idx);
if(!strlen(x_job))
{
SendClientMessage(playerid, COLOR_GREY,".: Usage: /fcar [tow/more soon] :.");
return 1;
}
if(strcmp(x_job,"tow",true) == 0)
{
if(IsHighRank(playerid))
{
GivePlayerMoney(playerid,-10000);
Money[playerid] -= 10000;
FamilyInfo[fam][fMoney] += 10000;
RespawnFactionVehicles(playerid);
}
}
if(strcmp(x_job,"park",true) == 0)
{
if(IsHighRank(playerid))
{
GivePlayerMoney(playerid,-10000);
Money[playerid] -= 10000;
FamilyInfo[fam][fMoney] += 10000;
SetCarPos(carid);
}
}
Please tell me what should i do.
Re: Error when compile. -
Toreno - 22.02.2012
You're missing a stock, SetCarPos().
Re : Error when compile. -
deltapro - 22.02.2012
Still geting same error..
Re: Error when compile. -
Toreno - 22.02.2012
And what did you do exactly? All I was telling you is, that you're missing a stock.
Re : Error when compile. -
deltapro - 22.02.2012
I maked on top of my script
stock SetCarPos;
____________________
Sorry i am new in scriping
Re: Error when compile. -
Konstantinos - 22.02.2012
pawn Код:
stock SetCarPos( carid )
{
// Code
}
At the // Code, write code of what you want to do with this function.
Re : Error when compile. -
deltapro - 22.02.2012
I cant fix it. I still get same error.
Re: Error when compile. -
Konstantinos - 22.02.2012
Delete
stock SetCarPos;
pawn Код:
stock SetCarPos(playerid, Float:Vx, Float:Vy, Float:Vz, Float:Va, Float:Px, Float:Py, Float:Pz, Float:Pa, interior)
{
TogglePlayerControllable(playerid, 1);
if(GetPlayerState(playerid) == PLAYER_STATE_DRIVER)
{
SetVehiclePos(GetPlayerVehicleID(playerid),Vx,Vy,Vz);
SetVehicleZAngle(GetPlayerVehicleID(playerid),Va);
LinkVehicleToInterior(GetPlayerVehicleID(playerid),interior);
}
else
{
SetPlayerPos(playerid,Px,Py,Pz);
SetPlayerFacingAngle(playerid,Pa);
}
SetCameraBehindPlayer(playerid);
SetPlayerInterior(playerid, interior);
return 1;
}
And replace the SetCarPos(carid) to SetCarPos(playerid, Float:Vx, Float:Vy, Float:Vz, Float:Va, Float:Px, Float:Py, Float:Pz, Float:Pa, interior)
Since I don't know what exactly do you want this function does.