1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-06-15 00:05:02 +02:00

* campaign against magic numbers

* ArtifactID was misleading and wrongly used in one place -- renamed and fixed
* minor changes
This commit is contained in:
mateuszb
2012-09-23 18:01:04 +00:00
parent 3fcba4fb5c
commit 6a81c8b1af
32 changed files with 567 additions and 511 deletions

View File

@ -434,7 +434,7 @@ void SetAvailableCreatures::applyCl( CClient *cl )
//inform order about the change
int p = -1;
if(dw->ID == 106) //War Machines Factory is not flaggable, it's "owned" by visitor
if(dw->ID == Obj::WAR_MACHINE_FACTORY) //War Machines Factory is not flaggable, it's "owned" by visitor
p = cl->getTile(dw->visitablePos())->visitableObjects.back()->tempOwner;
else
p = dw->tempOwner;
@ -923,15 +923,15 @@ void TradeComponents::applyCl(CClient *cl)
{///Shop handler
switch (CGI->mh->map->objects[objectid]->ID)
{
case 7: //Black Market
break;
case 95: //Tavern
break;
case 97: //Den of Thieves
break;
case 221: //Trading Post
break;
default:
tlog2 << "Shop type not supported! \n";
case Obj::BLACK_MARKET:
break;
case Obj::TAVERN:
break;
case Obj::DEN_OF_THIEVES:
break;
case Obj::TRADING_POST_SNOW:
break;
default:
tlog2 << "Shop type not supported! \n";
}
}