1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-06-19 00:17:56 +02:00

Little more work on artifacts.

This commit is contained in:
Michał W. Urbańczyk
2010-12-29 21:04:22 +00:00
parent 8104a43809
commit c9189119b9
17 changed files with 425 additions and 314 deletions

View File

@ -604,8 +604,17 @@ DLL_EXPORT const CStackInstance * StackLocation::getStack()
DLL_EXPORT const CArtifactInstance *ArtifactLocation::getArt() const
{
const ArtSlotInfo *s = getSlot();
if(s && !s->locked && s->artifact)
return s->artifact;
if(s && s->artifact)
{
if(!s->locked)
return s->artifact;
else
{
tlog3 << "ArtifactLocation::getArt: That location is locked!\n";
return NULL;
}
}
return NULL;
}
DLL_EXPORT CArtifactInstance *ArtifactLocation::getArt()