fabric-1.18: remap and update to 1.18-rc1+build.1

This commit is contained in:
Kosma Moczek 2021-11-25 19:33:41 +01:00
parent bc7405e8f4
commit 3d95f9250a
6 changed files with 21 additions and 19 deletions

View File

@ -5,7 +5,7 @@ buildscript {
mavenCentral() mavenCentral()
} }
dependencies { dependencies {
classpath group: 'net.fabricmc', name: 'fabric-loom', version: '0.8-SNAPSHOT' classpath group: 'net.fabricmc', name: 'fabric-loom', version: '0.10-SNAPSHOT'
} }
} }
apply plugin: 'fabric-loom' apply plugin: 'fabric-loom'
@ -15,8 +15,8 @@ loom {
} }
} }
sourceCompatibility = JavaVersion.VERSION_16 sourceCompatibility = JavaVersion.VERSION_17
targetCompatibility = JavaVersion.VERSION_16 targetCompatibility = JavaVersion.VERSION_17
archivesBaseName = project.archives_base_name archivesBaseName = project.archives_base_name
version = parent.version version = parent.version

View File

@ -1,12 +1,14 @@
# Done to increase the memory available to gradle. # Done to increase the memory available to gradle.
org.gradle.jvmargs=-Xmx1G org.gradle.jvmargs=-Xmx1G
# Fabric Properties
# check these on https://fabricmc.net/use
minecraft_version=1.17.1
yarn_mappings=1.17.1+build.1
loader_version=0.11.6
# Mod Properties # Mod Properties
archives_base_name=Dynmap archives_base_name=Dynmap
# Dependencies
# currently not on the main fabric site, check on the maven: https://maven.fabricmc.net/net/fabricmc/fabric-api/fabric-api # Fabric Properties
fabric_version=0.36.1+1.17 # check these on https://fabricmc.net/versions.html
minecraft_version=1.18-rc1
yarn_mappings=1.18-rc1+build.1
loader_version=0.12.5
#Fabric api
fabric_version=0.43.1+1.18

View File

@ -310,7 +310,7 @@ public class DynmapPlugin {
} }
// TODO: Consider whether cheats are enabled for integrated server // TODO: Consider whether cheats are enabled for integrated server
return server.isSinglePlayer() && player.equalsIgnoreCase(server.getUserName()); return server.isSingleplayer() && player.equalsIgnoreCase(server.getSinglePlayerName());
} }
boolean hasPerm(PlayerEntity psender, String permission) { boolean hasPerm(PlayerEntity psender, String permission) {

View File

@ -100,7 +100,7 @@ public class FabricPlayer extends FabricCommandSender implements DynmapPlayer {
} }
Vec3d pos = player.getPos(); Vec3d pos = player.getPos();
return FabricAdapter.toDynmapLocation(plugin, player.getServerWorld(), pos.getX(), pos.getY(), pos.getZ()); return FabricAdapter.toDynmapLocation(plugin, player.getWorld(), pos.getX(), pos.getY(), pos.getZ());
} }
@Override @Override

View File

@ -181,7 +181,7 @@ public class FabricServer extends DynmapServerInterface {
@Override @Override
public String getServerName() { public String getServerName() {
String sn; String sn;
if (server.isSinglePlayer()) if (server.isSingleplayer())
sn = "Integrated"; sn = "Integrated";
else else
sn = server.getServerIp(); sn = server.getServerIp();
@ -308,7 +308,7 @@ public class FabricServer extends DynmapServerInterface {
@Override @Override
public void broadcastMessage(String msg) { public void broadcastMessage(String msg) {
Text component = new LiteralText(msg); Text component = new LiteralText(msg);
server.getPlayerManager().broadcastChatMessage(component, MessageType.SYSTEM, Util.NIL_UUID); server.getPlayerManager().broadcast(component, MessageType.SYSTEM, Util.NIL_UUID);
Log.info(stripChatColor(msg)); Log.info(stripChatColor(msg));
} }
@ -548,7 +548,7 @@ public class FabricServer extends DynmapServerInterface {
@Override @Override
public String getServerIP() { public String getServerIP() {
if (server.isSinglePlayer()) if (server.isSingleplayer())
return "0.0.0.0"; return "0.0.0.0";
else else
return server.getServerIp(); return server.getServerIp();

View File

@ -26,8 +26,8 @@
], ],
"depends": { "depends": {
"fabricloader": ">=0.7.4", "fabricloader": ">=0.12.5",
"fabric": ">=0.17.0", "fabric": ">=0.43.1",
"minecraft": "1.17.1" "minecraft": "1.18-rc.1"
} }
} }