Exemple #1
0
 private bool SetBoxMovedFlag(Box box)
 {
     bool flagAnyBoxWasMoved;
     lastAction.IsBoxMoved = true;
     lastAction.BoxID = box.ID;
     flagAnyBoxWasMoved = true;
     return flagAnyBoxWasMoved;
 }
Exemple #2
0
 private void BackBox(Box box)
 {
     level.SetEmpty(box.Position);
     box.Position -= lastAction.MoveVector;
     level.SetEmpty(box.Position, false);
 }
Exemple #3
0
        private bool MoveBox(Box box, Vector2 NextToBox, bool flagAnyBoxWasMoved)
        {
            box.Position = NextToBox;
            level.SetEmpty(NextToBox, false);
            level.SetEmpty(player.Position);

            flagAnyBoxWasMoved = SetBoxMovedFlag(box);
            return flagAnyBoxWasMoved;
        }