mirror of
https://github.com/TES3MP/openmw-tes3mp.git
synced 2025-02-19 17:09:40 +00:00
added test for actor race
This commit is contained in:
parent
2acfe22975
commit
c7fab9aad6
1 changed files with 11 additions and 2 deletions
|
@ -119,7 +119,17 @@ namespace MWDialogue
|
|||
if (info.actor!=MWWorld::Class::get (actor).getId (actor))
|
||||
return false;
|
||||
|
||||
// TODO check actor race
|
||||
if (!info.race.empty())
|
||||
{
|
||||
ESMS::LiveCellRef<ESM::NPC, MWWorld::RefData> *cellRef = actor.get<ESM::NPC>();
|
||||
|
||||
if (!cellRef)
|
||||
return false;
|
||||
|
||||
if (info.race!=cellRef->base->race)
|
||||
return false;
|
||||
}
|
||||
|
||||
// TODO check actor class
|
||||
// TODO check actor faction
|
||||
// TODO check player faction
|
||||
|
@ -138,7 +148,6 @@ namespace MWDialogue
|
|||
|
||||
std::cout
|
||||
<< "unchecked entries:" << std::endl
|
||||
<< " actor race: " << info.race << std::endl
|
||||
<< " actor class: " << info.clas << std::endl
|
||||
<< " actor faction: " << info.npcFaction << std::endl
|
||||
<< " player faction: " << info.pcFaction << std::endl
|
||||
|
|
Loading…
Reference in a new issue