mirror of
https://github.com/PaperMC/Paper.git
synced 2025-01-27 02:31:43 +01:00
SPIGOT-6318: Fix smoke effect directions
By: WinX64 <winx64b@hotmail.com>
This commit is contained in:
parent
f7ff794ec7
commit
f6f717ebe7
@ -28,35 +28,31 @@ public class CraftEffect {
|
|||||||
datavalue = Item.getId(CraftMagicNumbers.getItem((Material) data));
|
datavalue = Item.getId(CraftMagicNumbers.getItem((Material) data));
|
||||||
break;
|
break;
|
||||||
case SMOKE:
|
case SMOKE:
|
||||||
switch ((BlockFace) data) { // TODO: Verify (Where did these values come from...?)
|
switch ((BlockFace) data) {
|
||||||
|
case DOWN:
|
||||||
|
// SPIGOT-6318: Fallback value for the old directions
|
||||||
|
case NORTH_EAST:
|
||||||
|
case NORTH_WEST:
|
||||||
case SOUTH_EAST:
|
case SOUTH_EAST:
|
||||||
|
case SOUTH_WEST:
|
||||||
|
case SELF:
|
||||||
datavalue = 0;
|
datavalue = 0;
|
||||||
break;
|
break;
|
||||||
case SOUTH:
|
case UP:
|
||||||
datavalue = 1;
|
datavalue = 1;
|
||||||
break;
|
break;
|
||||||
case SOUTH_WEST:
|
case NORTH:
|
||||||
datavalue = 2;
|
datavalue = 2;
|
||||||
break;
|
break;
|
||||||
case EAST:
|
case SOUTH:
|
||||||
datavalue = 3;
|
datavalue = 3;
|
||||||
break;
|
break;
|
||||||
case UP:
|
case WEST:
|
||||||
case SELF:
|
|
||||||
datavalue = 4;
|
datavalue = 4;
|
||||||
break;
|
break;
|
||||||
case WEST:
|
case EAST:
|
||||||
datavalue = 5;
|
datavalue = 5;
|
||||||
break;
|
break;
|
||||||
case NORTH_EAST:
|
|
||||||
datavalue = 6;
|
|
||||||
break;
|
|
||||||
case NORTH:
|
|
||||||
datavalue = 7;
|
|
||||||
break;
|
|
||||||
case NORTH_WEST:
|
|
||||||
datavalue = 8;
|
|
||||||
break;
|
|
||||||
default:
|
default:
|
||||||
throw new IllegalArgumentException("Bad smoke direction!");
|
throw new IllegalArgumentException("Bad smoke direction!");
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user