代码拉取完成,页面将自动刷新
//
// Created by liaoyunjie on 24-5-20.
//
#ifndef PROP_H
#define PROP_H
#include "BaseFlyingObject.h"
#include "ImageManager.h"
class BaseProp : public BaseFlyingObject {
public:
BaseProp(FlyingObjectType type, int location_x, int location_y, int width,
int height)
: BaseFlyingObject(type, location_x, location_y, 0, PROP_SPEEDY, width,
height) {}
virtual void effect() = 0;
void forward() override;
int factor() const override { return 1; }
};
class BloodProp : public BaseProp {
public:
BloodProp(int location_x, int location_y)
: BaseProp(BLOOD_PROP, location_x, location_y,
ImageManager::BLOOD_PROP_IMAGE.width(),
ImageManager::BLOOD_PROP_IMAGE.height()) {}
void effect() override;
};
class BombProp : public BaseProp {
public:
BombProp(int location_x, int location_y)
: BaseProp(BOMB_PROP, location_x, location_y,
ImageManager::BOMB_PROP_IMAGE.width(),
ImageManager::BOMB_PROP_IMAGE.height()) {}
void effect() override;
};
class BulletProp : public BaseProp {
public:
BulletProp(int location_x, int location_y)
: BaseProp(BULLET_PROP, location_x, location_y,
ImageManager::BULLET_PROP_IMAGE.width(),
ImageManager::BULLET_PROP_IMAGE.height()) {}
void effect() override;
private:
static void recover();
};
#endif // PROP_H
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。