Skip to content

Commit

Permalink
Updated to 1.19.4
Browse files Browse the repository at this point in the history
  • Loading branch information
MisterJulsen committed Oct 18, 2023
1 parent 63f491c commit 5254fea
Show file tree
Hide file tree
Showing 12 changed files with 25 additions and 24 deletions.
6 changes: 3 additions & 3 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ apply plugin: 'net.minecraftforge.gradle'
apply plugin: 'org.parchmentmc.librarian.forgegradle'


version = '1.0.0-1.19.3'
version = '1.0.0-1.19.4'
group = 'de.mrjulsen.mineify' // http://maven.apache.org/guides/mini/guide-naming-conventions.html
archivesBaseName = 'mineify'

Expand All @@ -47,7 +47,7 @@ minecraft {
//
// Use non-default mappings at your own risk. They may not always work.
// Simply re-run your setup task after changing the mappings to update your workspace.
mappings channel: 'parchment', version: '1.19.3-2023.06.25-1.19.3'
mappings channel: 'parchment', version: '1.19.4-2023.06.26-1.19.4'

// accessTransformer = file('src/main/resources/META-INF/accesstransformer.cfg') // Currently, this location cannot be changed from the default.

Expand Down Expand Up @@ -158,7 +158,7 @@ dependencies {
// Specify the version of Minecraft to use. If this is any group other than 'net.minecraft', it is assumed
// that the dep is a ForgeGradle 'patcher' dependency, and its patches will be applied.
// The userdev artifact is a special name and will get all sorts of transformations applied to it.
minecraft 'net.minecraftforge:forge:1.19.3-44.1.0'
minecraft 'net.minecraftforge:forge:1.19.4-45.2.0'

// https://mavenlibs.com/maven/dependency/org.jcraft/jorbis
// minecraftLibrary ("org.jcraft:jorbis:0.0.17")
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -236,7 +236,7 @@ public void onClose() {

@Override
public void render(PoseStack stack, int mouseX, int mouseY, float partialTicks) {
renderBackground(stack, 0);
renderBackground(stack);
drawCenteredString(stack, this.font, title, this.width / 2, guiTop, 16777215);
drawCenteredString(stack, this.font, textAttenuationDistance, this.width / 2, guiTop + 150 + 10, 16777215);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -187,7 +187,7 @@ public void reload() {
@Override
public void render(PoseStack pPoseStack, int pMouseX, int pMouseY, float pPartialTick) {

this.renderDirtBackground(0);
renderDirtBackground(pPoseStack);

if (this.isLoading()) {
drawCenteredString(pPoseStack, this.font, textLoading, this.width / 2, 100, 16777215);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ public void onClose() {

@Override
public void render(PoseStack stack, int mouseX, int mouseY, float partialTicks) {
renderBackground(stack, 0);
renderBackground(stack);
drawCenteredString(stack, this.font, title, this.width / 2, guiTop, 16777215);

super.render(stack, mouseX, mouseY, partialTicks);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -150,7 +150,7 @@ public void onClose() {

@Override
public void render(PoseStack stack, int mouseX, int mouseY, float partialTicks) {
renderBackground(stack, 0);
renderBackground(stack);
drawCenteredString(stack, this.font, title, this.width / 2, guiTop, 16777215);
super.render(stack, mouseX, mouseY, partialTicks);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,7 @@ public void onClose() {
}

private String getQualitySuffix(byte value) {
value = Mth.clamp(value, AudioFileConfig.OGG_QUALITY_MAX, AudioFileConfig.OGG_QUALITY_MIN);
value = (byte)Mth.clamp(value, AudioFileConfig.OGG_QUALITY_MAX, AudioFileConfig.OGG_QUALITY_MIN);
switch (value) {
case AudioFileConfig.OGG_QUALITY_MIN:
return "gui.mineify.quality.best";
Expand All @@ -180,7 +180,7 @@ private String getQualitySuffix(byte value) {
@Override
@SuppressWarnings("resource")
public void render(PoseStack stack, int mouseX, int mouseY, float partialTicks) {
renderBackground(stack, 0);
renderBackground(stack);
drawCenteredString(stack, this.font, title, this.width / 2, guiTop, 16777215);
drawCenteredString(stack, this.font, textFilename, this.width / 2, guiTop + 25, 16777215);

Expand Down
3 changes: 2 additions & 1 deletion src/main/java/de/mrjulsen/mineify/commands/SoundCommand.java
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@
import net.minecraft.commands.arguments.EntityArgument;
import net.minecraft.commands.arguments.coordinates.Vec3Argument;
import net.minecraft.core.BlockPos;
import net.minecraft.core.Vec3i;
import net.minecraft.network.chat.Component;
import net.minecraft.server.level.ServerPlayer;
import net.minecraft.world.phys.Vec3;
Expand Down Expand Up @@ -266,7 +267,7 @@ private static int playSound(CommandSourceStack pSource, Collection<ServerPlayer
}
}

ServerApi.playSound(pSound, new ServerPlayer[] { serverplayer }, new BlockPos(vec3), attenuationDistance, f, pPitch);
ServerApi.playSound(pSound, new ServerPlayer[] { serverplayer }, new BlockPos(new Vec3i((int)vec3.x, (int)vec3.y, (int)vec3.z)), attenuationDistance, f, pPitch);
++i;
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,6 @@ private static <T> void registerPacket(Class<T> clazz, IPacketBase<T> packet, @N
}

public static void sendToClient(Object o, ServerPlayer player) {
NetworkManager.MOD_CHANNEL.sendTo(o, player.connection.getConnection(), NetworkDirection.PLAY_TO_CLIENT);
NetworkManager.MOD_CHANNEL.sendTo(o, player.connection.connection, NetworkDirection.PLAY_TO_CLIENT);
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,6 @@ public class AudioFileConfig {
*/
public AudioFileConfig(ESoundChannels channels, byte quality) {
this.channels = channels;
this.quality = Mth.clamp(quality, OGG_QUALITY_MAX, OGG_QUALITY_MIN);
this.quality = (byte)Mth.clamp(quality, OGG_QUALITY_MAX, OGG_QUALITY_MIN);
}
}
8 changes: 4 additions & 4 deletions src/main/resources/META-INF/mods.toml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
# The name of the mod loader type to load - for regular FML @Mod mods it should be javafml
modLoader="javafml" #mandatory
# A version range to match for said mod loader - for regular FML @Mod it will be the forge version
loaderVersion="[44,)" #mandatory This is typically bumped every Minecraft version by Forge. See our download page for lists of versions.
loaderVersion="[45,)" #mandatory This is typically bumped every Minecraft version by Forge. See our download page for lists of versions.
# The license for you mod. This is mandatory metadata and allows for easier comprehension of your redistributive properties.
# Review your options at https://choosealicense.com/. All rights reserved is the default copyright stance, and is thus the default here.
license="All rights reserved"
Expand All @@ -23,7 +23,7 @@ version="${file.jarVersion}" #mandatory
# A display name for the mod
displayName="Mineify" #mandatory
# A URL to query for updates for this mod. See the JSON update specification https://mcforge.readthedocs.io/en/latest/gettingstarted/autoupdate/
updateJSONURL="https://raw.githubusercontent.com/MisterJulsen/Mineify/1.19.3/update.json" #optional
updateJSONURL="https://raw.githubusercontent.com/MisterJulsen/Mineify/1.19.4/update.json" #optional
# A URL for the "homepage" for this mod, displayed in the mod UI
displayURL="https://www.curseforge.com/minecraft/mc-mods/mineify" #optional
# A file name (in the root of the mod JAR) containing a logo for display
Expand All @@ -43,7 +43,7 @@ With Mineify, each player can upload their own sounds or music to the server and
# Does this dependency have to exist - if not, ordering below must be specified
mandatory=true #mandatory
# The version range of the dependency
versionRange="[44,)" #mandatory
versionRange="[45,)" #mandatory
# An ordering relationship for the dependency - BEFORE or AFTER required if the relationship is not mandatory
ordering="NONE"
# Side this dependency is applied on - BOTH, CLIENT or SERVER
Expand All @@ -53,6 +53,6 @@ With Mineify, each player can upload their own sounds or music to the server and
modId="minecraft"
mandatory=true
# This version range declares a minimum of the current minecraft version up to but not including the next major version
versionRange="[1.19.3,1.20)"
versionRange="[1.19.4,1.20)"
ordering="NONE"
side="BOTH"
12 changes: 6 additions & 6 deletions src/main/resources/pack.mcmeta
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
{
"pack": {
"description": "mineify resources",
"pack_format": 12,
"forge:resource_pack_format": 12,
"forge:data_pack_format": 10
"description": {
"text": "mineify resources"
},
"forge:server_data_pack_format": 12,
"pack_format": 13
}
}

}
4 changes: 2 additions & 2 deletions update.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"promos": {
"1.19.3-latest": "1.0.0-1.19.3",
"1.19.3-recommended": "1.0.0-1.19.3"
"1.19.4-latest": "1.0.0-1.19.4",
"1.19.4-recommended": "1.0.0-1.19.4"
},
"homepage": "https://www.curseforge.com/minecraft/mc-mods/mineify"
}

0 comments on commit 5254fea

Please sign in to comment.