05/06/22 15:18:06 KWsRNgPO
////////////////////////////////////////////
class Ship{ //戦闘機の親クラス
private:
int x; //x座標
int y; //y座標
public:
virtual int move(float); //動きの仮想関数
}:
class MyShip :public Ship{ //自機クラス
private:
int power; //パワーアップしているかどうか
int bomb; //ボム
int left; //残機
public:
int move(float); //動きの実体
int damage(); //敵機、玉、壁にぶつかった時
};
class EnemyShip :public Ship{
private:
int num; //ナンバリング
public:
int move(float); //動きの実体
};
////////////////////////////////////////////////
//こんな感じ?
//おれの知識ではこれが精一杯