mirror of
https://github.com/openfrontio/OpenFrontIO.git
synced 2026-07-19 09:04:59 +00:00
combine Game & MutableGame
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
import { AllianceRequest, Cell, Difficulty, Execution, MutableGame, Player, PlayerInfo, PlayerType, Relation, TerrainType, TerraNullius, UnitType } from "../game/Game"
|
||||
import { AllianceRequest, Cell, Difficulty, Execution, Game, Player, PlayerInfo, PlayerType, Relation, TerrainType, TerraNullius, UnitType } from "../game/Game"
|
||||
import { PseudoRandom } from "../PseudoRandom"
|
||||
import { AttackExecution } from "./AttackExecution";
|
||||
import { TransportShipExecution } from "./TransportShipExecution";
|
||||
@@ -23,7 +23,7 @@ export class FakeHumanExecution implements Execution {
|
||||
|
||||
private active = true
|
||||
private random: PseudoRandom;
|
||||
private mg: MutableGame
|
||||
private mg: Game
|
||||
private player: Player = null
|
||||
|
||||
private enemy: Player | null = null
|
||||
@@ -36,7 +36,7 @@ export class FakeHumanExecution implements Execution {
|
||||
this.random = new PseudoRandom(simpleHash(playerInfo.id) + simpleHash(gameID))
|
||||
}
|
||||
|
||||
init(mg: MutableGame, ticks: number) {
|
||||
init(mg: Game, ticks: number) {
|
||||
this.mg = mg
|
||||
if (this.random.chance(10)) {
|
||||
// this.isTraitor = true
|
||||
|
||||
Reference in New Issue
Block a user