diff options
author | Andrei Karas <akaras@inbox.ru> | 2012-05-31 22:23:23 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2012-05-31 22:23:23 +0300 |
commit | fc5ba333f8832f3d8e054e7c74df1e3cd353645f (patch) | |
tree | 16aabceaaa2b197d006bd357d3176acac292cde7 /src/resources | |
parent | 9875c00dc37b1d7b55e1154075a0cd2d997a490d (diff) | |
download | manaplus-fc5ba333f8832f3d8e054e7c74df1e3cd353645f.tar.gz manaplus-fc5ba333f8832f3d8e054e7c74df1e3cd353645f.tar.bz2 manaplus-fc5ba333f8832f3d8e054e7c74df1e3cd353645f.tar.xz manaplus-fc5ba333f8832f3d8e054e7c74df1e3cd353645f.zip |
Add sittop sprites support.
Add groundtop collision support (not collision but special selected tiles).
Diffstat (limited to 'src/resources')
-rw-r--r-- | src/resources/beinginfo.h | 1 | ||||
-rw-r--r-- | src/resources/mapreader.cpp | 3 | ||||
-rw-r--r-- | src/resources/monsterdb.cpp | 4 | ||||
-rw-r--r-- | src/resources/spritedef.cpp | 1 | ||||
-rw-r--r-- | src/resources/spritedef.h | 1 |
5 files changed, 10 insertions, 0 deletions
diff --git a/src/resources/beinginfo.h b/src/resources/beinginfo.h index bd2043fba..8142cc194 100644 --- a/src/resources/beinginfo.h +++ b/src/resources/beinginfo.h @@ -55,6 +55,7 @@ enum SoundEvent SOUND_EVENT_DIE, SOUND_EVENT_MOVE, SOUND_EVENT_SIT, + SOUND_EVENT_SITTOP, SOUND_EVENT_SPAWN }; diff --git a/src/resources/mapreader.cpp b/src/resources/mapreader.cpp index 19f9ab3f2..3f1ef1239 100644 --- a/src/resources/mapreader.cpp +++ b/src/resources/mapreader.cpp @@ -431,6 +431,9 @@ inline static void setTile(Map *map, MapLayer *layer, int x, int y, int gid) case Map::COLLISION_WATER: map->blockTile(x, y, Map::BLOCKTYPE_WATER); break; + case Map::COLLISION_GROUNDTOP: + map->blockTile(x, y, Map::BLOCKTYPE_GROUNDTOP); + break; default: break; } diff --git a/src/resources/monsterdb.cpp b/src/resources/monsterdb.cpp index 2c9448fc3..d76585fd2 100644 --- a/src/resources/monsterdb.cpp +++ b/src/resources/monsterdb.cpp @@ -160,6 +160,10 @@ void MonsterDB::load() { currentInfo->addSound(SOUND_EVENT_SIT, filename); } + else if (event == "sittop") + { + currentInfo->addSound(SOUND_EVENT_SITTOP, filename); + } else if (event == "spawn") { currentInfo->addSound(SOUND_EVENT_SPAWN, filename); diff --git a/src/resources/spritedef.cpp b/src/resources/spritedef.cpp index 4aa0eada4..da3b70559 100644 --- a/src/resources/spritedef.cpp +++ b/src/resources/spritedef.cpp @@ -143,6 +143,7 @@ void SpriteDef::substituteActions() substituteAction(SpriteAction::CAST_MAGIC, SpriteAction::ATTACK); substituteAction(SpriteAction::USE_ITEM, SpriteAction::CAST_MAGIC); substituteAction(SpriteAction::SIT, SpriteAction::STAND); + substituteAction(SpriteAction::SITTOP, SpriteAction::SIT); substituteAction(SpriteAction::SLEEP, SpriteAction::SIT); substituteAction(SpriteAction::HURT, SpriteAction::STAND); substituteAction(SpriteAction::DEAD, SpriteAction::HURT); diff --git a/src/resources/spritedef.h b/src/resources/spritedef.h index e59e4bd1f..b0cb5f1b6 100644 --- a/src/resources/spritedef.h +++ b/src/resources/spritedef.h @@ -78,6 +78,7 @@ namespace SpriteAction static const std::string DEFAULT = "stand"; static const std::string STAND = "stand"; static const std::string SIT = "sit"; + static const std::string SITTOP = "sittop"; static const std::string SLEEP = "sleep"; static const std::string DEAD = "dead"; static const std::string MOVE = "walk"; |