3 #include "TypeDescription.h"
4 #include "../battle/Resources.h"
5 #include "../battle/Monster.h"
6 #include "../battle/PartyLayout.h"
7 #include "../common/Capsule.h"
8 #include "../common/Hero.h"
9 #include "../common/Item.h"
10 #include "../common/Spell.h"
11 #include "../map/Map.h"
12 #include "../menu/Resources.h"
14 using battle::Monster;
15 using battle::PartyLayout;
16 using common::Capsule;
26 Caster::Caster(Interpreter &intp)
32 battle::Resources *Caster::GetBattleResources(const string &ident) {
33 return reinterpret_cast<battle::Resources *>(
34 intp.GetObject(battle::Resources::TYPE_ID, ident));
37 Capsule *Caster::GetCapsule(const string &ident) {
38 return reinterpret_cast<Capsule *>(intp.GetObject(Capsule::TYPE_ID, ident));
41 Hero *Caster::GetHero(const string &ident) {
42 return reinterpret_cast<Hero *>(intp.GetObject(Hero::TYPE_ID, ident));
45 Item *Caster::GetItem(const string &ident) {
46 return reinterpret_cast<Item *>(intp.GetObject(Item::TYPE_ID, ident));
49 Map *Caster::GetMap(const string &ident) {
50 return reinterpret_cast<Map *>(intp.GetObject(Map::TYPE_ID, ident));
53 menu::Resources *Caster::GetMenuResources(const string &ident) {
54 return reinterpret_cast<menu::Resources *>(
55 intp.GetObject(menu::Resources::TYPE_ID, ident));
58 Monster *Caster::GetMonster(const string &ident) {
59 return reinterpret_cast<Monster *>(intp.GetObject(Monster::TYPE_ID, ident));
62 PartyLayout *Caster::GetPartyLayout(const string &ident) {
63 return reinterpret_cast<PartyLayout *>(
64 intp.GetObject(PartyLayout::TYPE_ID, ident));
67 Spell *Caster::GetSpell(const string &ident) {
68 return reinterpret_cast<Spell *>(intp.GetObject(Spell::TYPE_ID, ident));