From ea8fb5426b0f065b4ef508bb33c2baf30df6b5a4 Mon Sep 17 00:00:00 2001 From: Kelly Rauchenberger Date: Sun, 28 Feb 2021 17:58:15 -0500 Subject: Simplified "animation" map sprite parameter The filenames for these are fairly regular, and we're gonna want to abstract it away further later on anyway. --- res/maps/hallucination_beach.tmx | 2 +- res/maps/hallucination_hot_spring.tmx | 2 +- res/maps/hallucination_interior.tmx | 6 +++--- res/maps/pink_shell.tmx | 2 +- res/maps/underwater_start.tmx | 2 +- src/map.cpp | 2 +- 6 files changed, 8 insertions(+), 8 deletions(-) diff --git a/res/maps/hallucination_beach.tmx b/res/maps/hallucination_beach.tmx index ce6c830..9830cf5 100644 --- a/res/maps/hallucination_beach.tmx +++ b/res/maps/hallucination_beach.tmx @@ -43,7 +43,7 @@ - + diff --git a/res/maps/hallucination_hot_spring.tmx b/res/maps/hallucination_hot_spring.tmx index b019681..7ccc0cb 100644 --- a/res/maps/hallucination_hot_spring.tmx +++ b/res/maps/hallucination_hot_spring.tmx @@ -36,7 +36,7 @@ - + diff --git a/res/maps/hallucination_interior.tmx b/res/maps/hallucination_interior.tmx index 55e5506..a4ff7b3 100644 --- a/res/maps/hallucination_interior.tmx +++ b/res/maps/hallucination_interior.tmx @@ -98,7 +98,7 @@ - + @@ -114,7 +114,7 @@ - + @@ -126,7 +126,7 @@ - + diff --git a/res/maps/pink_shell.tmx b/res/maps/pink_shell.tmx index 12eea42..ecff5a8 100644 --- a/res/maps/pink_shell.tmx +++ b/res/maps/pink_shell.tmx @@ -51,7 +51,7 @@ - + diff --git a/res/maps/underwater_start.tmx b/res/maps/underwater_start.tmx index 0ced9c4..cd73e07 100644 --- a/res/maps/underwater_start.tmx +++ b/res/maps/underwater_start.tmx @@ -82,7 +82,7 @@ - + diff --git a/src/map.cpp b/src/map.cpp index 7a3de78..0cf9402 100644 --- a/src/map.cpp +++ b/src/map.cpp @@ -88,7 +88,7 @@ Map::Map(std::string_view name) : name_(name) { } else if (property.getName() == "collisionHeight") { p.collisionSize.h() = property.getIntValue(); } else if (property.getName() == "animation") { - p.animationFilename = property.getStringValue(); + p.animationFilename = "../res/sprites/" + property.getStringValue() + "_anim.txt"; } else if (property.getName() == "animName") { p.animName = property.getStringValue(); } else if (property.getName() == "interactionScript") { -- cgit 1.4.1