summaryrefslogtreecommitdiff
path: root/src/nodedef.h
diff options
context:
space:
mode:
authorsfan5 <sfan5@live.de>2016-12-23 13:48:32 +0100
committersfan5 <sfan5@live.de>2017-01-02 15:28:06 +0100
commit523f0e8c5bce0cb58215dc1f9d027cf32394e3c3 (patch)
treeba8cbd3e60947573fcb6065f4caf5b3152cccb93 /src/nodedef.h
parente2e8da5ee44f71c22996a780caff67e48e79fae4 (diff)
downloadminetest-523f0e8c5bce0cb58215dc1f9d027cf32394e3c3.tar.gz
minetest-523f0e8c5bce0cb58215dc1f9d027cf32394e3c3.tar.bz2
minetest-523f0e8c5bce0cb58215dc1f9d027cf32394e3c3.zip
Move TileAnimation code to seperate file
Diffstat (limited to 'src/nodedef.h')
-rw-r--r--src/nodedef.h16
1 files changed, 3 insertions, 13 deletions
diff --git a/src/nodedef.h b/src/nodedef.h
index 80396f992..b5639b516 100644
--- a/src/nodedef.h
+++ b/src/nodedef.h
@@ -34,6 +34,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
#include "itemgroup.h"
#include "sound.h" // SimpleSoundSpec
#include "constants.h" // BS
+#include "tileanimation.h"
class INodeDefManager;
class IItemDefManager;
@@ -161,22 +162,14 @@ enum NodeDrawType
/*
Stand-alone definition of a TileSpec (basically a server-side TileSpec)
*/
-enum TileAnimationType{
- TAT_NONE=0,
- TAT_VERTICAL_FRAMES=1,
-};
+
struct TileDef
{
std::string name;
bool backface_culling; // Takes effect only in special cases
bool tileable_horizontal;
bool tileable_vertical;
- struct{
- enum TileAnimationType type;
- int aspect_w; // width for aspect ratio
- int aspect_h; // height for aspect ratio
- float length; // seconds
- } animation;
+ struct TileAnimationParams animation;
TileDef()
{
@@ -185,9 +178,6 @@ struct TileDef
tileable_horizontal = true;
tileable_vertical = true;
animation.type = TAT_NONE;
- animation.aspect_w = 1;
- animation.aspect_h = 1;
- animation.length = 1.0;
}
void serialize(std::ostream &os, u16 protocol_version) const;