1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-11-06 09:09:40 +02:00

* reported problems with hero flags resolved

* a bit of battle interface
* heroes with same owner cannot fight
This commit is contained in:
mateuszb
2008-02-26 18:01:26 +00:00
parent 1e7f8984e2
commit 1580c71c78
9 changed files with 174 additions and 28 deletions

View File

@@ -1,13 +1,34 @@
#pragma once
#include "global.h"
#include "CPlayerInterface.h"
class CCreatureSet;
class CGHeroInstance;
class CBattleInterface : public IActivable
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);
};