package extend.zp.player.state;

import com.game.state.StateBase;

import extend.zp.EXActionEvent;
import extend.zp.EXMainServer;
import extend.zp.EXPlayer;
import extend.zp.PlayerRuleManager;


public class EXPlayerWaitState extends StateBase<EXPlayer> {


	
	@Override
	public void execute(EXPlayer owner, String cmd, int gid, Object param) {
		switch (cmd) {
		case EXActionEvent.EVENT_OTHER_DISCARD:
			EXMainServer.playerRuleMgr.condition(PlayerRuleManager.OTHER_DISCARD_RULE , owner);
			break;
		case EXActionEvent.EVENT_OTHER_DRAW:
			EXMainServer.playerRuleMgr.condition(PlayerRuleManager.DRAW_RULE , owner);
			break;
		case EXActionEvent.EVENT_WIN:
			EXMainServer.playerRuleMgr.condition(PlayerRuleManager.WIN_RULE , owner);
			break;
			
		default:
			break;
		}
		
	}

}
