mirror of
https://github.com/vcmi/vcmi.git
synced 2025-08-13 19:54:17 +02:00
* next part of thieves' guild window
This commit is contained in:
@@ -4956,6 +4956,19 @@ CThievesGuildWindow::CThievesGuildWindow(const CGObjectInstance * _owner)
|
|||||||
{
|
{
|
||||||
blitAt(graphics->portraitSmall[it->second.portrait], 260 + 66 * counter, 360, background);
|
blitAt(graphics->portraitSmall[it->second.portrait], 260 + 66 * counter, 360, background);
|
||||||
counter++;
|
counter++;
|
||||||
|
|
||||||
|
//printing stats
|
||||||
|
if(it->second.details)
|
||||||
|
{
|
||||||
|
for (int i=0; i<it->second.details->primskills.size(); ++i)
|
||||||
|
{
|
||||||
|
printAt(CGI->generaltexth->allTexts[380+i], 191 + 66*counter, 394 + 11*i, FONT_SMALL, zwykly, background);
|
||||||
|
std::ostringstream skill;
|
||||||
|
skill << it->second.details->primskills[i];
|
||||||
|
printTo(skill.str(), 244 + 66 * counter, 410 + 11*i, FONT_SMALL, zwykly, background);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
//printing best creature
|
//printing best creature
|
||||||
@@ -4966,6 +4979,25 @@ CThievesGuildWindow::CThievesGuildWindow(const CGObjectInstance * _owner)
|
|||||||
counter++;
|
counter++;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
//printing personality
|
||||||
|
counter = 0;
|
||||||
|
for(std::map<ui8, si8>::const_iterator it = tgi.personality.begin(); it != tgi.personality.end(); ++it)
|
||||||
|
{
|
||||||
|
int toPrint = 0;
|
||||||
|
if(it->second == -1)
|
||||||
|
{
|
||||||
|
toPrint = 172;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
toPrint = 168 + it->second;
|
||||||
|
}
|
||||||
|
|
||||||
|
printAtMiddle(CGI->generaltexth->arraytxt[toPrint], 283 + 66*counter, 459, FONT_SMALL, zwykly, background);
|
||||||
|
|
||||||
|
counter++;
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
CThievesGuildWindow::~CThievesGuildWindow()
|
CThievesGuildWindow::~CThievesGuildWindow()
|
||||||
|
@@ -3613,6 +3613,11 @@ InfoAboutHero::InfoAboutHero()
|
|||||||
portrait = -1;
|
portrait = -1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
InfoAboutHero::InfoAboutHero( const InfoAboutHero & iah )
|
||||||
|
{
|
||||||
|
assign(iah);
|
||||||
|
}
|
||||||
|
|
||||||
InfoAboutHero::~InfoAboutHero()
|
InfoAboutHero::~InfoAboutHero()
|
||||||
{
|
{
|
||||||
delete details;
|
delete details;
|
||||||
@@ -3650,3 +3655,18 @@ void InfoAboutHero::initFromHero( const CGHeroInstance *h, bool detailed )
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void InfoAboutHero::assign( const InfoAboutHero & iah )
|
||||||
|
{
|
||||||
|
army = iah.army;
|
||||||
|
details = (iah.details ? new Details(*iah.details) : NULL);
|
||||||
|
hclass = iah.hclass;
|
||||||
|
name = iah.name;
|
||||||
|
owner = iah.owner;
|
||||||
|
portrait = iah.portrait;
|
||||||
|
}
|
||||||
|
|
||||||
|
InfoAboutHero & InfoAboutHero::operator=( const InfoAboutHero & iah )
|
||||||
|
{
|
||||||
|
assign(iah);
|
||||||
|
return *this;
|
||||||
|
}
|
@@ -61,6 +61,9 @@ namespace boost
|
|||||||
|
|
||||||
struct DLL_EXPORT InfoAboutHero
|
struct DLL_EXPORT InfoAboutHero
|
||||||
{
|
{
|
||||||
|
private:
|
||||||
|
void assign(const InfoAboutHero & iah);
|
||||||
|
public:
|
||||||
struct DLL_EXPORT Details
|
struct DLL_EXPORT Details
|
||||||
{
|
{
|
||||||
std::vector<int> primskills;
|
std::vector<int> primskills;
|
||||||
@@ -74,6 +77,8 @@ struct DLL_EXPORT InfoAboutHero
|
|||||||
CCreatureSet army; //numbers of creatures are exact numbers if detailed else they are quantity ids (0 - a few, 1 - several and so on)
|
CCreatureSet army; //numbers of creatures are exact numbers if detailed else they are quantity ids (0 - a few, 1 - several and so on)
|
||||||
|
|
||||||
InfoAboutHero();
|
InfoAboutHero();
|
||||||
|
InfoAboutHero(const InfoAboutHero & iah);
|
||||||
|
InfoAboutHero & operator=(const InfoAboutHero & iah);
|
||||||
~InfoAboutHero();
|
~InfoAboutHero();
|
||||||
void initFromHero(const CGHeroInstance *h, bool detailed);
|
void initFromHero(const CGHeroInstance *h, bool detailed);
|
||||||
};
|
};
|
||||||
|
Reference in New Issue
Block a user