Trailers respawning.
#1

Hello.

I am in middle of a personal project of scripting a server from scratch, I've made factions and what not and the first job I'm making is trucking. I'm well into it, however I'd like the trailer to despawn as I deliver the truck. At the moment this happens:
[ame]http://www.youtube.com/watch?v=9Yl782Ayfbk[/ame]

Is there a way to get the trailer despawned aswell?

This is my current code:

pawn Code:
if(truckloaded[playerid] == 2 && CPT[playerid] == 3)
        {
            SendClientMessage(playerid, COLOR_GREEN, "You've returned the truck. You got a skill point and $50 extra.");
            PlayerInfo[playerid][pCash] += 50;
            PlayerInfo[playerid][pTruckerSkill] += 1;
            truckloaded[playerid] = 0;
            DisablePlayerCheckpoint(playerid);
            CPT[playerid] = 0;
            new vehicleid = GetPlayerVehicleID(playerid);
            if(GetPlayerState(playerid) == PLAYER_STATE_DRIVER)
            {
            if(IsATruck(vehicleid)) SetVehicleToRespawn(vehicleid);
            }
            return 1;
            }
Reply


Messages In This Thread
Trailers respawning. - by Why - 01.09.2012, 23:55
Re: Trailers respawning. - by MarkoN - 02.09.2012, 00:05
Re: Trailers respawning. - by Why - 02.09.2012, 00:19
Re: Trailers respawning. - by ddnbb - 02.09.2012, 00:21
Re: Trailers respawning. - by MarkoN - 02.09.2012, 00:28

Forum Jump:


Users browsing this thread: 1 Guest(s)