Skip to content

Commit

Permalink
Update to 1.19.4
Browse files Browse the repository at this point in the history
  • Loading branch information
BlakeJH committed Apr 5, 2023
1 parent 1d23ff6 commit 3e91bb6
Show file tree
Hide file tree
Showing 7 changed files with 20 additions and 22 deletions.
2 changes: 1 addition & 1 deletion build.gradle
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
plugins {
id 'fabric-loom' version '0.7-SNAPSHOT'
id 'fabric-loom' version '1.1-SNAPSHOT'
id 'maven-publish'
}

Expand Down
10 changes: 5 additions & 5 deletions gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,13 @@
org.gradle.jvmargs=-Xmx1G
# Fabric Properties
# check these on https://modmuss50.me/fabric.html
minecraft_version=1.16.5
yarn_mappings=1.16.5+build.6
loader_version=0.11.3
minecraft_version=1.19.4
yarn_mappings=1.19.4+build.1
loader_version=0.14.19
# Mod Properties
mod_version=1
maven_group=me.UltraBlackLinux
maven_group=com.blake_jh
archives_base_name=noHurtCam
# Dependencies
# check this on https://modmuss50.me/fabric.html
fabric_version=0.25.1+build.416-1.16
fabric_version=0.77.0+1.19.4
2 changes: 1 addition & 1 deletion gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-7.0.2-bin.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-7.2-bin.zip
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
Original file line number Diff line number Diff line change
@@ -1,20 +1,20 @@
package me.ultrablacklinux.nohurtcam;
package com.blake_jh.nohurtcam;

import net.fabricmc.api.ModInitializer;
import net.fabricmc.fabric.api.client.event.lifecycle.v1.ClientTickEvents;
import net.fabricmc.fabric.api.client.keybinding.v1.KeyBindingHelper;
import net.minecraft.client.MinecraftClient;
import net.minecraft.client.options.KeyBinding;
import net.minecraft.client.option.KeyBinding;
import net.minecraft.text.Text;
import org.lwjgl.glfw.GLFW;

public class NoHurtCam implements ModInitializer {
public static boolean toggledOn = false;
public static boolean toggledOn = true; // Set the toggledOn variable to true
MinecraftClient client = MinecraftClient.getInstance();
@Override
public void onInitialize() {
KeyBinding k = KeyBindingHelper.registerKeyBinding(new KeyBinding("key.noHurtCam.toggle",
GLFW.GLFW_KEY_F8,
KeyBinding k = KeyBindingHelper.registerKeyBinding(new KeyBinding("key.noHurtCam.toggle",
GLFW.GLFW_KEY_F8,
"category.noHurtCam"));

ClientTickEvents.END_CLIENT_TICK.register(client -> {
Expand All @@ -27,8 +27,6 @@ public void onInitialize() {
toggledOn = true;
client.player.sendMessage(Text.of("§9[NoHurtCam] §rDisabled Hurtcam"), false);
}


}
});
}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package me.ultrablacklinux.nohurtcam.mixin;
package com.blake_jh.nohurtcam.mixin;

import me.ultrablacklinux.nohurtcam.NoHurtCam;
import com.blake_jh.nohurtcam.NoHurtCam;
import net.minecraft.client.render.GameRenderer;
import net.minecraft.client.util.math.MatrixStack;
import org.spongepowered.asm.mixin.Mixin;
Expand All @@ -10,8 +10,8 @@

@Mixin(GameRenderer.class)
public class GameRendererMixin {
@Inject(at = @At("HEAD"), method = "bobViewWhenHurt(Lnet/minecraft/client/util/math/MatrixStack;F)V", cancellable = true)
@Inject(at = @At("HEAD"), method = "tiltViewWhenHurt(Lnet/minecraft/client/util/math/MatrixStack;F)V", cancellable = true)
public void bobViewWhenHurt(MatrixStack matrixStack_1, float float_1, CallbackInfo ci) {
if (NoHurtCam.toggledOn) ci.cancel();
}
}
}
4 changes: 2 additions & 2 deletions src/main/resources/fabric.mod.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"name": "NoHurtCam",
"description": "Removes the damage Screenshake",
"authors": [
"UltraBlackLinux"
"Blake_JH"
],
"contact": {
"homepage": "https://github.com/UltraBlackLinux/noHurtCam",
Expand All @@ -16,7 +16,7 @@
"environment": "*",
"entrypoints": {
"main": [
"me.ultrablacklinux.nohurtcam.NoHurtCam"
"com.blake_jh.nohurtcam.NoHurtCam"
]
},
"mixins": [
Expand Down
4 changes: 2 additions & 2 deletions src/main/resources/noHurtCam.mixins.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
{
"required": true,
"minVersion": "0.8",
"package": "me.ultrablacklinux.nohurtcam.mixin",
"compatibilityLevel": "JAVA_8",
"package": "com.blake_jh.nohurtcam.mixin",
"compatibilityLevel": "JAVA_17",
"mixins": [
"GameRendererMixin"
],
Expand Down

0 comments on commit 3e91bb6

Please sign in to comment.