public AzioneMovimento(Quantum quantum, Casella casellaPartenza, bool puòAttaccare = true) { this.casellaPartenza = casellaPartenza; naveMossa = casellaPartenza.Occupante; this.quantum = quantum; this.puòAttaccare = puòAttaccare; // Faccio partire il pathfinder pathFinder = new PathFinder(); pathFinder.Start(this.casellaPartenza, naveMossa.MuoveInDiagonale); // Illumino le caselle raggiungibili int[] caselleRaggiungibili = Tile.Tiles(t => { Casella casella = t as Casella; int d = pathFinder.DistanzaCasella(t); return (d <= naveMossa.Pwr && d > 0 && (puòAttaccare || (casella != null && casella.Occupante == null) )); } ).Select(t => t.ID).ToArray(); quantum.getGUI().Tabellone.ResetSelezioneMouse(); quantum.getGUI().Tabellone.IlluminaCaselle(caselleRaggiungibili); }