Пример #1
0
        public SerializableActorObjective CreatePedObjective(Model model, Vector3 pos, float heading)
        {
            var tmpPed = new Ped(model, pos, heading);
            tmpPed.IsPositionFrozen = false;
            tmpPed.BlockPermanentEvents = true;

            var blip = tmpPed.AttachBlip();
            blip.Color = Color.Red;
            blip.Scale = 0.7f;
            _blips.Add(blip);

            var tmpObj = new SerializableActorObjective();
            tmpObj.SetPed(tmpPed);
            tmpObj.SpawnAfter = 0;
            tmpObj.ActivateAfter = 0;
            tmpObj.Behaviour = 2;
            tmpObj.RelationshipGroup = 5;
            tmpObj.WeaponAmmo = 9999;
            tmpObj.WeaponHash = 0;
            tmpObj.Health = 200;
            tmpObj.Accuracy = 50;
            tmpObj.Armor = 0;
            tmpObj.SpawnInVehicle = false;
            tmpObj.Waypoints = new List<SerializableWaypoint>();
            CurrentMission.Objectives.Add(tmpObj);
            return tmpObj;
        }
Пример #2
0
        public SerializableActorObjective CreatePedObjective(SerializableActorObjective orig)
        {
            var tmpPed = new Ped(orig.GetPed().Model, orig.GetPed().Position - new Vector3(0,0,1), orig.GetPed().Rotation.Yaw);
            tmpPed.IsPositionFrozen = false;
            tmpPed.BlockPermanentEvents = true;

            var blip = tmpPed.AttachBlip();
            blip.Color = Color.Red;
            blip.Scale = 0.7f;
            _blips.Add(blip);

            var tmpObj = (SerializableActorObjective)orig.Clone();
            tmpObj.SetPed(tmpPed);
            CurrentMission.Objectives.Add(tmpObj);
            return tmpObj;
        }
Пример #3
0
 public WaypointEditor(SerializableActorObjective actor) : this()
 {
     _mainPed = null;
     _mainActorObjective = actor;
 }