File indexing completed on 2024-10-27 03:47:45

0001 /*
0002     SPDX-FileCopyrightText: 2006 Pierre Ducroquet <pinaraf@pinaraf.info>
0003 
0004     SPDX-License-Identifier: GPL-2.0-or-later
0005 */
0006 
0007 #ifndef AI_DEFAULT_H
0008 #define AI_DEFAULT_H
0009 
0010 #include "../../computerplayer.h"
0011 
0012 class AiDefault : public ComputerPlayer
0013 {
0014 protected:
0015     enum AiLevel { Weak, Normal, Hard };
0016 
0017     explicit AiDefault(Game *game, const QString &newName, const QColor &color, AiLevel level);
0018 
0019     void setAiLevel (AiLevel level) { m_level = level; }
0020 
0021     AiLevel aiLevel() const { return m_level; }
0022 
0023     void play() override;
0024 
0025 private:
0026     AiLevel m_level;
0027 };
0028 
0029 #endif // AI_DEFAULT_H