public void RemovePiece(HexLocation location) { ZertzRingRenderer zrr = this.boardR.RemoveRing(location); Vector3 via = this.zcr.MinimalTile.TileEscapeLocation; Vector3 des = this.zcr.MinimalTile.NextVector; this.zcr.MinimalTile.Add(zrr); zrr.RenderMover = RenderMoveManager.GenerateReverseHopMover(zrr.Location, via, 1.0f, RenderMoveManager.GenerateMoveMover(via, des, 2.0f, null)); //,RenderMoveManager.GenerateStaticMover(des) }
public override void OnLoad(EventArgs e) { this.ti.OnLoad(e); this.si.CurrentState = 0x00; this.si.OnLoad(e); this.zcr.OnLoad(e); ZertzBallRenderer.GenerateBalls(ZertzBallContainer.Offset(), this.rc, this.zcr, 0x00); ZertzRingRenderer.GenerateRings(this.rc, this.boardR, this.game, this.zcr, this.hls, 0x40); this.OnResize(e); //this.rc.Add(0x100,); }
public void SelectedItem(ISelectable sel) { if (sel == null) { return; } try { if (sel is ZertzBallRenderer) { ZertzBallRenderer zbr = (ZertzBallRenderer)sel; if (zbr.Container != ZertzBallContainerType.None) { this.game.TakeBall(zbr.Type); } } else if (sel is ZertzRingRenderer) { ZertzRingRenderer zrr = (ZertzRingRenderer)sel; this.game.SelectPiece(zrr.HexLocation); } else if (sel is LinuxFlag) { if (this.state == SceneActionState.Select) { this.state = SceneActionState.Caputure; } else { this.game.EndTurn(); } } } catch (Exception e) { Console.WriteLine(e); this.MessageBoard.PostMessage(this, e.Message); } }