public Player(int _h = 7, int _v = 7) { this.pos_v = _v; this.pos_h = _h; this.liftUpELemStack = new Stack <ElementBase>(); this.gsm = GameStatusManger.GetInstance(); }
public ElementBase(int v, int h, int rt = -1) { this.pos_h = h; this.pos_v = v; this.remain_time = rt; this.gsm = GameStatusManger.GetInstance(); }
public Game(int scence_h_size = 55, int scence_v_size = 35) { SenceWidth = scence_h_size; SenceHeigth = scence_v_size; StageManager.LoadAllStage(); this.stage = StageManager.GetStageByIdx(0); this.gsm = GameStatusManger.GetInstance(); // gsm.Inital(); this.gsm.stage = this.stage; // TODO: adopt the new draw system // new draw buffer stagecanvas = new ConsoleCanvas(SenceWidth, SenceHeigth, anchor_h: 2, anchor_v: 2); gameMsgUI = new GameMsgUI(SenceWidth, 10, anchor_v: SenceHeigth + 2, anchor_h: 2); playerStatusUI = new PlayerStatusMsgUI(30, SenceHeigth, anchor_v: 2, anchor_h: 2 * (SenceWidth + 1) + 2); // gameMsgCanvas = new ConsoleCanvas(SenceWidth, 10, anchor_v: SenceHeigth + 2, anchor_h: 2); // playerStatusUICanvas = new ConsoleCanvas(25, SenceHeigth, anchor_v: 2, anchor_h: 2*(SenceWidth+1) + 2); draw_buffer = stagecanvas.GetBuffer(); color_buffer = stagecanvas.GetColorBuffer(); stagecanvas.drawEdge(); gameMsgUI.canvas.drawEdge(); playerStatusUI.canvas.drawEdge(); BulletManager.gsm = this.gsm; }