Changed again action that is called if timer runs out.

This commit is contained in:
LevelX2 2014-05-03 09:27:21 +02:00
parent 64f6c58887
commit c77c43a1b0

View file

@ -28,6 +28,24 @@
package mage.server.game; package mage.server.game;
import java.io.BufferedOutputStream;
import java.io.FileOutputStream;
import java.io.IOException;
import java.io.ObjectOutput;
import java.io.ObjectOutputStream;
import java.io.OutputStream;
import java.io.Serializable;
import java.util.Collection;
import java.util.HashSet;
import java.util.List;
import java.util.Map;
import java.util.Map.Entry;
import java.util.Set;
import java.util.UUID;
import java.util.concurrent.ConcurrentHashMap;
import java.util.concurrent.ExecutorService;
import java.util.concurrent.Future;
import java.util.zip.GZIPOutputStream;
import mage.MageException; import mage.MageException;
import mage.abilities.Ability; import mage.abilities.Ability;
import mage.cards.Card; import mage.cards.Card;
@ -46,26 +64,25 @@ import mage.game.events.TableEvent;
import mage.game.permanent.Permanent; import mage.game.permanent.Permanent;
import mage.interfaces.Action; import mage.interfaces.Action;
import mage.players.Player; import mage.players.Player;
import mage.server.*; import mage.server.ChatManager;
import mage.server.Main;
import mage.server.TableManager;
import mage.server.User;
import mage.server.UserManager;
import mage.server.util.ConfigSettings; import mage.server.util.ConfigSettings;
import mage.server.util.Splitter; import mage.server.util.Splitter;
import mage.server.util.SystemUtil; import mage.server.util.SystemUtil;
import mage.server.util.ThreadExecutor; import mage.server.util.ThreadExecutor;
import mage.utils.timer.PriorityTimer; import mage.utils.timer.PriorityTimer;
import mage.view.*; import mage.view.AbilityPickerView;
import mage.view.CardsView;
import mage.view.ChatMessage;
import mage.view.ChatMessage.MessageColor; import mage.view.ChatMessage.MessageColor;
import mage.view.ChatMessage.MessageType; import mage.view.ChatMessage.MessageType;
import mage.view.GameView;
import mage.view.PermanentView;
import org.apache.log4j.Logger; import org.apache.log4j.Logger;
import java.io.*;
import java.util.*;
import java.util.Map.Entry;
import java.util.concurrent.ConcurrentHashMap;
import java.util.concurrent.ExecutorService;
import java.util.concurrent.Future;
import java.util.zip.GZIPOutputStream;
/** /**
* *
* @author BetaSteward_at_googlemail.com * @author BetaSteward_at_googlemail.com
@ -251,7 +268,7 @@ public class GameController implements GameCallback {
Action executeOnNoTimeLeft = new Action() { Action executeOnNoTimeLeft = new Action() {
@Override @Override
public void execute() throws MageException { public void execute() throws MageException {
game.concede(initPlayerId); game.timerTimeout(initPlayerId);
logger.debug("Player has no time left to end the match: " + initPlayerId + ". Conceding."); logger.debug("Player has no time left to end the match: " + initPlayerId + ". Conceding.");
} }
}; };