Throw config error when using global zones as parent

This commit is contained in:
Jean Flach 2018-06-15 14:40:09 +02:00
parent 0f1715332a
commit ee9be90fa7
1 changed files with 3 additions and 0 deletions

View File

@ -33,6 +33,9 @@ void Zone::OnAllConfigLoaded()
m_Parent = Zone::GetByName(GetParentRaw());
if (m_Parent && m_Parent->IsGlobal())
BOOST_THROW_EXCEPTION(ScriptError("Zone '" + GetName() + "' can not have a global zone as parent.", GetDebugInfo()));
Zone::Ptr zone = m_Parent;
int levels = 0;