Example #1
0
        public SerializablePickup CreatePickup(SerializablePickup orig)
        {
            var tmpObject = new Rage.Object(new Model("prop_mp_repair"), orig.GetEntity().Position);
            tmpObject.Rotation = orig.GetEntity().Rotation;
            tmpObject.Position = orig.GetEntity().Position;
            tmpObject.IsPositionFrozen = true;

            var tmpObj = (SerializablePickup)orig.Clone();
            tmpObj.SetEntity(tmpObject);
            CurrentMission.Pickups.Add(tmpObj);
            return tmpObj;
        }
Example #2
0
        public SerializableObject CreatePickup(int weaponHash, Vector3 pos, Rotator rot)
        {
            var tmpObject = new Rage.Object(new Model("prop_mp_repair"), pos);
            tmpObject.Rotation = rot;
            tmpObject.Position = pos;
            tmpObject.IsPositionFrozen = true;

            var tmpObj = new SerializablePickup();
            tmpObj.SetEntity(tmpObject);
            tmpObj.SpawnAfter = 0;
            tmpObj.RemoveAfter = 0;
            tmpObj.Respawn = false;
            tmpObj.Ammo = 9999;
            tmpObj.PickupHash = weaponHash;
            CurrentMission.Pickups.Add(tmpObj);
            return tmpObj;
        }