srgnis / body-health-system Goto Github PK
View Code? Open in Web Editor NEWA new health system for Minecraft
License: MIT License
A new health system for Minecraft
License: MIT License
It seems that trinkets that add more hp or just mods in general that can give you extra hp dont scale with / add to your body health so even when you have 5 extra hearts, taking 4 damage from fall damage for example; will still break your legs even though you should have more heart points into that category. This should also be the case with the absorption effect, spreading out evenly onto different body parts based on the golden hearts applied to your character.
Each additional heart should spread out with a priority list of head>chest>arms>legs (configurable, such as head>arms>legs>chest if you wanted to supply heart points to the weakest body parts first). Half hearts should still try to be calculated, so smaller health buffs can still feel useful. If there are not enough hearts to spread out, even with half hearts, it will just spread what it can on the prioritized body parts first until you get more hearts.
@SrGnis please add this. I'm making a newer realistic modpack and this would be much help. thanks
Could be in villages or temples. Anything that has chests in it. I feel like the craft recipes for plasters and med kits are a little too annoying to make lol.
hello! I just wanted to suggest being able to reduce the size of the character in the hud and if he could stay behind the chat so I could read it, thanks! (and key bind to open hud to see what's wrong with my character.)
As of version 0.3.1, if I start drowning, ill be dead in 4 ticks. No matter how much chest health I have.
The chest armor is reducing that damage and is the only thing defining the ability of player character to live a bit longer xd
Possible solution would be: the possibility to define the minimal damage before applying it to body part.
Or, if that is even possible, to define damage reduction from specified sources.
If possible, a configuration option for natural regen still being functional, but modifiable; would be a good option for the players. Possibly with an option to change the speed of the natural regen based on ticks. Effectively offering a way to still regen health, but at a configurable pace. Additionally making the healing items stack onto it I feel would also be a good addition, rather than an instant heal since there are potions for that.
please
When the Body Health system and the Gravestone mod are both active, a potential bug may occur. If you die with a life regeneration effect, selecting respawn may cause you to get stuck at the death location (instead of returning to your spawn point or a designated location). In third-person view, you won't be able to see your player model, and you won't be able to move, break blocks, attack, open the map, or perform other actions. Pressing the 'E' key to open the inventory panel may result in a flickering interface, but you'll see your character in the panel lying down and injured. In other words, you are in a quantum superposition, like Schrödinger's cat, in some unknown state of life and death.
Upon exiting and re-entering the game, you should return to normal. However, all the items in your inventory before your death won't disappear (even if you have 'keepInventory: false' set). The gravestone will still generate and contain the same items as you had, effectively resulting in item duplication.
Posion damage can kill the player reducing the health of the torso or head to 0.
Posion shold not be able to reduce to 0 parts which are a requirement for the player to stay alive.
Medkits don't work in multiplayer, when i right-click to open the medkit GUI nothing shows.
Version: 0.3.0
Error in the console of the server when trying to use the medkit:
Failed to handle packet net.minecraft.class_2886@6d5487c8, suppressing error
java.lang.RuntimeException: Cannot load class net.fabricmc.fabric.api.client.networking.v1.ClientPlayNetworking in environment type SERVER
at Not Enough Crashes deobfuscated stack trace.(1.19.2+build.28) ~[?:?]
at net.fabricmc.loader.impl.transformer.FabricTransformer.transform(FabricTransformer.java:59) ~[fabric-loader-0.14.10.jar:?]
at net.fabricmc.loader.impl.launch.knot.KnotClassDelegate.getPreMixinClassByteArray(KnotClassDelegate.java:454) ~[fabric-loader-0.14.10.jar:?]
at net.fabricmc.loader.impl.launch.knot.KnotClassDelegate.getPostMixinClassByteArray(KnotClassDelegate.java:407) ~[fabric-loader-0.14.10.jar:?]
at net.fabricmc.loader.impl.launch.knot.KnotClassDelegate.tryLoadClass(KnotClassDelegate.java:323) ~[fabric-loader-0.14.10.jar:?]
at net.fabricmc.loader.impl.launch.knot.KnotClassDelegate.loadClass(KnotClassDelegate.java:218) ~[fabric-loader-0.14.10.jar:?]
at net.fabricmc.loader.impl.launch.knot.KnotClassLoader.loadClass(KnotClassLoader.java:145) ~[fabric-loader-0.14.10.jar:?]
at java.lang.ClassLoader.loadClass(ClassLoader.java:521) ~[?:?]
at xyz.srgnis.bodyhealthsystem.network.ClientNetworking.requestBodyData(ClientNetworking.java:67) ~[Body%20Health%20System.jar:?]
at xyz.srgnis.bodyhealthsystem.client.screen.HealScreenHandler.(HealScreenHandler.java:45) ~[Body%20Health%20System.jar:?]
at xyz.srgnis.bodyhealthsystem.items.MedkitItem$1.createMenu(MedkitItem.java:65) ~[Body%20Health%20System.jar:?]
at net.minecraft.server.network.ServerPlayerEntity.openHandledScreen(ServerPlayerEntity:1040) ~[?:?]
at xyz.srgnis.bodyhealthsystem.items.MedkitItem.use(MedkitItem.java:48) ~[Body%20Health%20System.jar:?]
at net.minecraft.item.ItemStack.use(ItemStack:276) ~[?:?]
at net.minecraft.server.network.ServerPlayerInteractionManager.interactItem(ServerPlayerInteractionManager:290) ~[?:?]
at net.minecraft.server.network.ServerPlayNetworkHandler.onPlayerInteractItem(ServerPlayNetworkHandler:1182) ~[?:?]
at net.minecraft.network.packet.c2s.play.PlayerInteractItemC2SPacket.apply(PlayerInteractItemC2SPacket:29) ~[?:?]
at net.minecraft.network.packet.c2s.play.PlayerInteractItemC2SPacket.apply(PlayerInteractItemC2SPacket:7) ~[?:?]
at net.minecraft.network.NetworkThreadUtils.method_11072(NetworkThreadUtils:22) ~[?:?]
at net.minecraft.server.ServerTask.run(ServerTask:18) ~[?:?]
at net.minecraft.util.thread.ThreadExecutor.executeTask(ThreadExecutor:157) ~[?:?]
at net.minecraft.util.thread.ReentrantThreadExecutor.executeTask(ReentrantThreadExecutor:23) ~[?:?]
at net.minecraft.server.MinecraftServer.executeTask(MinecraftServer:776) ~[server-intermediary.jar:?]
at net.minecraft.server.MinecraftServer.executeTask(MinecraftServer:159) ~[server-intermediary.jar:?]
at net.minecraft.util.thread.ThreadExecutor.runTask(ThreadExecutor:131) ~[?:?]
at net.minecraft.server.MinecraftServer.runOneTask(MinecraftServer:758) ~[server-intermediary.jar:?]
at net.minecraft.server.MinecraftServer.runTask(MinecraftServer:752) ~[server-intermediary.jar:?]
at net.minecraft.util.thread.ThreadExecutor.runTasks(ThreadExecutor:116) ~[?:?]
at net.minecraft.server.MinecraftServer.runTasksTillTickEnd(MinecraftServer:736) ~[server-intermediary.jar:?]
at net.minecraft.server.MinecraftServer.runServer(MinecraftServer:669) ~[server-intermediary.jar:?]
at net.minecraft.server.MinecraftServer.method_29739(MinecraftServer:257) ~[server-intermediary.jar:?]
at java.lang.Thread.run(Thread.java:1589) [?:?]
first aid looks like it's been dead for a long time and it's been a long time since there was a PR that added multiplayer, that players can heal each other... could you integrate this PR in your mod?
Hello, I'm really glad this mod is being ported to fabric, although I appear to have found a semi game-breaking problem.
P.S: Feel free to ask if you need help with testing something! 😄
When you have a totem in your hand you die regardless, and you lose your entire inventory whilst also getting stuck if you don't respawn fast enough, athough relogging fixes getting stuck.
Would I be correct to assume this a bug? (My apologies if it's intended.)
E.G.
There is many other versions but there is no 1.19.4 for fabric and i'm not sure if there is reason or anything to why it doesn't exist.
I found that server side code is being executed in the client side as is the case of ServerNetworking.syncBody(pe);
in OnHealMixin
.
A revision of the code is needed, especially the mixins.
Versions 0.3.4 and 0.3.5 crash the client. 0.3.3 starts successfully. Minecraft 1.20.1 fabric 0.14.22. From the installed mods: fabric-api-0.87.0+1.20.1.jar . Tested on TLauncher and GravitLauncher launchers.
crash-2023-08-20_12.23.12-client.txt
Compatibility with levelZ so the scalling health works, like let us choose where we want the extra health to be
It would look better if the HUD is only available for survival mode and not in creative mode, as it can be annoying for some players to see the HUD in creative mode and that it has no use.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.