D'angband  0.0.0
Deeangband
 全て クラス 名前空間 ファイル 関数 変数 型定義 列挙型 列挙値 フレンド マクロ定義 ページ
Coordinates.cpp
[詳解]
1 
9 #include "stdafx.h"
10 #include "Coordinates.h"
11 
12 namespace Deeangband
13 {
14 
15  Coordinates::Coordinates(int x, int y)
16  {
17  this->fx = x;
18  this->fy = y;
19  }
20 
21  Coordinates::Coordinates(void)
22  {
23  this->fx = 0;
24  this->fy = 0;
25  }
26 
27  Coordinates::‾Coordinates(void)
28  {
29  }
30 
31  int Coordinates::GetX(void)
32  {
33  return this->fx;
34  }
35 
36  int Coordinates::GetY(void)
37  {
38  return this->fy;
39  }
40 
41  void Coordinates::Set(int x, int y)
42  {
43  this->fx = x;
44  this->fy = y;
45  }
46 
47  Coordinates Coordinates::operator=(const Coordinates& plus)
48  {
49  this->fx = plus.fx;
50  this->fy = plus.fy;
51  return *this;
52  }
53 
54  Coordinates Coordinates::operator+(const Coordinates& plus)
55  {
56  this->fx += plus.fx;
57  this->fy += plus.fy;
58  return *this;
59  }
60 
61  Coordinates& Coordinates::operator+=(const Coordinates& plus)
62  {
63  this->fx += plus.fx;
64  this->fy += plus.fy;
65  return *this;
66  }
67 
68 }
Coordinatesクラスとその他付随要素の定義
標準のシステム インクルード ファイルのインクルード ファイル、または 参照回数が多く、かつあまり変更さ...