Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function PlayerVehicleStartUp ( Player )
- if (Player.nextStartUp && Player.nextStartUp > CurTime()) then return; end
- if (Player:GetVehicle().IsPassengerSeat) then return; end
- local currentVehicle = Player:GetVehicle()
- local vehicleCheck = Player:GetVehicle().vehicleTable;
- if currentVehicle:GetTable().Disabled then
- Player:Notify('This vehicle has been disabled in an accident.');
- return;
- end
- if (vehicleCheck && vehicleCheck.Script == "veyron") then
- if (!VehicleIgnitionOn) then
- VehicleIgnitionOn = true;
- currentVehicle:EmitSound("perp3.0/vehicle/engine/veyron_ignitionstart.wav", 100, 100);
- currentVehicle:Fire('turnon', '', 3);
- Player.nextStartUp = CurTime() + 4;
- else
- VehicleIgnitionOn = nil;
- currentVehicle:EmitSound("Vehicles/golf/v8_stop1.wav", 100, 100);
- currentVehicle:Fire('turnoff', '', 0);
- Player.nextStartUp = CurTime() + 2;
- end;
- elseif (vehicleCheck && vehicleCheck.Script != "veyron") then
- if (!VehicleIgnitionOn) then
- VehicleIgnitionOn = true;
- currentVehicle:EmitSound("Vehicles/Lambo/Start.wav", 100, 100);
- currentVehicle:Fire('turnon', '', 6);
- Player.nextStartUp = CurTime() + 7;
- else
- VehicleIgnitionOn = nil;
- currentVehicle:EmitSound("Vehicles/golf/v8_stop1.wav", 100, 100);
- currentVehicle:Fire('turnoff', '', 0);
- Player.nextStartUp = CurTime() + 2;
- end;
- end;
- end;
- concommand.Add("perp_v_su", PlayerVehicleStartUp);
Add Comment
Please, Sign In to add comment