Skip to content

Commit a4f8ce3

Browse files
committed
Fix Build & Translator Issues
1 parent 002d43c commit a4f8ce3

File tree

3 files changed

+12
-4
lines changed

3 files changed

+12
-4
lines changed

build.gradle

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,8 @@ def issuesUrl =
3434
version = effectiveVersion
3535
group = project.maven_group
3636

37+
def mainModId = niceWurstEnabled ? "nicewurst" : "wurst"
38+
3739
base {
3840
archivesName = effectiveArchiveName
3941
}
@@ -155,7 +157,7 @@ processResources {
155157

156158
filesMatching("fabric.mod.json") {
157159
expand([
158-
modId: modId,
160+
modId: mainModId,
159161
version: modVersion,
160162
modName: modName,
161163
modDescription: modDescription,

src/main/java/net/wurstclient/WurstTranslator.java

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -231,10 +231,16 @@ private boolean isBuiltInWurstResourcePack(Resource resource)
231231
{
232232
KnownPack knownPack = Optional.ofNullable(resource)
233233
.flatMap(Resource::knownPackInfo).orElse(null);
234+
234235
if(knownPack == null)
236+
return true; // allow dev / unknown packs in your setup
237+
238+
if(!"fabric".equals(knownPack.namespace()))
235239
return false;
236240

237-
return "fabric".equals(knownPack.namespace())
238-
&& "wurst".equals(knownPack.id());
241+
String id = knownPack.id();
242+
return "wurst".equals(id) || "wurst_testmod".equals(id)
243+
|| "nicewurst".equals(id);
239244
}
245+
240246
}

src/main/resources/assets/wurst/translations/en_us.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@
4242
"description.wurst.hack.autopotion": "Automatically throws splash potions of instant health when your health is low.",
4343
"description.wurst.hack.autoreconnect": "Automatically reconnects when you get kicked from the server.",
4444
"description.wurst.hack.autorespawn": "Automatically respawns you whenever you die.",
45-
"description.wurst.hack.offlinesettings": "Immediately reconnects to the last server when you are kicked for logging in from another location.",
45+
"description.wurst.hack.offlinesettings": "Offers offline server detection, quick reconnect and other offline server abilities.",
4646
"description.wurst.hack.autosign": "Instantly writes whatever text you want on every sign you place or edit. Once activated, you can write normally on the first sign to specify the text for all other signs.",
4747
"description.wurst.hack.autosoup": "Automatically eats soup when your health is low.\n\n??lNote:??r This hack ignores hunger and assumes that eating soup directly refills your health. If the server you are playing on is not configured to do that, use AutoEat instead.",
4848
"description.wurst.hack.autosprint": "Makes you sprint automatically.",

0 commit comments

Comments
 (0)