ProxDetector Error?
#1

Alright, I am wanting a message to show when a player powers on their vehicle within a radius of 20, but I keep getting this error:

Код:
C:\Documents and Settings\nmader\Desktop\Lost Roleplay\filterscripts\Engine.pwn(416) : error 004: function "ProxDetector" is not implemented
I do have it forwarded and everything:

pawn Код:
forward ProxDetector(Float:radi, playerid, string[],col1,col2,col3,col4,col5);
forward ProxDetectorS(Float:radi, playerid, targetid);
Right at the beginning of the script after everything is defined.

pawn Код:
public OnPlayerKeyStateChange(playerid, newkeys, oldkeys)
{
    new engineStatus[MAX_VEHICLES];
    if(newkeys & KEY_HANDBRAKE && GetPlayerState(playerid) == PLAYER_STATE_DRIVER)
    {
        #define GREY 0xCECECEFF
        #define COLOR_PURPLE 0xC2A2DAAA
        new vehicle = GetPlayerVehicleID(playerid);
        new Engine[MAX_VEHICLES], Lights[MAX_VEHICLES];
        if(Engine[vehicle] == 0)
        {
            new string[128];
            new sendername[MAX_PLAYER_NAME];
            new engine, lights, alarm, doors, bonnet, boot, objective;
            Engine[vehicle] = 1;
            GetVehicleParamsEx(vehicle, engine, lights, alarm, doors, bonnet, boot, objective);//This bit is checking the current status of the vehicles.
            SetVehicleParamsEx(vehicle, 1, lights, alarm, doors, bonnet, boot, 0);
            GameTextForPlayer(playerid, "~G~Engine On!", 5000, 4);
            format(string, sizeof(string), "*%s turns the key of their vehicle, powering it on!", sendername);
            ProxDetector(20.0, playerid, string,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
        }
        else
        {
            SendClientMessage(playerid, GREY, "This vehicle's engine is already on, use /eoff to turn it on!");//This will display on the screen if the engine is already off.
        }
    }
    return 1;
}
Reply
#2

This is incorrect.
pawn Код:
forward ProxDetector(Float:radi, playerid, string[],col1,col2,col3,col4,col5);
forward ProxDetector(Float:radi, playerid, targetid);
I've never used ProxDetector, but I know this is how forward and public functions work. forwarding it twice will simply not work.
pawn Код:
forward ProxDetector(Float:radi, playerid, string[],col1,col2,col3,col4,col5);
public ProxDetector(Float:radi, playerid, string[],col1,col2,col3,col4,col5)
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)