Exemplo n.º 1
0
 public CmdFireBallResponse(int side, int type, Vector2 startPosition, Vector2 dir, Vector2 collisionPoint, GridPosition destGrid, int ballId, float speed, int result) : this()
 {
     CmdData                                   = new StructBattleCommand();
     CmdData.Side                              = (sbyte)side;
     CmdData.Type                              = (int)Type;
     CmdData.FireBallResponse                  = new FireBallResponse();
     CmdData.FireBallResponse.Type             = type;
     CmdData.FireBallResponse.StartPosition    = new Vector2D();
     CmdData.FireBallResponse.StartPosition.X  = startPosition.x;
     CmdData.FireBallResponse.StartPosition.Y  = startPosition.y;
     CmdData.FireBallResponse.Dir              = new Vector2D();
     CmdData.FireBallResponse.Dir.X            = dir.x;
     CmdData.FireBallResponse.Dir.Y            = dir.y;
     CmdData.FireBallResponse.CollisionPoint   = new Vector2D();
     CmdData.FireBallResponse.CollisionPoint.X = collisionPoint.x;
     CmdData.FireBallResponse.CollisionPoint.Y = collisionPoint.y;
     CmdData.FireBallResponse.DestGrid         = new GridCoord();
     CmdData.FireBallResponse.DestGrid.Col     = destGrid.col;
     CmdData.FireBallResponse.DestGrid.Row     = destGrid.row;
     CmdData.FireBallResponse.BallId           = ballId;
     CmdData.FireBallResponse.Speed            = speed;
     CmdData.FireBallResponse.Result           = (sbyte)result;
 }
Exemplo n.º 2
0
 public CmdFireBall(int side, int type, Vector2 startPosition, Vector2 dir, Vector2 collisionPoint, GridPosition destGrid, bool isFlyout, float speed) : this()
 {
     CmdData                           = new StructBattleCommand();
     CmdData.Side                      = (sbyte)side;
     CmdData.Type                      = (int)Type;
     CmdData.FireBall                  = new FireBall();
     CmdData.FireBall.Type             = type;
     CmdData.FireBall.StartPosition    = new Vector2D();
     CmdData.FireBall.StartPosition.X  = startPosition.x;
     CmdData.FireBall.StartPosition.Y  = startPosition.y;
     CmdData.FireBall.Dir              = new Vector2D();
     CmdData.FireBall.Dir.X            = dir.x;
     CmdData.FireBall.Dir.Y            = dir.y;
     CmdData.FireBall.CollisionPoint   = new Vector2D();
     CmdData.FireBall.CollisionPoint.X = collisionPoint.x;
     CmdData.FireBall.CollisionPoint.Y = collisionPoint.y;
     CmdData.FireBall.DestGrid         = new GridCoord();
     CmdData.FireBall.DestGrid.Col     = destGrid.col;
     CmdData.FireBall.DestGrid.Row     = destGrid.row;
     CmdData.FireBall.IsFlyout         = isFlyout;
     CmdData.FireBall.Speed            = speed;
 }