Esempio n. 1
0
        public bool Execute(Universe universe)
        {
            squadList.GetMeetingPoint(squadAlfaId, squadDeltaId);

            var meetingPoint = squadList.GetMeetingPoint(squadAlfaId, squadDeltaId);

            actions.ActionSelectSquad(squadAlfaId);
            actions.ActionMoveSelectionToPosition(meetingPoint);
            squadList.GetSquadById(squadAlfaId).UpdateLastCallTime(MyStrategy.Universe.World.TickIndex);

            actions.ActionSelectSquad(squadDeltaId);
            actions.ActionMoveSelectionToPosition(meetingPoint);
            squadList.GetSquadById(squadDeltaId).UpdateLastCallTime(MyStrategy.Universe.World.TickIndex);
            return(true);
        }
Esempio n. 2
0
        internal void DoStop(Queue <IMoveAction> actions)
        {
            actions.ActionSelectSquad(Id);
            actions.ActionMoveSelectionToPosition(SquadCenter);

            UpdateLastCallTime(MyStrategy.Universe.World.TickIndex);
        }
Esempio n. 3
0
        //public double AirEnergy => (AirForce + AirDefence) / DispersionSquared;
        //public double AirEnergyRelative => AirEnergy / StartAirEnergy;
        //public double GroundEnergyRelative => GroundEnergy / StartGroundEnergy;
        //public double GroundEnergy => (GroundForce + GroundDefence) / DispersionSquared;

        //public double Energy => GroundEnergy + AirEnergy;

        #endregion

        #region Actions

        internal void DoMove(Queue <IMoveAction> actions, AbsolutePosition position)
        {
            if (NukeMarkerCounter == 0)
            {
                actions.ActionSelectSquad(Id);
                actions.ActionMoveSelectionToPosition(position);
            }
            else
            {
                MyStrategy.Universe.Print($"Squad {(Squads)Id} is locked due to Nuke marker.");
            }
            UpdateLastCallTime(MyStrategy.Universe.World.TickIndex);
        }
Esempio n. 4
0
 internal void DoFollow(Queue <IMoveAction> actions, Squad thisSquad, Squad targetSquad)
 {
     actions.ActionSelectSquad(thisSquad.Id);
     actions.ActionMoveSelectionToPosition(targetSquad.SquadCenter);
     UpdateLastCallTime(MyStrategy.Universe.World.TickIndex);
 }