代码拉取完成,页面将自动刷新
同步操作将从 ibc-dabing/Landlords 强制同步,此操作会覆盖自 Fork 仓库以来所做的任何修改,且无法恢复!!!
确定后同步将在后台操作,完成时将刷新页面,请耐心等待。
#ifndef PLAYER_H
#define PLAYER_H
#include <QObject>
#include "cards.h"
class Player : public QObject
{
Q_OBJECT
public:
enum Role{Lord, Farmer}; // 角色
enum Sex{Man, Woman}; // 性别
enum Direction{Left, Right}; // 头像的显示方位
enum Type{Robot, User, UnKnow}; // 玩家的类型
explicit Player(QObject *parent = nullptr);
explicit Player(QString name, QObject *parent = nullptr);
void setName(QString name);
QString getName();
void setRole(Role role);
Role getRole();
void setSex(Sex sex);
Sex getSex();
void setDirection(Direction direction);
Direction getDirection();
void setType(Type type);
Type getType();
void setScore(int score);
int getScore();
void setWin(bool flag);
bool isWin();
void setPrevPlayer(Player* player);
void setNextPlayer(Player* player);
Player* getPrevPlayer();
Player* getNextPlayer();
void grabLordBet(int point);
void storeDispatchCard(const Card& card);
void storeDispatchCard(const Cards& cards);
Cards getCards();
void clearCards();
void playHand(const Cards& cards);
Player* getPendPlayer();
Cards getPendCards();
void storePendingInfo(Player* player, const Cards& cards);
virtual void prepareCallLord();
virtual void preparePlayHand();
virtual void thinkCallLord();
virtual void thinkPlayHand();
signals:
void notifyGrabLordBet(Player* player, int bet);
void notifyPlayHand(Player* player, const Cards& card);
void notifyPickCards(Player* player, const Cards& cards);
protected:
int m_score = 0;
QString m_name;
Role m_role;
Sex m_sex;
Direction m_direction;
Type m_type;
bool m_isWin = false;
Player* m_prev = nullptr;
Player* m_next = nullptr;
Cards m_cards;
Cards m_pendCards;
Player* m_pendPlayer = nullptr;
};
#endif // PLAYER_H
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。