mirror of
https://github.com/plexusorg/Plex-FAWE.git
synced 2024-11-16 17:16:11 +00:00
Quick fix for SnowHeightMap
This commit is contained in:
parent
ddc59809d8
commit
0aadef97d0
@ -19,7 +19,6 @@
|
|||||||
|
|
||||||
package com.sk89q.worldedit.math.convolution;
|
package com.sk89q.worldedit.math.convolution;
|
||||||
|
|
||||||
import com.google.common.collect.ImmutableMap;
|
|
||||||
import com.sk89q.worldedit.EditSession;
|
import com.sk89q.worldedit.EditSession;
|
||||||
import com.sk89q.worldedit.MaxChangedBlocksException;
|
import com.sk89q.worldedit.MaxChangedBlocksException;
|
||||||
import com.sk89q.worldedit.function.mask.Mask;
|
import com.sk89q.worldedit.function.mask.Mask;
|
||||||
@ -232,7 +231,7 @@ public class SnowHeightMap {
|
|||||||
private void setSnowLayer(int x, int z, float newHeight) throws MaxChangedBlocksException {
|
private void setSnowLayer(int x, int z, float newHeight) throws MaxChangedBlocksException {
|
||||||
int numOfLayers = (int) ((newHeight % 1) * 8) + 1;
|
int numOfLayers = (int) ((newHeight % 1) * 8) + 1;
|
||||||
//FAWE start - avoid BlockVector3 creation for no reason
|
//FAWE start - avoid BlockVector3 creation for no reason
|
||||||
session.setBlock(x, (int) newHeight, z, BlockTypes.SNOW.getState(ImmutableMap.of(LAYERS, numOfLayers)));
|
session.setBlock(x, (int) newHeight, z, BlockTypes.SNOW.getDefaultState().with(LAYERS, numOfLayers));
|
||||||
//FAWE end
|
//FAWE end
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user