X-Git-Url: http://git.localhorst.tv/?a=blobdiff_plain;f=src%2Floader%2FCaster.cpp;h=152c8b298dfa1958a793800c35f7cd8d0a760f20;hb=8fd08e32d902b1340dd686ba0d7990fb1be3b861;hp=a3a6707f9a4d19e7fa1b2e90cfd7223e66f9f39d;hpb=f6085f8568f2c754ed2eac294171e542139581f4;p=l2e.git diff --git a/src/loader/Caster.cpp b/src/loader/Caster.cpp index a3a6707..152c8b2 100644 --- a/src/loader/Caster.cpp +++ b/src/loader/Caster.cpp @@ -9,11 +9,12 @@ #include "TypeDescription.h" -using battle::Hero; using battle::Monster; using battle::PartyLayout; +using common::Hero; using common::Item; using common::Spell; +using map::Map; using std::string; @@ -24,6 +25,7 @@ Caster::Caster(Interpreter &intp) , battleResourcesId(TypeDescription::GetTypeId("BattleResources")) , heroId(TypeDescription::GetTypeId("Hero")) , itemId(TypeDescription::GetTypeId("Item")) +, mapId(TypeDescription::GetTypeId("Map")) , monsterId(TypeDescription::GetTypeId("Monster")) , partyLayoutId(TypeDescription::GetTypeId("PartyLayout")) , spellId(TypeDescription::GetTypeId("Spell")) { @@ -43,6 +45,10 @@ Item *Caster::GetItem(const string &ident) { return reinterpret_cast(intp.GetObject(itemId, ident)); } +Map *Caster::GetMap(const string &ident) { + return reinterpret_cast(intp.GetObject(mapId, ident)); +} + Monster *Caster::GetMonster(const string &ident) { return reinterpret_cast(intp.GetObject(monsterId, ident)); }