summaryrefslogtreecommitdiffstats
path: root/source/Blocks/BlockBed.h
diff options
context:
space:
mode:
authormadmaxoft@gmail.com <madmaxoft@gmail.com@0a769ca7-a7f5-676a-18bf-c427514a06d6>2013-06-04 21:22:14 +0200
committermadmaxoft@gmail.com <madmaxoft@gmail.com@0a769ca7-a7f5-676a-18bf-c427514a06d6>2013-06-04 21:22:14 +0200
commit3ee523628465a59070354781cda6585f6778192c (patch)
tree0ef22389cfc7738fd79a02b11e1bc33a63f28b09 /source/Blocks/BlockBed.h
parentExpat project: fixed intermediate files output folder (diff)
downloadcuberite-3ee523628465a59070354781cda6585f6778192c.tar
cuberite-3ee523628465a59070354781cda6585f6778192c.tar.gz
cuberite-3ee523628465a59070354781cda6585f6778192c.tar.bz2
cuberite-3ee523628465a59070354781cda6585f6778192c.tar.lz
cuberite-3ee523628465a59070354781cda6585f6778192c.tar.xz
cuberite-3ee523628465a59070354781cda6585f6778192c.tar.zst
cuberite-3ee523628465a59070354781cda6585f6778192c.zip
Diffstat (limited to '')
-rw-r--r--source/Blocks/BlockBed.h21
1 files changed, 7 insertions, 14 deletions
diff --git a/source/Blocks/BlockBed.h b/source/Blocks/BlockBed.h
index ab55ffc92..bf8906750 100644
--- a/source/Blocks/BlockBed.h
+++ b/source/Blocks/BlockBed.h
@@ -3,7 +3,6 @@
#include "BlockHandler.h"
#include "../World.h"
-#include "../Sign.h"
#include "../Player.h"
@@ -44,13 +43,11 @@ public:
}
-
-
// Bed specific helper functions
static NIBBLETYPE RotationToMetaData(double a_Rotation)
{
- a_Rotation += 180 + (180/4); // So its not aligned with axis
- if( a_Rotation > 360 ) a_Rotation -= 360;
+ a_Rotation += 180 + (180 / 4); // So its not aligned with axis
+ if (a_Rotation > 360) a_Rotation -= 360;
a_Rotation = (a_Rotation / 360) * 4;
@@ -62,15 +59,11 @@ public:
{
switch (a_MetaData)
{
- case 0: // south +z
- return Vector3i(0, 0, 1);
- case 1: // west -x
- return Vector3i(-1, 0, 0);
- case 2: // north -z
- return Vector3i(0, 0, -1);
- case 3: // east +x
- return Vector3i(1, 0, 0);
- };
+ case 0: return Vector3i(0, 0, 1);
+ case 1: return Vector3i(-1, 0, 0);
+ case 2: return Vector3i(0, 0, -1);
+ case 3: return Vector3i(1, 0, 0);
+ }
return Vector3i();
}
} ;