Beispiel #1
0
        public override void Process()
        {
            base.Process();
            if (CalloutsPlusMain.RepairEngineModifierKey == Keys.None) //Checks to see if the modifier is None
            {
                if (Functions.IsKeyDown(CalloutsPlusMain.RepairEngineKey))
                {
                    BreakdownObj.RepairVehicle(vehicle1);
                }
            }
            else
            {
                if (Functions.IsKeyStillDown(CalloutsPlusMain.RepairEngineModifierKey) && Functions.IsKeyDown(CalloutsPlusMain.RepairEngineKey))
                {
                    BreakdownObj.RepairVehicle(vehicle1);
                }
            }

            if (this.vehicle1.Exists())
            {
                if (this.vehicle1.EngineHealth > 60)
                {
                    Functions.PrintHelp("The vehicle's engine is fixed, order the pedestrian to get back in his vehicle or deal with him however you choose.");
                    Functions.SetPedIsOwnedByScript(driver, this, false);
                    this.driver.Task.StandStill(-1);
                    this.End();
                }
            }
            else
            {
                this.End();
            }
        }