예제 #1
0
 public State(ImmutableState imm)
 {
     DungeonStart  = imm.DungeonStart.Replicate();
     Entities      = new EntityDictionary(imm.Entities);
     CurrentActor  = imm.CurrentActor;
     StepsLeft     = imm.StepsLeft;
     StepsTaken    = imm.StepsTaken;
     Cursor        = imm.Cursor;
     Camera        = imm.Camera;
     CurrentReason = imm.CurrentReason;
     Initiative    = new Schedule(imm.Initiative);
     TurnsLeft     = imm.TurnsLeft;
     XSSRState     = new ulong[] { imm.XSSRState[0], imm.XSSRState[1] };
 }
예제 #2
0
 public ImmutableState(Dungeon dungeon, EntityDictionary entities, string currentActor, int stepsLeft,
                       int stepsTaken,
                       Position cursor, Position camera, WaitReason currentReason, Schedule initiative, long turnsLeft,
                       ulong[] xssrState)
 {
     DungeonStart  = dungeon;
     Entities      = entities.ToImmutable();
     CurrentActor  = currentActor;
     StepsLeft     = stepsLeft;
     StepsTaken    = stepsTaken;
     Cursor        = cursor;
     Camera        = camera;
     CurrentReason = currentReason;
     Initiative    = initiative.Scheduled.ToImmutableSortedDictionary();
     TurnsLeft     = turnsLeft;
     XSSRState     = xssrState;
 }