Skip to content

Commit f7f5ca7

Browse files
committed
Merge branch 'mc/1.13'
2 parents b6cd012 + 80f1d90 commit f7f5ca7

File tree

81 files changed

+2857
-1243
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

81 files changed

+2857
-1243
lines changed

BlueMapBukkit/src/main/resources/bluemap-bukkit-defaults.conf

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ metrics: true
33
renderThreadCount: -2
44
data: "bluemap"
55
webroot: "bluemap/web"
6+
useCookies: true
67
webserver {
78
enabled: true
89
port: 8100

BlueMapBukkit/src/main/resources/bluemap-bukkit.conf

Lines changed: 29 additions & 49 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,9 @@ webroot: "bluemap/web"
3737
# Default is "<webroot>/data"
3838
#webdata: "path/to/data/folder"
3939

40+
# If the web-application should use cookies to save the configurations of a user.
41+
useCookies: true
42+
4043
webserver {
4144
# With this setting you can disable the integrated web-server.
4245
# This is usefull if you want to only render the map-data for later use, or if you setup your own webserver.
@@ -65,40 +68,43 @@ maps: [
6568
{
6669
# The id of this map
6770
# Should only contain word-charactes: [a-zA-Z0-9_]
71+
# Changing this value breaks your existing renders.
6872
id: "world"
6973

7074
# The name of this map
71-
# This defines the display name of this map, you can change this at any time
75+
# This defines the display name of this map, you can change this at any time.
7276
# Default is the id of this map
7377
name: "World"
7478

75-
# The path to the save-folder of the world to render
79+
# The path to the save-folder of the world to render.
7680
world: "world"
7781

7882
# The position on the world where the map will be centered if you open it.
83+
# You can change this at any time.
7984
# This defaults to the world-spawn if you don't set it.
8085
#startPos: [500, -820]
86+
87+
# The color of thy sky as a hex-color
88+
# You can change this at any time.
89+
# Default is "#7dabff"
90+
skyColor: "#7dabff"
91+
92+
# Defines the ambient light-strength that every block is recieving, regardless of the sunlight/blocklight.
93+
# 0 is no ambient light, 1 is fully lighted.
94+
# You can change this at any time.
95+
# Default is 0
96+
ambientLight: 0
8197

8298
# If this is false, BlueMap tries to omit all blocks that are not visible from above-ground.
8399
# More specific: Block-Faces that have a sunlight/skylight value of 0 are removed.
84100
# This improves the performance of the map on slower devices by a lot, but might cause some blocks to disappear that should normally be visible.
101+
# Changing this value requires a re-render of the map.
85102
# Default is false
86103
renderCaves: false
87104

88-
# AmbientOcclusion adds soft shadows into corners, which gives the map a much better look.
89-
# This has only a small impact on render-time and has no impact on the web-performance of the map.
90-
# The value defines the strength of the shading, a value of 0 disables ambientOcclusion.
91-
# Default is 0.25
92-
ambientOcclusion: 0.25
93-
94-
# Lighting uses the light-data in minecraft to shade each block-face.
95-
# If this is enabled, caves and inside buildings without torches will be darker.
96-
# The value defines the strength of the shading and a value of 0 disables lighting (every block will be fully lit).
97-
# Default is 0.8
98-
lighting: 0.8
99-
100105
# With the below values you can limit the map-render.
101106
# This can be used to ignore the nethers ceiling or render only a certain part of a world.
107+
# Changing this values might require a re-render of the map, already rendered tiles outside the limits will not be deleted.
102108
# Default is no min or max value (= infinite bounds)
103109
#minX: -4000
104110
#maxX: 4000
@@ -110,67 +116,41 @@ maps: [
110116
# Using this, BlueMap pretends that every Block out of the defined render-bounds is AIR,
111117
# this means you can see the blocks where the world is cut (instead of having a see-through/xray view).
112118
# This has only an effect if you set some render-bounds above.
113-
# Default is enabled
119+
# Changing this value requires a re-render of the map.
120+
# Default is true
114121
renderEdges: true
115122

116123
# With this set to true, the generated files for this world are compressed using gzip to save A LOT of space.
117124
# Files will be only 5% as big with compression!
118125
# Note: If you are using NGINX or Apache to host your map, you can configure them to serve the compressed files directly.
119126
# This is much better than disabling the compression.
127+
# Changing this value requires a re-render of the map.
128+
# Default is true
120129
useCompression: true
121-
122-
# HIRES is the high-resolution render of the map. Where you see every block.
123-
hires {
124-
# Defines the size of one map-tile in blocks.
125-
# If you change this value, the lowres values might need adjustment as well!
126-
# Default is 32
127-
tileSize: 32
128-
129-
# The View-Distance for hires tiles on the web-map (the value is the radius in tiles)
130-
# Default is 4.5
131-
viewDistance: 4.5
132-
}
133-
134-
# LOWRES is the low-resolution render of the map. Thats the model that you see if you zoom far out to get an overview.
135-
lowres {
136-
# Defines resolution of the lowres model. E.g. If the hires.tileSize is 32, a value of 4 means that every 8*8 blocks will be summarized by one point on the lowres map.
137-
# Calculation: 32 / 4 = 8
138-
# You can only use values that result in an integer if you use the above calculation!
139-
# Default is 4
140-
pointsPerHiresTile: 4
141-
142-
# Defines the size of one lowres-map-tile in points.
143-
# Default is 50
144-
pointsPerLowresTile: 50
145-
146-
# The View-Distance for lowres tiles on the web-map (the value is the radius in tiles)
147-
# Default is 7
148-
viewDistance: 7
149-
}
150130
}
151131

152132
# Here another example for the End-Map
153133
# Things we don't want to change from default we can just omit
154134
{
155135
id: "end"
156136
name: "End"
157-
world: "world/DIM1"
137+
world: "world_the_end"
158138

159139
# In the end is no sky-light, so we need to enable this or we won't see anything.
160140
renderCaves: true
161141

162-
# Same here, we don't want a dark map. But not completely disabled, so we see the effect of e.g torches.
163-
lighting: 0.4
142+
# Same here, we don't want a dark map. But not completely lighted, so we see the effect of e.g torches.
143+
ambientLight: 0.6
164144
}
165145

166146
# Here another example for the Nether-Map
167147
{
168148
id: "nether"
169149
name: "Nether"
170-
world: "world/DIM-1"
150+
world: "world_nether"
171151

172152
renderCaves: true
173-
lighting: 0.6
153+
ambientLight: 0.6
174154

175155
# We slice the whole world at y:90 so every block above 90 will be air.
176156
# This way we don't render the nethers ceiling.

BlueMapCLI/src/main/java/de/bluecolored/bluemap/cli/BlueMapCLI.java

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -141,9 +141,10 @@ public void renderMaps() throws IOException {
141141

142142
Logger.global.logInfo("Writing settings.json ...");
143143
WebSettings webSettings = new WebSettings(config.getWebDataPath().resolve("settings.json").toFile());
144-
webSettings.setAllEnabled(false);
144+
webSettings.set(config.isUseCookies(), "useCookies");
145+
webSettings.setAllMapsEnabled(false);
145146
for (MapType map : maps.values()) {
146-
webSettings.setEnabled(true, map.getId());
147+
webSettings.setMapEnabled(true, map.getId());
147148
webSettings.setFrom(map.getTileRenderer(), map.getId());
148149
webSettings.setFrom(map.getWorld(), map.getId());
149150
}

BlueMapCLI/src/main/resources/bluemap-cli-defaults.conf

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,8 @@ accept-download: false
22
metrics: true
33
renderThreadCount: 0
44
data: "."
5-
webroot: "web"
5+
webroot: "web"
6+
useCookies: true
67
webserver {
78
enabled: false
89
port: 8100

BlueMapCLI/src/main/resources/bluemap-cli.conf

Lines changed: 27 additions & 47 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,9 @@ webroot: "web"
3737
# Default is "<webroot>/data"
3838
#webdata: "path/to/data/folder"
3939

40+
# If the web-application should use cookies to save the configurations of a user.
41+
useCookies: true
42+
4043
webserver {
4144
# With this setting you can enable the integrated web-server.
4245
# Default is disabled
@@ -64,40 +67,43 @@ maps: [
6467
{
6568
# The id of this map
6669
# Should only contain word-charactes: [a-zA-Z0-9_]
70+
# Changing this value breaks your existing renders.
6771
id: "world"
6872

6973
# The name of this map
70-
# This defines the display name of this map, you can change this at any time
74+
# This defines the display name of this map, you can change this at any time.
7175
# Default is the id of this map
7276
name: "World"
7377

74-
# The path to the save-folder of the world to render
78+
# The path to the save-folder of the world to render.
7579
world: "world"
7680

7781
# The position on the world where the map will be centered if you open it.
82+
# You can change this at any time.
7883
# This defaults to the world-spawn if you don't set it.
7984
#startPos: [500, -820]
85+
86+
# The color of thy sky as a hex-color
87+
# You can change this at any time.
88+
# Default is "#7dabff"
89+
skyColor: "#7dabff"
90+
91+
# Defines the ambient light-strength that every block is recieving, regardless of the sunlight/blocklight.
92+
# 0 is no ambient light, 1 is fully lighted.
93+
# You can change this at any time.
94+
# Default is 0
95+
ambientLight: 0
8096

8197
# If this is false, BlueMap tries to omit all blocks that are not visible from above-ground.
8298
# More specific: Block-Faces that have a sunlight/skylight value of 0 are removed.
8399
# This improves the performance of the map on slower devices by a lot, but might cause some blocks to disappear that should normally be visible.
100+
# Changing this value requires a re-render of the map.
84101
# Default is false
85102
renderCaves: false
86103

87-
# AmbientOcclusion adds soft shadows into corners, which gives the map a much better look.
88-
# This has only a small impact on render-time and has no impact on the web-performance of the map.
89-
# The value defines the strength of the shading, a value of 0 disables ambientOcclusion.
90-
# Default is 0.25
91-
ambientOcclusion: 0.25
92-
93-
# Lighting uses the light-data in minecraft to shade each block-face.
94-
# If this is enabled, caves and inside buildings without torches will be darker.
95-
# The value defines the strength of the shading and a value of 0 disables lighting (every block will be fully lit).
96-
# Default is 0.8
97-
lighting: 0.8
98-
99104
# With the below values you can limit the map-render.
100105
# This can be used to ignore the nethers ceiling or render only a certain part of a world.
106+
# Changing this values might require a re-render of the map, already rendered tiles outside the limits will not be deleted.
101107
# Default is no min or max value (= infinite bounds)
102108
#minX: -4000
103109
#maxX: 4000
@@ -109,43 +115,17 @@ maps: [
109115
# Using this, BlueMap pretends that every Block out of the defined render-bounds is AIR,
110116
# this means you can see the blocks where the world is cut (instead of having a see-through/xray view).
111117
# This has only an effect if you set some render-bounds above.
112-
# Default is enabled
118+
# Changing this value requires a re-render of the map.
119+
# Default is true
113120
renderEdges: true
114121

115122
# With this set to true, the generated files for this world are compressed using gzip to save A LOT of space.
116123
# Files will be only 5% as big with compression!
117124
# Note: If you are using NGINX or Apache to host your map, you can configure them to serve the compressed files directly.
118125
# This is much better than disabling the compression.
126+
# Changing this value requires a re-render of the map.
127+
# Default is true
119128
useCompression: true
120-
121-
# HIRES is the high-resolution render of the map. Where you see every block.
122-
hires {
123-
# Defines the size of one map-tile in blocks.
124-
# If you change this value, the lowres values might need adjustment as well!
125-
# Default is 32
126-
tileSize: 32
127-
128-
# The View-Distance for hires tiles on the web-map (the value is the radius in tiles)
129-
# Default is 4.5
130-
viewDistance: 4.5
131-
}
132-
133-
# LOWRES is the low-resolution render of the map. Thats the model that you see if you zoom far out to get an overview.
134-
lowres {
135-
# Defines resolution of the lowres model. E.g. If the hires.tileSize is 32, a value of 4 means that every 8*8 blocks will be summarized by one point on the lowres map.
136-
# Calculation: 32 / 4 = 8
137-
# You can only use values that result in an integer if you use the above calculation!
138-
# Default is 4
139-
pointsPerHiresTile: 4
140-
141-
# Defines the size of one lowres-map-tile in points.
142-
# Default is 50
143-
pointsPerLowresTile: 50
144-
145-
# The View-Distance for lowres tiles on the web-map (the value is the radius in tiles)
146-
# Default is 7
147-
viewDistance: 7
148-
}
149129
}
150130

151131
# Here another example for the End-Map
@@ -158,8 +138,8 @@ maps: [
158138
# In the end is no sky-light, so we need to enable this or we won't see anything.
159139
renderCaves: true
160140

161-
# Same here, we don't want a dark map. But not completely disabled, so we see the effect of e.g torches.
162-
lighting: 0.4
141+
# Same here, we don't want a dark map. But not completely lighted, so we see the effect of e.g torches.
142+
ambientLight: 0.6
163143
}
164144

165145
# Here another example for the Nether-Map
@@ -169,7 +149,7 @@ maps: [
169149
world: "world/DIM-1"
170150

171151
renderCaves: true
172-
lighting: 0.6
152+
ambientLight: 0.6
173153

174154
# We slice the whole world at y:90 so every block above 90 will be air.
175155
# This way we don't render the nethers ceiling.

BlueMapCommon/src/main/java/de/bluecolored/bluemap/common/plugin/Plugin.java

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -246,9 +246,10 @@ public synchronized void load() throws IOException, ParseResourceException {
246246
}
247247

248248
WebSettings webSettings = new WebSettings(config.getWebDataPath().resolve("settings.json").toFile());
249-
webSettings.setAllEnabled(false);
249+
webSettings.set(config.isUseCookies(), "useCookies");
250+
webSettings.setAllMapsEnabled(false);
250251
for (MapType map : maps.values()) {
251-
webSettings.setEnabled(true, map.getId());
252+
webSettings.setMapEnabled(true, map.getId());
252253
webSettings.setFrom(map.getTileRenderer(), map.getId());
253254
webSettings.setFrom(map.getWorld(), map.getId());
254255
}
@@ -273,7 +274,7 @@ public synchronized void load() throws IOException, ParseResourceException {
273274
Thread.sleep(TimeUnit.MINUTES.toMillis(1));
274275

275276
while (true) {
276-
if (serverInterface.isMetricsEnabled(config.isMetricsEnabled())) Metrics.sendReport("Sponge");
277+
if (serverInterface.isMetricsEnabled(config.isMetricsEnabled())) Metrics.sendReport(this.implementationType);
277278
Thread.sleep(TimeUnit.MINUTES.toMillis(30));
278279
}
279280
} catch (InterruptedException ex){

0 commit comments

Comments
 (0)