public CombatHelper(IHommRobot robot) { this.robot = robot; world = robot.World; player = robot.Player; hommEngine = world.HommEngine; commonEngine = world.CommonEngine; }
public RoundToUnityConnecter(IHommEngine hommEngine, ICommonEngine commonEngine, IHommUserInterfaceEngine uiEngine, HommObjectsCreationHelper objectsCreationHelper) { this.uiEngine = uiEngine; this.hommEngine = hommEngine; this.commonEngine = commonEngine; this.objectsCreationHelper = objectsCreationHelper; }
public MovementHelper(IHommRobot robot, Direction movementDirection) { this.robot = robot; this.movementDirection = movementDirection; world = robot.World; hommEngine = world.HommEngine; commonEngine = world.CommonEngine; player = robot.Player; map = world.Round.Map; newLocation = player.Location.NeighborAt(movementDirection); movementDuration = GetTravelDuration(player, map); }
public Tuple <Location, double> TryMoveHero(IHommEngine engine, Player player, Map map) { var newLocation = player.Location.NeighborAt(MovementDirection); var turnDuration = GetTravelDuration(player, map); var travelIsPossible = newLocation.IsInside(map.Size) && (map[newLocation].tileObject?.IsPassable ?? false); if (travelIsPossible) { engine.Move(player.Name, MovementDirection, turnDuration); return(Tuple.Create(newLocation, turnDuration)); } return(Tuple.Create(player.Location, turnDuration)); }
public HommObjectsCreationHelper(Random random, IHommEngine engine) { this.random = random; this.engine = engine; }
public Tuple <Location, double> TryMoveHero(IHommEngine engine, Player player, Map map) { return(Tuple.Create(player.Location, HommRules.Current.WaitDuration)); }