Game-Design / Sprint2 / Sprint2_actual / Commands / PreviousNPCCommand.cs
PreviousNPCCommand.cs
Raw
using System;
using System.Collections.Generic;
using System.Text;
using System;
namespace Sprint2_actual.Commands
{
    public class PreviousNPCCommand:ICommand
    {
        private Game1 game1;

        public PreviousNPCCommand(Game1 game) //Could change this to pass only the NPC class when created
        {
            this.game1 = game;
        }

        public void Execute()
        {
            //Go to the previous Enemy NPC that is created from factory for enemies
            game1.Npc.PrevSprite();
        }
    }
}