-
Notifications
You must be signed in to change notification settings - Fork 26
Multi Version Bridge API #143
Conversation
moehreag
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A lot of good things, but also still some major issues. Of course, this is nowhere near finished, but the more bugs can be fixed already the less we have to find afterwards.
1.20/src/main/java/io/github/axolotlclient/modules/hud/gui/hud/simple/CustomHudEntry.java
Outdated
Show resolved
Hide resolved
| import net.minecraft.resource.Identifier; | ||
| import org.jetbrains.annotations.Nullable; | ||
|
|
||
| public class AxoRenderContextImpl implements AxoRenderContext { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
On 1.8.9, this should ideally be an implementation akin to GuiGraphics on 1.20.1/1.21. On those newer versions, it should be a wrapper implementation. Another reason to prefer newer methods as a base are differences in parameter types and method usages, f.e. in regards to drawing textures (blitSprite methods) due to render types as well as text rendering (which isn't directly being delegated to the TextRenderer/Font). As such, a stateful matrix implementation might be necessary for 1.8.9 as well.
1.8.9/src/main/java/io/github/axolotlclient/bridge/impl/AxoRenderContextImpl.java
Show resolved
Hide resolved
1.8.9/src/main/java/io/github/axolotlclient/bridge/impl/AxoRenderContextImpl.java
Outdated
Show resolved
Hide resolved
common/src/main/java/io/github/axolotlclient/modules/hud/gui0/hud/item/ArrowHud.java
Outdated
Show resolved
Hide resolved
common/src/main/java/io/github/axolotlclient/modules/hud/gui0/hud/simple/CPSHud.java
Outdated
Show resolved
Hide resolved
common/src/main/java/io/github/axolotlclient/modules/hud/gui0/hud/simple/CPSHud.java
Outdated
Show resolved
Hide resolved
common/src/main/java/io/github/axolotlclient/modules/hud/gui0/hud/simple/PingHud.java
Outdated
Show resolved
Hide resolved
| return camera.distanceTo(receiving.getRotationVec(1)); | ||
| private static double getAttackDistance(AxoEntity attacking, AxoEntity receiving) { | ||
| Vec3 camera = attacking.getRotation(1); | ||
| return camera.dist(receiving.getRotation(1)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Other versions do a manual raycast here which probably works better. However, the method used is not available on 1.8.9.
|
Resolved some of the comments. The code currently is ugly and has extraneous diffs, but I will clean them up later with some automated tooling. I just want to get everything in a working state before I deal with that. |
…ause mojmap) note that this commit DOES NOT implement proper functionality (events, calling the correct render events, etc).
|
Limiting the scope of this now. Only porting Hypixel and HUD modules, and not even all HUD modules. I want this to be in an usable state in a few months, and begin testing soon. Future work can include porting other modules / cleanup. |
improve user agent format
- too early initialization of hud bounds - potion hud sprites - wrong parameters in gui mixins - icon hud getting cut off - trap upgrade icons - add a few todos
# Conflicts: # 1.16_combat-6/src/main/java/io/github/axolotlclient/AxolotlClient.java # 1.16_combat-6/src/main/java/io/github/axolotlclient/modules/hud/HudManager.java # 1.16_combat-6/src/main/java/io/github/axolotlclient/modules/hud/gui/hud/PotionsHud.java # 1.16_combat-6/src/main/java/io/github/axolotlclient/modules/hypixel/StatsMod.java # 1.20/src/main/java/io/github/axolotlclient/AxolotlClient.java # 1.20/src/main/java/io/github/axolotlclient/modules/hud/HudManager.java # 1.20/src/main/java/io/github/axolotlclient/modules/hud/gui/hud/PotionsHud.java # 1.20/src/main/java/io/github/axolotlclient/modules/hypixel/StatsMod.java # 1.21.7/build.gradle.kts # 1.21.7/src/main/java/io/github/axolotlclient/AxolotlClient.java # 1.21.7/src/main/java/io/github/axolotlclient/mixin/PlayerEntityRendererMixin.java # 1.21.7/src/main/java/io/github/axolotlclient/modules/hud/HudManager.java # 1.21.7/src/main/java/io/github/axolotlclient/modules/hud/gui/hud/PotionsHud.java # 1.21.7/src/main/java/io/github/axolotlclient/modules/hypixel/StatsMod.java # 1.21/src/main/java/io/github/axolotlclient/AxolotlClient.java # 1.21/src/main/java/io/github/axolotlclient/modules/hud/HudManager.java # 1.21/src/main/java/io/github/axolotlclient/modules/hud/gui/hud/PotionsHud.java # 1.21/src/main/java/io/github/axolotlclient/modules/hypixel/StatsMod.java # 1.8.9/src/main/java/io/github/axolotlclient/AxolotlClient.java # 1.8.9/src/main/java/io/github/axolotlclient/modules/hud/HudManager.java # 1.8.9/src/main/java/io/github/axolotlclient/modules/hud/gui/hud/PotionsHud.java # 1.8.9/src/main/java/io/github/axolotlclient/modules/hypixel/StatsMod.java # common/src/main/java/io/github/axolotlclient/AxolotlClientCommon.java # common/src/main/resources/assets/axolotlclient/lang/en_us.json # gradle.properties
- store filters as base64 to prevent conflicts with commas
Provide an internal API over Minecraft to remove duplicated code across minecraft versions.
This is implemented via a set of interfaces, which are injected via loom interface injection (at compile time) and Mixins (at runtime). A stub class will be exposed to
commonas API, which provides static methods. These methods are overwritten via Mixin at runtime.Goals:
commonNon-goals:
Checklist:
1.8.9(reference implementation for ports)1.161.201.211.21.4Port other modulesDuring the porting process,
0or some other suffix may be appended to avoid name collisions. These will be removed once colliding packages & classes have been abstracted away.