mirror of
https://github.com/vcmi/vcmi.git
synced 2025-01-24 03:47:18 +02:00
1580c71c78
* a bit of battle interface * heroes with same owner cannot fight
34 lines
1008 B
C++
34 lines
1008 B
C++
#pragma once
|
|
#include "global.h"
|
|
#include "CPlayerInterface.h"
|
|
|
|
class CCreatureSet;
|
|
class CGHeroInstance;
|
|
template <typename T> class AdventureMapButton;
|
|
|
|
class CBattleInterface : public IActivable, public IShowable
|
|
{
|
|
private:
|
|
SDL_Surface * background, * menu;
|
|
AdventureMapButton<CBattleInterface> * bOptions, * bSurrender, * bFlee, * bAutofight, * bSpell,
|
|
* bWait, * bDefence, * bConsoleUp, * bConsoleDown;
|
|
public:
|
|
CBattleInterface(CCreatureSet * army1, CCreatureSet * army2, int3 tile, CGHeroInstance *hero1, CGHeroInstance *hero2);
|
|
~CBattleInterface();
|
|
|
|
//button handle funcs:
|
|
void bOptionsf();
|
|
void bSurrenderf();
|
|
void bFleef();
|
|
void bAutofightf();
|
|
void bSpellf();
|
|
void bWaitf();
|
|
void bDefencef();
|
|
void bConsoleUpf();
|
|
void bConsoleDownf();
|
|
//end of button handle funcs
|
|
//napisz tu klase odpowiadajaca za wyswietlanie bitwy i obsluge uzytkownika, polecenia ma przekazywac callbackiem
|
|
void activate();
|
|
void deactivate();
|
|
void show(SDL_Surface * to);
|
|
}; |