Skip to content

Commit e927517

Browse files
authored
Merge pull request #4250 from webbukkit/v3.0
3.8 release
2 parents ea68a31 + c375665 commit e927517

346 files changed

Lines changed: 9621 additions & 883 deletions

File tree

Some content is hidden

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

DynmapCore/src/main/java/org/dynmap/hdmap/ChunkStatusHDShader.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,9 +43,10 @@ private static class ChunkStatusMap {
4343
new ChunkStatusMap("carvers", 0xFFEFD5);
4444
new ChunkStatusMap("liquid_carvers", 0xF0E68C);
4545
new ChunkStatusMap("features", 0xBDB76B);
46+
new ChunkStatusMap("initialize_light", 0xAAA0AA);
4647
new ChunkStatusMap("light", 0xDDA0DD);
47-
new ChunkStatusMap("spawn", 0xFF00FF);
4848
new ChunkStatusMap("heightmaps", 0x9370DB);
49+
new ChunkStatusMap("spawn", 0xFF00FF);
4950
new ChunkStatusMap("full", 0x32CD32);
5051
}
5152

DynmapCore/src/main/java/org/dynmap/storage/aws_s3/AWSS3MapStorage.java

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -138,9 +138,9 @@ public boolean write(long hash, BufferOutputStream encImage, long timestamp) {
138138
s3.deleteObject(req);
139139
}
140140
else {
141-
PutObjectRequest req = PutObjectRequest.builder().bucketName(bucketname).key(baseKey).contentType(map.getImageFormat().getEncoding().getContentType())
141+
PutObjectRequest req = PutObjectRequest.builder().bucketName(bucketname).key(baseKey).contentType(map.getImageFormat().getEncoding().getContentType())
142142
.addMetadata("x-dynmap-hash", Long.toHexString(hash)).addMetadata("x-dynmap-ts", Long.toString(timestamp)).build();
143-
s3.putObject(req, RequestBody.fromBytes(encImage.buf));
143+
s3.putObject(req, RequestBody.fromBytes(Arrays.copyOf(encImage.buf, encImage.len)));
144144
}
145145
done = true;
146146
} catch (S3Exception x) {
@@ -407,7 +407,7 @@ private void processEnumMapTiles(DynmapWorld world, MapType map, ImageVariant va
407407
}
408408
if (result.isTruncated()) { // If more, build continuiation request
409409
req = ListObjectsV2Request.builder().bucketName(bucketname)
410-
.prefix(basekey).delimiter("").maxKeys(1000).continuationToken(result.getContinuationToken()).encodingType("url").requestPayer("requester").build();
410+
.prefix(basekey).delimiter("").maxKeys(1000).continuationToken(result.getNextContinuationToken()).encodingType("url").requestPayer("requester").build();
411411
}
412412
else { // Else, we're done
413413
done = true;
@@ -480,7 +480,7 @@ private void processPurgeMapTiles(DynmapWorld world, MapType map, ImageVariant v
480480
}
481481
if (result.isTruncated()) { // If more, build continuiation request
482482
req = ListObjectsV2Request.builder().bucketName(bucketname)
483-
.prefix(basekey).delimiter("").maxKeys(1000).continuationToken(result.getContinuationToken()).encodingType("url").requestPayer("requester").build();
483+
.prefix(basekey).delimiter("").maxKeys(1000).continuationToken(result.getNextContinuationToken()).encodingType("url").requestPayer("requester").build();
484484
}
485485
else { // Else, we're done
486486
done = true;
@@ -529,7 +529,7 @@ public boolean setPlayerFaceImage(String playername, FaceType facetype,
529529
}
530530
else {
531531
PutObjectRequest req = PutObjectRequest.builder().bucketName(bucketname).key(baseKey).contentType("image/png").build();
532-
s3.putObject(req, RequestBody.fromBytes(encImage.buf));
532+
s3.putObject(req, RequestBody.fromBytes(Arrays.copyOf(encImage.buf, encImage.len)));
533533
}
534534
done = true;
535535
} catch (S3Exception x) {
@@ -582,7 +582,7 @@ public boolean setMarkerImage(String markerid, BufferOutputStream encImage) {
582582
}
583583
else {
584584
PutObjectRequest req = PutObjectRequest.builder().bucketName(bucketname).key(baseKey).contentType("image/png").build();
585-
s3.putObject(req, RequestBody.fromBytes(encImage.buf));
585+
s3.putObject(req, RequestBody.fromBytes(Arrays.copyOf(encImage.buf, encImage.len)));
586586
}
587587
done = true;
588588
} catch (S3Exception x) {
@@ -611,8 +611,8 @@ public boolean setMarkerFile(String world, String content) {
611611
s3.deleteObject(delreq);
612612
}
613613
else {
614-
PutObjectRequest req = PutObjectRequest.builder().bucketName(bucketname).key(baseKey).contentType("application/json").build();
615-
s3.putObject(req, RequestBody.fromBytes(content.getBytes(StandardCharsets.UTF_8)));
614+
PutObjectRequest req = PutObjectRequest.builder().bucketName(bucketname).key(baseKey).contentType("application/json").build();
615+
s3.putObject(req, RequestBody.fromString(content));
616616
}
617617
done = true;
618618
} catch (S3Exception x) {
@@ -745,7 +745,7 @@ else if (fileid.endsWith(".js")) {
745745
ct = "application/x-javascript";
746746
}
747747
PutObjectRequest req = PutObjectRequest.builder().bucketName(bucketname).key(baseKey).contentType(ct).build();
748-
s3.putObject(req, RequestBody.fromBytes(content.buf));
748+
s3.putObject(req, RequestBody.fromBytes(Arrays.copyOf(content.buf, content.len)));
749749
standalone_cache.put(fileid, digest);
750750
}
751751
done = true;

DynmapCore/src/main/resources/extracted/web/css/dynmap_style.css

Lines changed: 233 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,22 @@
1+
:root {
2+
--colour-highlight: oklch(0.56 0.16 142.24);
3+
--smokey-white: oklch(0.99 0 0);
4+
--gunmetal: oklch(0.29 0.02 277.99);
5+
--charcoal-grey: oklch(0.34 0.03 273.24);
6+
--ship-grey: oklch(0.36 0.02 278.37);
7+
--vampire-grey: oklch(0.45 0.02 278.64);
8+
--cool-grey: oklch(0.72 0.02 270.22);
9+
--slate-grey: oklch(0.6 0.02 264.54);
10+
--status-error: oklch(0.51 0.12 22.01);
11+
}
12+
13+
.montserrat-font {
14+
font-family: "Montserrat", sans-serif;
15+
font-optical-sizing: auto;
16+
font-weight: 400;
17+
font-style: normal;
18+
}
19+
120
/* TILE DEBUGGING */
221
/*.leaflet-tile {
322
margin: -1;
@@ -1019,46 +1038,227 @@
10191038

10201039
/* Login/register panel */
10211040
.dynmaplogin {
1022-
text-align: center;
1023-
width: 100%;
1024-
font-weight: bold;
1025-
color: #FFFFFF;
1041+
display: grid;
1042+
width: 100%;
1043+
height: 100%;
1044+
place-items: center;
1045+
width: 100%;
1046+
font-weight: bold;
1047+
color: #FFFFFF;
1048+
background: var(--vampire-grey);
1049+
font-family: "Montserrat", sans-serif;
1050+
font-optical-sizing: auto;
1051+
font-weight: 400;
1052+
font-style: normal;
1053+
box-sizing: border-box;
1054+
1055+
& * {
1056+
box-sizing: border-box;
1057+
}
1058+
1059+
.container {
1060+
--outer-margin: 2rem;
1061+
container-type: inline-size;
1062+
container-name: container;
1063+
position: relative;
1064+
width: calc(100% - var(--outer-margin) * 2);
1065+
max-width: 960px;
1066+
padding: 3rem;
1067+
margin: var(--outer-margin);
1068+
padding-block-start: 3rem;
1069+
border-radius: 20px;
1070+
/*background-image: url("https://wallpapersok.com/images/file/minecraft-landscape-with-cloudy-sky-b9nxzmdukp1j51zq.jpg"); */
1071+
background-color: var(--gunmetal);
1072+
box-shadow: 0px 30px 30px -5px var(--ship-grey);
1073+
1074+
&::before {
1075+
position: absolute;
1076+
top: 0;
1077+
left: 0;
1078+
z-index: 0;
1079+
content: '';
1080+
display: flex;
1081+
width: 100%;
1082+
height: 100%;
1083+
background: url("https://cdn.modrinth.com/data/fRQREgAc/2eaa1e6a6fa03e485a319a628d6b29ba382855b4_96.webp");
1084+
background-position: right 1rem;
1085+
background-repeat: no-repeat;
1086+
background-size: 25%;
1087+
pointer-events: none;
1088+
opacity: 0.4;
1089+
mix-blend-mode: overlay;
1090+
}
1091+
}
1092+
1093+
h2 {
1094+
margin: 0;
1095+
font-size: 2rem;
1096+
font-weight: 700;
1097+
color: var(--smokey-white);
1098+
1099+
span {
1100+
color: var(--colour-highlight);
1101+
}
1102+
}
1103+
h3 {
1104+
margin: 0;
1105+
margin-block-end: 5rem;
1106+
padding-right: 40px;
1107+
font-size: 1rem;
1108+
font-weight: 700;
1109+
color: var(--cool-grey);
1110+
text-transform: uppercase;
1111+
text-decoration: underline;
1112+
text-decoration-thickness: 1px;
1113+
text-underline-offset: 5px;
1114+
text-decoration-color: var(--colour-highlight);
1115+
1116+
&:has(~ .statusmessage > div) {
1117+
margin-block-end: 3rem;
1118+
}
1119+
}
1120+
1121+
p {
1122+
line-height: 1.4;
1123+
}
1124+
1125+
a {
1126+
color: var(--colour-highlight);
1127+
}
1128+
1129+
code {
1130+
font-family: 'Courier New', Courier, monospace;
1131+
font-size: 14px;
1132+
padding: 4px 6px;
10261133
background: #000000;
1027-
}
1134+
border-radius: 5px;
1135+
}
10281136

1029-
table.loginregister {
1030-
color: #ffffff;
1031-
border: 1px solid rgba(64,64,64,0.6);
1032-
background: #bbb;
1033-
font-weight: bold;
1034-
margin: auto;
1035-
}
1137+
.loginregister {
1138+
font-size: 1rem;
10361139

1037-
td.login {
1038-
vertical-align: top;
1039-
color: #000000;
1040-
background-color: #bbb;
1041-
border: 1px solid rgba(64,64,64,0.6);
1042-
font-weight: bold;
1043-
margin: 2em;
1044-
width: 40em;
1045-
}
1140+
&:has(#register-form:target) #login-form {
1141+
display: none;
1142+
}
10461143

1047-
td.register {
1048-
vertical-align: top;
1049-
color: #000000;
1050-
background-color: #bbb;
1051-
border: 1px solid rgba(64,64,64,0.6);
1052-
font-weight: bold;
1053-
margin: 2em;
1054-
width: 40em;
1144+
#login-form { }
1145+
1146+
#register-form {
1147+
display: none;
1148+
&:target {
1149+
display: block;
1150+
}
1151+
}
1152+
input {
1153+
width: 100%;
1154+
padding: 0;
1155+
font-size: 1rem;
1156+
color: var(--smokey-white);
1157+
border: none;
1158+
background: transparent;
1159+
font-family: inherit;
1160+
font-weight: 500;
1161+
&::placeholder {
1162+
opacity: 0.1;
1163+
color: var(--smokey-white);
1164+
1165+
}
1166+
&:focus-visible {
1167+
background: none;
1168+
border: none;
1169+
outline: none;
1170+
}
1171+
&:is(:-webkit-autofill, :autofill) {
1172+
border: none;
1173+
}
1174+
1175+
&[type="submit"] {
1176+
max-width: 20ch;
1177+
padding-block: 1rem;
1178+
padding-inline: 2rem;
1179+
background-color: var(--colour-highlight);
1180+
border-radius: calc(infinity * 1px);
1181+
border: 2px solid transparent;
1182+
cursor: pointer;
1183+
transition: .2s background ease;
1184+
&:hover {
1185+
background-color: oklch(from var(--colour-highlight) calc(l - 0.04) c h);
1186+
}
1187+
&:focus-visible {
1188+
border: 2px solid var(--smokey-white);
1189+
}
1190+
}
1191+
}
1192+
1193+
label {
1194+
margin-block-end: .2rem;
1195+
color: var(--slate-grey);
1196+
font-size: 0.813rem;
1197+
font-weight: 400;
1198+
}
1199+
}
1200+
1201+
form {
1202+
display: grid;
1203+
grid-template-columns: minmax(100px, 1fr);
1204+
gap: 2rem;
1205+
max-width: 60ch;
1206+
1207+
p {
1208+
grid-column: 1 / -1;
1209+
}
1210+
}
1211+
.form-item {
1212+
position: relative;
1213+
grid-column: 1 / -1;
1214+
display: flex;
1215+
flex-direction: column;
1216+
padding-block: 1rem;
1217+
padding-inline: 2rem;
1218+
background-color: var(--charcoal-grey);
1219+
border-radius: 10px;
1220+
border: 2px solid transparent;
1221+
transition: border .5s ease;
1222+
&:focus-within {
1223+
border: 2px solid var(--colour-highlight);
1224+
color: black;
1225+
}
1226+
}
1227+
1228+
@container (width > 400px) {
1229+
form {
1230+
grid-template-columns: repeat(2, minmax(100px, 1fr));
1231+
1232+
}
1233+
1234+
.form-item.shortened {
1235+
grid-column: 1;
1236+
+ .shortened {
1237+
grid-column: 2;
1238+
}
1239+
}
1240+
1241+
h3 {
1242+
padding: 0;
1243+
}
1244+
}
10551245
}
10561246

10571247
div.statusmessage {
1058-
color: #FF0000;
1059-
font-weight: bold;
1060-
font-size: 24px;
1061-
1248+
position: relative;
1249+
z-index: 2;
1250+
&:empty {
1251+
display: none;
1252+
}
1253+
> div {
1254+
margin-block-end: 2rem;
1255+
padding: 1rem;
1256+
color: var(--smokey-white);
1257+
font-weight: bold;
1258+
font-size: 16px;
1259+
background: linear-gradient(90deg, var(--status-error) 30%, transparent 80%);
1260+
font-weight: 300;
1261+
border-radius: 5px;
10621262
}
10631263

10641264
.logincontainer {

0 commit comments

Comments
 (0)