├── .github └── workflows │ └── build.yml ├── .gitignore ├── JexChangelog.txt ├── LICENSE ├── README.md ├── build.gradle ├── gradle.properties ├── gradle └── wrapper │ ├── gradle-wrapper.jar │ └── gradle-wrapper.properties ├── gradlew ├── gradlew.bat ├── lib ├── IRCClient.jar ├── baritone-1.6.3-dev.jar └── sodium.jar ├── settings.gradle └── src └── main ├── java ├── bedrockminer │ └── utils │ │ ├── BlockBreaker.java │ │ ├── BlockPlacer.java │ │ ├── BreakingFlowController.java │ │ ├── CheckingEnvironment.java │ │ ├── InventoryManager.java │ │ ├── Messager.java │ │ └── TargetBlock.java ├── me │ └── dustin │ │ ├── events │ │ ├── EventManager.java │ │ └── core │ │ │ ├── Event.java │ │ │ ├── EventHook.java │ │ │ ├── EventListener.java │ │ │ ├── annotate │ │ │ └── EventPointer.java │ │ │ └── priority │ │ │ └── Priority.java │ │ └── jex │ │ ├── JexClient.java │ │ ├── event │ │ ├── chat │ │ │ ├── EventSendMessage.java │ │ │ ├── EventShouldPreviewChat.java │ │ │ └── EventSortSuggestions.java │ │ ├── filters │ │ │ ├── ApplyFogFilter.java │ │ │ ├── ClickBlockFilter.java │ │ │ ├── ClientPacketFilter.java │ │ │ ├── DirectClientPacketFilter.java │ │ │ ├── DrawScreenFilter.java │ │ │ ├── InteractBlockFilter.java │ │ │ ├── ItemStackDecrementFilter.java │ │ │ ├── ItemStackSetCountFilter.java │ │ │ ├── KeyPressFilter.java │ │ │ ├── MousePressFilter.java │ │ │ ├── PlayerPacketsFilter.java │ │ │ ├── ServerPacketFilter.java │ │ │ ├── SetScreenFilter.java │ │ │ ├── SoundFilter.java │ │ │ ├── TickFilter.java │ │ │ ├── TickParticleFilter.java │ │ │ ├── ToolTipFilter.java │ │ │ └── ToolTipItemFilter.java │ │ ├── misc │ │ │ ├── EventControlLlama.java │ │ │ ├── EventEntityHitbox.java │ │ │ ├── EventGameFinishedLoading.java │ │ │ ├── EventGetFramerateLimit.java │ │ │ ├── EventGetToolTipFromItem.java │ │ │ ├── EventHorseIsSaddled.java │ │ │ ├── EventItemStackDecrement.java │ │ │ ├── EventItemStackSetCount.java │ │ │ ├── EventKeyPressed.java │ │ │ ├── EventMouseButton.java │ │ │ ├── EventPortalCloseGUI.java │ │ │ ├── EventRenderTick.java │ │ │ ├── EventServerTurn.java │ │ │ ├── EventSetLevel.java │ │ │ ├── EventSetOptionInstance.java │ │ │ ├── EventSetScreen.java │ │ │ ├── EventStop.java │ │ │ └── EventTick.java │ │ ├── packet │ │ │ ├── EventConnect.java │ │ │ ├── EventHello.java │ │ │ ├── EventPacketReceive.java │ │ │ └── EventPacketSent.java │ │ ├── player │ │ │ ├── EventAttackEntity.java │ │ │ ├── EventCurrentItemAttackStrengthDelay.java │ │ │ ├── EventExplosionVelocity.java │ │ │ ├── EventGetPose.java │ │ │ ├── EventGetReachDistance.java │ │ │ ├── EventGetSkinTexture.java │ │ │ ├── EventHasExtendedReach.java │ │ │ ├── EventIsPlayerTouchingWater.java │ │ │ ├── EventMove.java │ │ │ ├── EventPlayerPackets.java │ │ │ ├── EventPlayerUpdates.java │ │ │ ├── EventPlayerVelocity.java │ │ │ ├── EventPushAwayFromEntity.java │ │ │ ├── EventPushOutOfBlocks.java │ │ │ ├── EventSetPlayerHealth.java │ │ │ ├── EventSetSprint.java │ │ │ ├── EventSlowdown.java │ │ │ ├── EventStep.java │ │ │ ├── EventStopUsingItem.java │ │ │ └── EventWalkOffBlock.java │ │ ├── render │ │ │ ├── EventBindShader.java │ │ │ ├── EventBlockBrightness.java │ │ │ ├── EventBlockOutlineColor.java │ │ │ ├── EventBobView.java │ │ │ ├── EventClipCamera.java │ │ │ ├── EventDrawScreen.java │ │ │ ├── EventGetGlintShaders.java │ │ │ ├── EventGetRenderType.java │ │ │ ├── EventHurtCam.java │ │ │ ├── EventInitPlayerModel.java │ │ │ ├── EventIsBlockOpaque.java │ │ │ ├── EventLivingEntityCallRender.java │ │ │ ├── EventMarkChunkClosed.java │ │ │ ├── EventNametagShouldRender.java │ │ │ ├── EventPlayerEntityGetBodyParts.java │ │ │ ├── EventPlayerEntityTexturedModelData.java │ │ │ ├── EventRender2D.java │ │ │ ├── EventRender2DItem.java │ │ │ ├── EventRender2DNoScale.java │ │ │ ├── EventRender3D.java │ │ │ ├── EventRenderBackground.java │ │ │ ├── EventRenderBlock.java │ │ │ ├── EventRenderBlockEntity.java │ │ │ ├── EventRenderBodyPart.java │ │ │ ├── EventRenderChatHud.java │ │ │ ├── EventRenderChest.java │ │ │ ├── EventRenderCrosshair.java │ │ │ ├── EventRenderEffects.java │ │ │ ├── EventRenderFeature.java │ │ │ ├── EventRenderFluid.java │ │ │ ├── EventRenderHand.java │ │ │ ├── EventRenderHeldItem.java │ │ │ ├── EventRenderItem.java │ │ │ ├── EventRenderNametags.java │ │ │ ├── EventRenderOverlay.java │ │ │ ├── EventRenderRain.java │ │ │ ├── EventRenderShadowAndFire.java │ │ │ ├── EventRenderToolTip.java │ │ │ ├── EventRenderWidget.java │ │ │ ├── EventRenderWithShader.java │ │ │ ├── EventRotateItemEntity.java │ │ │ ├── EventSetupFog.java │ │ │ ├── EventShouldDrawSide.java │ │ │ ├── EventShouldFlipUpsideDown.java │ │ │ ├── EventSodiumBeginShader.java │ │ │ ├── EventSodiumQuadAlpha.java │ │ │ ├── EventVisualCooldown.java │ │ │ ├── EventWorldRender.java │ │ │ └── EventWorldRenderEntity.java │ │ └── world │ │ │ ├── EventBlockCollisionShape.java │ │ │ ├── EventBreakBlock.java │ │ │ ├── EventClickBlock.java │ │ │ ├── EventInteractBlock.java │ │ │ ├── EventLoadChunk.java │ │ │ ├── EventPlaySound.java │ │ │ ├── EventPlayerInteractionTick.java │ │ │ ├── EventSpawnEntity.java │ │ │ ├── EventTickParticle.java │ │ │ ├── EventWaterVelocity.java │ │ │ └── EventWeatherGradient.java │ │ ├── feature │ │ ├── command │ │ │ ├── CommandManager.java │ │ │ ├── core │ │ │ │ ├── Command.java │ │ │ │ ├── annotate │ │ │ │ │ └── Cmd.java │ │ │ │ └── arguments │ │ │ │ │ ├── BlockStateArgumentType.java │ │ │ │ │ ├── ColorArgumentType.java │ │ │ │ │ ├── CommandArgumentType.java │ │ │ │ │ ├── EnchantmentArgumentType.java │ │ │ │ │ ├── FakePlayerArgumentType.java │ │ │ │ │ ├── FeatureArgumentType.java │ │ │ │ │ ├── FriendArgumentType.java │ │ │ │ │ ├── IdentifierArgumentType.java │ │ │ │ │ ├── MessageArgumentType.java │ │ │ │ │ ├── ParticleTypeArgumentType.java │ │ │ │ │ ├── PlayerNameArgumentType.java │ │ │ │ │ ├── Vec3ArgumentType.java │ │ │ │ │ └── impl │ │ │ │ │ ├── DefaultPosArgument.java │ │ │ │ │ ├── LookingPosArgument.java │ │ │ │ │ └── PosArgument.java │ │ │ └── impl │ │ │ │ ├── CommandAutoDrop.java │ │ │ │ ├── CommandBaritone.java │ │ │ │ ├── CommandBind.java │ │ │ │ ├── CommandBot.java │ │ │ │ ├── CommandBotCmd.java │ │ │ │ ├── CommandBreed.java │ │ │ │ ├── CommandCGive.java │ │ │ │ ├── CommandCopyNBT.java │ │ │ │ ├── CommandDamage.java │ │ │ │ ├── CommandDupe.java │ │ │ │ ├── CommandEnchant.java │ │ │ │ ├── CommandExcavatorPos.java │ │ │ │ ├── CommandFakePlayer.java │ │ │ │ ├── CommandFriend.java │ │ │ │ ├── CommandHat.java │ │ │ │ ├── CommandHead.java │ │ │ │ ├── CommandHelp.java │ │ │ │ ├── CommandItemExploit.java │ │ │ │ ├── CommandLibrarianRoll.java │ │ │ │ ├── CommandNameHistory.java │ │ │ │ ├── CommandPanic.java │ │ │ │ ├── CommandPeek.java │ │ │ │ ├── CommandPing.java │ │ │ │ ├── CommandPlugins.java │ │ │ │ ├── CommandScreenshot.java │ │ │ │ ├── CommandSearch.java │ │ │ │ ├── CommandServerScrubber.java │ │ │ │ ├── CommandSkinSteal.java │ │ │ │ ├── CommandSlimeChunks.java │ │ │ │ ├── CommandSpeedCraft.java │ │ │ │ ├── CommandToggle.java │ │ │ │ ├── CommandTrail.java │ │ │ │ ├── CommandVClip.java │ │ │ │ ├── CommandWaypoint.java │ │ │ │ └── CommandXray.java │ │ ├── keybind │ │ │ └── Keybind.java │ │ ├── mod │ │ │ ├── core │ │ │ │ ├── Category.java │ │ │ │ ├── Feature.java │ │ │ │ ├── FeatureExtension.java │ │ │ │ └── FeatureManager.java │ │ │ └── impl │ │ │ │ ├── combat │ │ │ │ ├── AnchorAura.java │ │ │ │ ├── AntiFireball.java │ │ │ │ ├── AntiKnockback.java │ │ │ │ ├── AutoArmor.java │ │ │ │ ├── AutoCope.java │ │ │ │ ├── AutoEZ.java │ │ │ │ ├── AutoGapple.java │ │ │ │ ├── AutoPot.java │ │ │ │ ├── AutoSoup.java │ │ │ │ ├── AutoTotem.java │ │ │ │ ├── AutoTrap.java │ │ │ │ ├── AutoWeapon.java │ │ │ │ ├── BowBomb.java │ │ │ │ ├── Criticals.java │ │ │ │ ├── CrystalAura.java │ │ │ │ ├── Hitboxes.java │ │ │ │ ├── NoFriendDMG.java │ │ │ │ ├── Roaster.java │ │ │ │ ├── Surround.java │ │ │ │ ├── TPSSync.java │ │ │ │ ├── Triggerbot.java │ │ │ │ ├── WebSpam.java │ │ │ │ └── killaura │ │ │ │ │ ├── KillAura.java │ │ │ │ │ └── impl │ │ │ │ │ ├── MultiAura.java │ │ │ │ │ └── SingleAura.java │ │ │ │ ├── misc │ │ │ │ ├── Announcer.java │ │ │ │ ├── AntiAFK.java │ │ │ │ ├── ArmorDerp.java │ │ │ │ ├── AutoDisconnect.java │ │ │ │ ├── AutoDogFeeder.java │ │ │ │ ├── AutoLibrarianRoll.java │ │ │ │ ├── AutoMend.java │ │ │ │ ├── AutoReconnect.java │ │ │ │ ├── AutoRespawn.java │ │ │ │ ├── AutoWither.java │ │ │ │ ├── CoordFinder.java │ │ │ │ ├── CreativeDrop.java │ │ │ │ ├── Derp.java │ │ │ │ ├── Fakelag.java │ │ │ │ ├── IRC.java │ │ │ │ ├── InventoryAutoClicker.java │ │ │ │ ├── InventoryPlus.java │ │ │ │ ├── InventorySort.java │ │ │ │ ├── MassTPA.java │ │ │ │ ├── MendingSaver.java │ │ │ │ ├── Messages.java │ │ │ │ ├── MiddleClickFriend.java │ │ │ │ ├── PingSpoof.java │ │ │ │ ├── SkinBlink.java │ │ │ │ ├── Spammer.java │ │ │ │ ├── SpeedCrafter.java │ │ │ │ ├── UnfocusedFPS.java │ │ │ │ └── VanillaSpoof.java │ │ │ │ ├── movement │ │ │ │ ├── AntiVoid.java │ │ │ │ ├── BucketCatch.java │ │ │ │ ├── CompatSwim.java │ │ │ │ ├── DepthStrider.java │ │ │ │ ├── FallSpeed.java │ │ │ │ ├── FastLadder.java │ │ │ │ ├── InventoryMove.java │ │ │ │ ├── NoSlow.java │ │ │ │ ├── Parkour.java │ │ │ │ ├── Safewalk.java │ │ │ │ ├── Scaffold.java │ │ │ │ ├── Spider.java │ │ │ │ ├── Sprint.java │ │ │ │ ├── Step.java │ │ │ │ ├── YawLock.java │ │ │ │ ├── elytraplus │ │ │ │ │ ├── ElytraPlus.java │ │ │ │ │ └── impl │ │ │ │ │ │ ├── AlwaysBoostElytraFly.java │ │ │ │ │ │ ├── BoostElytraFly.java │ │ │ │ │ │ ├── ECMEElytraFly.java │ │ │ │ │ │ └── HoverElytraFly.java │ │ │ │ ├── fly │ │ │ │ │ ├── Fly.java │ │ │ │ │ └── impl │ │ │ │ │ │ ├── CreativeFly.java │ │ │ │ │ │ ├── NormalFly.java │ │ │ │ │ │ ├── ThreeDFly.java │ │ │ │ │ │ └── TightFly.java │ │ │ │ └── speed │ │ │ │ │ ├── Speed.java │ │ │ │ │ └── impl │ │ │ │ │ ├── StrafeSpeed.java │ │ │ │ │ └── VanillaSpeed.java │ │ │ │ ├── player │ │ │ │ ├── AntiEffect.java │ │ │ │ ├── AntiHunger.java │ │ │ │ ├── AutoDrop.java │ │ │ │ ├── AutoEat.java │ │ │ │ ├── AutoFish.java │ │ │ │ ├── AutoTool.java │ │ │ │ ├── AutoWalk.java │ │ │ │ ├── Blink.java │ │ │ │ ├── ElytraSwap.java │ │ │ │ ├── Enderman.java │ │ │ │ ├── FastPlace.java │ │ │ │ ├── Freecam.java │ │ │ │ ├── Ghost.java │ │ │ │ ├── HotbarRefill.java │ │ │ │ ├── Jesus.java │ │ │ │ ├── NoFall.java │ │ │ │ ├── NoPush.java │ │ │ │ ├── NoTurn.java │ │ │ │ ├── PortalGui.java │ │ │ │ ├── Reach.java │ │ │ │ ├── Sneak.java │ │ │ │ ├── SpeedMine.java │ │ │ │ └── ThrowPearl.java │ │ │ │ ├── render │ │ │ │ ├── AntiOverlay.java │ │ │ │ ├── BarrierView.java │ │ │ │ ├── BlockOverlay.java │ │ │ │ ├── CameraClip.java │ │ │ │ ├── Crosshair.java │ │ │ │ ├── CustomBG.java │ │ │ │ ├── CustomFont.java │ │ │ │ ├── CustomMainMenu.java │ │ │ │ ├── CustomWidgets.java │ │ │ │ ├── EnchantColor.java │ │ │ │ ├── Gui.java │ │ │ │ ├── HoleESP.java │ │ │ │ ├── HolidayEvents.java │ │ │ │ ├── InventoryView.java │ │ │ │ ├── ItemPhysics.java │ │ │ │ ├── ItemScale.java │ │ │ │ ├── ItemSearcher.java │ │ │ │ ├── Nametag.java │ │ │ │ ├── NoFog.java │ │ │ │ ├── NoHurtCam.java │ │ │ │ ├── NoRender.java │ │ │ │ ├── NoVisualCooldown.java │ │ │ │ ├── OldBlocking.java │ │ │ │ ├── OwnerTags.java │ │ │ │ ├── Search.java │ │ │ │ ├── SignReader.java │ │ │ │ ├── Skeletons.java │ │ │ │ ├── SpawnHighlighter.java │ │ │ │ ├── SuperheroFX.java │ │ │ │ ├── TargetHud.java │ │ │ │ ├── ToolTips.java │ │ │ │ ├── Tracers.java │ │ │ │ ├── Trail.java │ │ │ │ ├── Trajectories.java │ │ │ │ ├── TunnelFinder.java │ │ │ │ ├── Zoom.java │ │ │ │ ├── esp │ │ │ │ │ ├── ESP.java │ │ │ │ │ └── impl │ │ │ │ │ │ ├── BoxESP.java │ │ │ │ │ │ ├── OutlineBox.java │ │ │ │ │ │ ├── ShaderESP.java │ │ │ │ │ │ └── TwoDeeESP.java │ │ │ │ ├── hud │ │ │ │ │ ├── Hud.java │ │ │ │ │ └── elements │ │ │ │ │ │ ├── ArmorElement.java │ │ │ │ │ │ ├── ArrayListElement.java │ │ │ │ │ │ ├── BiomeElement.java │ │ │ │ │ │ ├── CoordinatesElement.java │ │ │ │ │ │ ├── DirectionElement.java │ │ │ │ │ │ ├── FPSElement.java │ │ │ │ │ │ ├── HudElement.java │ │ │ │ │ │ ├── LookElement.java │ │ │ │ │ │ ├── PingElement.java │ │ │ │ │ │ ├── PlayerCountElement.java │ │ │ │ │ │ ├── PlayerFaceElement.java │ │ │ │ │ │ ├── PotionEffectsElement.java │ │ │ │ │ │ ├── RadarElement.java │ │ │ │ │ │ ├── SaturationElement.java │ │ │ │ │ │ ├── ServerElement.java │ │ │ │ │ │ ├── SpeedElement.java │ │ │ │ │ │ ├── TPSElement.java │ │ │ │ │ │ ├── TabGuiElement.java │ │ │ │ │ │ ├── TargetHudElement.java │ │ │ │ │ │ ├── UsernameElement.java │ │ │ │ │ │ └── WatermarkElement.java │ │ │ │ └── storageesp │ │ │ │ │ ├── StorageESP.java │ │ │ │ │ └── impl │ │ │ │ │ ├── BoxStorageESP.java │ │ │ │ │ └── OutlineStorageESP.java │ │ │ │ └── world │ │ │ │ ├── AccuratePlace.java │ │ │ │ ├── AirPlace.java │ │ │ │ ├── AntiGhostBlock.java │ │ │ │ ├── AntiHazard.java │ │ │ │ ├── AntiLiquid.java │ │ │ │ ├── AutoBreak.java │ │ │ │ ├── AutoFarm.java │ │ │ │ ├── AutoMine.java │ │ │ │ ├── AutoSign.java │ │ │ │ ├── BedrockBreaker.java │ │ │ │ ├── BedrockObf.java │ │ │ │ ├── BonemealAura.java │ │ │ │ ├── ChestStealer.java │ │ │ │ ├── ColoredSigns.java │ │ │ │ ├── EndPortalFinder.java │ │ │ │ ├── EntityRider.java │ │ │ │ ├── Excavator.java │ │ │ │ ├── FarmAura.java │ │ │ │ ├── Fullbright.java │ │ │ │ ├── LawnBot.java │ │ │ │ ├── LogOutSpot.java │ │ │ │ ├── NewChunks.java │ │ │ │ ├── NoWeather.java │ │ │ │ ├── Nuker.java │ │ │ │ ├── Radar.java │ │ │ │ ├── SlimeSpawnMarker.java │ │ │ │ ├── SpawnProofing.java │ │ │ │ ├── SpawnSphere.java │ │ │ │ ├── Timer.java │ │ │ │ ├── Tunneller.java │ │ │ │ ├── Waypoints.java │ │ │ │ ├── WorldTime.java │ │ │ │ ├── XPBottleSpammer.java │ │ │ │ └── xray │ │ │ │ ├── Xray.java │ │ │ │ └── impl │ │ │ │ ├── NormalXray.java │ │ │ │ └── OpacityXray.java │ │ ├── plugin │ │ │ ├── JexPlugin.java │ │ │ └── JexPluginManager.java │ │ └── property │ │ │ ├── Property.java │ │ │ └── PropertyManager.java │ │ ├── file │ │ ├── core │ │ │ ├── ConfigFile.java │ │ │ └── ConfigManager.java │ │ └── impl │ │ │ ├── AltFile.java │ │ │ ├── AutoDropFile.java │ │ │ ├── ClientSettingsFile.java │ │ │ ├── FeatureFile.java │ │ │ ├── FriendFile.java │ │ │ ├── HudElementsFile.java │ │ │ ├── KeybindFile.java │ │ │ ├── SearchFile.java │ │ │ ├── ServerListFile.java │ │ │ ├── TrailsFile.java │ │ │ ├── WaypointFile.java │ │ │ └── XrayFile.java │ │ ├── gui │ │ ├── account │ │ │ ├── AccountManagerScreen.java │ │ │ ├── AddAccountScreen.java │ │ │ ├── DirectLoginScreen.java │ │ │ ├── ImportFromTXTScreen.java │ │ │ ├── account │ │ │ │ └── MinecraftAccount.java │ │ │ └── impl │ │ │ │ ├── AccountButton.java │ │ │ │ └── GuiPasswordField.java │ │ ├── changelog │ │ │ ├── ChangelogScreen.java │ │ │ └── changelog │ │ │ │ ├── ChangelogLine.java │ │ │ │ └── JexChangelog.java │ │ ├── jex │ │ │ ├── JexOptionsScreen.java │ │ │ ├── JexPersonalizationScreen.java │ │ │ └── selection │ │ │ │ ├── AutoDropSelectScreen.java │ │ │ │ ├── SearchSelectScreen.java │ │ │ │ ├── XraySelectScreen.java │ │ │ │ └── button │ │ │ │ ├── BlockButton.java │ │ │ │ └── ItemButton.java │ │ ├── jexgui │ │ │ ├── JexFeatureListScreen.java │ │ │ ├── JexGuiScreen.java │ │ │ ├── JexPropertyListScreen.java │ │ │ └── impl │ │ │ │ ├── JexCategoryButton.java │ │ │ │ ├── JexFeatureButton.java │ │ │ │ ├── JexKeybindButton.java │ │ │ │ ├── JexPropertyButton.java │ │ │ │ └── properties │ │ │ │ ├── JexBooleanPropertyButton.java │ │ │ │ ├── JexColorPropertyButton.java │ │ │ │ ├── JexDoublePropertyButton.java │ │ │ │ ├── JexEnumPropertyButton.java │ │ │ │ ├── JexFloatPropertyButton.java │ │ │ │ ├── JexIntegerPropertyButton.java │ │ │ │ ├── JexKeybindPropertyButton.java │ │ │ │ ├── JexLongPropertyButton.java │ │ │ │ └── JexStringPropertyButton.java │ │ ├── keybind │ │ │ ├── JexEditKeybindScreen.java │ │ │ ├── JexKeybindListScreen.java │ │ │ └── impl │ │ │ │ └── JexKeybindButton.java │ │ ├── mcleaks │ │ │ └── MCLeaksScreen.java │ │ ├── minecraft │ │ │ └── JexTitleScreen.java │ │ ├── plugin │ │ │ ├── JexPluginScreen.java │ │ │ └── button │ │ │ │ └── JexPluginButton.java │ │ ├── proxy │ │ │ └── ProxyScreen.java │ │ ├── site │ │ │ ├── JexLoginRegisterScreen.java │ │ │ └── JexWebsiteScreen.java │ │ ├── tab │ │ │ └── TabGui.java │ │ ├── thealtening │ │ │ ├── TheAlteningScreen.java │ │ │ └── impl │ │ │ │ └── TheAlteningAccountButton.java │ │ └── waypoints │ │ │ ├── WaypointEditScreen.java │ │ │ ├── WaypointScreen.java │ │ │ └── impl │ │ │ ├── ServerButton.java │ │ │ └── WaypointButton.java │ │ ├── helper │ │ ├── addon │ │ │ ├── AddonHelper.java │ │ │ ├── cape │ │ │ │ ├── CapeHelper.java │ │ │ │ ├── JexCapeFeatureRenderer.java │ │ │ │ └── JexElytraFeatureRenderer.java │ │ │ ├── ears │ │ │ │ ├── EarsHelper.java │ │ │ │ └── JexEarsFeatureRenderer.java │ │ │ ├── hat │ │ │ │ ├── HatHelper.java │ │ │ │ └── JexHatFeatureRenderer.java │ │ │ ├── pegleg │ │ │ │ ├── JexPeglegFeatureRenderer.java │ │ │ │ └── PeglegHelper.java │ │ │ └── penis │ │ │ │ ├── JexPenisFeatureRenderer.java │ │ │ │ └── PenisHelper.java │ │ ├── baritone │ │ │ ├── BaritoneHelper.java │ │ │ ├── UnsafeBaritoneHelper.java │ │ │ └── process │ │ │ │ ├── KillauraTargetProcess.java │ │ │ │ └── PauseProcess.java │ │ ├── entity │ │ │ ├── EntityHelper.java │ │ │ └── FakePlayerEntity.java │ │ ├── file │ │ │ ├── FileHelper.java │ │ │ ├── JsonHelper.java │ │ │ ├── ModFileHelper.java │ │ │ └── YamlHelper.java │ │ ├── math │ │ │ ├── ClientMathHelper.java │ │ │ ├── ColorHelper.java │ │ │ ├── EncryptHelper.java │ │ │ ├── Matrix4x4.java │ │ │ ├── TPSHelper.java │ │ │ └── vector │ │ │ │ ├── RotationVector.java │ │ │ │ ├── Vector2D.java │ │ │ │ ├── Vector3D.java │ │ │ │ ├── Vector3I.java │ │ │ │ └── Vector4D.java │ │ ├── misc │ │ │ ├── ChatHelper.java │ │ │ ├── ClassHelper.java │ │ │ ├── HWID.java │ │ │ ├── KeyboardHelper.java │ │ │ ├── Lagometer.java │ │ │ ├── MouseHelper.java │ │ │ ├── PrettyPrintTextFormatter.java │ │ │ ├── StopWatch.java │ │ │ └── Wrapper.java │ │ ├── network │ │ │ ├── ConnectedServerHelper.java │ │ │ ├── MCAPIHelper.java │ │ │ ├── MinecraftServerAddress.java │ │ │ ├── NetworkHelper.java │ │ │ ├── ProxyHelper.java │ │ │ ├── ServerPinger.java │ │ │ ├── ServerScrubber.java │ │ │ ├── WebHelper.java │ │ │ ├── jexsite │ │ │ │ ├── JexSiteHelper.java │ │ │ │ └── JexSitePacketListener.java │ │ │ └── login │ │ │ │ ├── mcleaks │ │ │ │ └── MCLeaksHelper.java │ │ │ │ ├── minecraft │ │ │ │ ├── MSLoginHelper.java │ │ │ │ ├── MinecraftAccountManager.java │ │ │ │ └── MojangLoginHelper.java │ │ │ │ └── thealtening │ │ │ │ ├── TheAlteningHelper.java │ │ │ │ └── TheAlteningSessionService.java │ │ ├── player │ │ │ ├── FriendHelper.java │ │ │ ├── InventoryHelper.java │ │ │ ├── PlayerHelper.java │ │ │ └── bot │ │ │ │ ├── BotClientConnection.java │ │ │ │ ├── BotClientPlayNetworkHandler.java │ │ │ │ ├── BotLoginNetworkHandler.java │ │ │ │ ├── PlayerBot.java │ │ │ │ └── UncaughtExceptionLogger.java │ │ ├── render │ │ │ ├── BufferHelper.java │ │ │ ├── Button.java │ │ │ ├── ButtonListener.java │ │ │ ├── EntityPositionHelper.java │ │ │ ├── FileBrowser.java │ │ │ ├── GifDecoder.java │ │ │ ├── Render2DHelper.java │ │ │ ├── Render3DHelper.java │ │ │ ├── Scissor.java │ │ │ ├── Scrollbar.java │ │ │ ├── Stencil.java │ │ │ ├── font │ │ │ │ ├── FontHelper.java │ │ │ │ └── NahrFont.java │ │ │ └── shader │ │ │ │ ├── ShaderHelper.java │ │ │ │ ├── ShaderProgram.java │ │ │ │ ├── ShaderUniform.java │ │ │ │ ├── impl │ │ │ │ ├── BlurShader.java │ │ │ │ ├── EnchantColorShader.java │ │ │ │ ├── OpacityXrayShader.java │ │ │ │ ├── OutlineShader.java │ │ │ │ └── PosColorShader.java │ │ │ │ └── post │ │ │ │ ├── PostProcessEffect.java │ │ │ │ └── impl │ │ │ │ ├── PostProcessBlur.java │ │ │ │ └── PostProcessOutline.java │ │ ├── update │ │ │ ├── JexVersion.java │ │ │ ├── Update.java │ │ │ └── UpdateManager.java │ │ └── world │ │ │ ├── PathingHelper.java │ │ │ ├── SeedHelper.java │ │ │ ├── WorldHelper.java │ │ │ ├── testpathfinder │ │ │ └── TestPathFinder.java │ │ │ └── wurstpathfinder │ │ │ ├── FlyPathProcessor.java │ │ │ ├── PathFinder.java │ │ │ ├── PathPos.java │ │ │ ├── PathProcessor.java │ │ │ ├── PathQueue.java │ │ │ └── WalkPathProcessor.java │ │ └── load │ │ ├── JexLoad.java │ │ ├── JexMixinConfigPlugin.java │ │ ├── PreLaunch.java │ │ ├── impl │ │ ├── IAbstractHorseEntity.java │ │ ├── IChatHud.java │ │ ├── IChatInputSuggestor.java │ │ ├── IChatScreen.java │ │ ├── IClientPlayNetworkHandler.java │ │ ├── IClientPlayerEntity.java │ │ ├── IClientPlayerInteractionManager.java │ │ ├── IFrameBuffer.java │ │ ├── IHandledScreen.java │ │ ├── IItemRenderer.java │ │ ├── IKeyBinding.java │ │ ├── IMinecraft.java │ │ ├── IPersistentProjectileEntity.java │ │ ├── IProjectile.java │ │ ├── IShader.java │ │ ├── ISliderWidget.java │ │ └── IWorldRenderer.java │ │ └── mixin │ │ ├── indigo │ │ ├── MixinClientLoginNetworkAddon.java │ │ └── MixinTerrainRenderContext.java │ │ ├── minecraft │ │ ├── MixinAbstractBlock.java │ │ ├── MixinAbstractBlockState.java │ │ ├── MixinAbstractClientPlayerEntity.java │ │ ├── MixinAbstractHorseEntity.java │ │ ├── MixinBackgroundRenderer.java │ │ ├── MixinBlock.java │ │ ├── MixinBlockEntityRenderDispatcher.java │ │ ├── MixinBufferRenderer.java │ │ ├── MixinCactusBlock.java │ │ ├── MixinCamera.java │ │ ├── MixinChatHud.java │ │ ├── MixinChatInputSuggestor.java │ │ ├── MixinChatScreen.java │ │ ├── MixinChestBlockEntityRenderer.java │ │ ├── MixinChunkOcclusionDataBuilder.java │ │ ├── MixinClickableWidget.java │ │ ├── MixinClientConnection.java │ │ ├── MixinClientLoginNetworkHandler.java │ │ ├── MixinClientPlayNetworkHandler.java │ │ ├── MixinClientPlayerEntity.java │ │ ├── MixinClientPlayerInteractionManager.java │ │ ├── MixinClientWorld.java │ │ ├── MixinConnectScreen.java │ │ ├── MixinEntity.java │ │ ├── MixinEntityRenderer.java │ │ ├── MixinFluidBlock.java │ │ ├── MixinFluidRenderer.java │ │ ├── MixinFluidState.java │ │ ├── MixinFramebuffer.java │ │ ├── MixinGameRenderer.java │ │ ├── MixinHandledScreen.java │ │ ├── MixinHeldItemRenderer.java │ │ ├── MixinInGameHud.java │ │ ├── MixinInGameOverlayRenderer.java │ │ ├── MixinItemEntityRenderer.java │ │ ├── MixinItemRenderer.java │ │ ├── MixinItemStack.java │ │ ├── MixinKeybinding.java │ │ ├── MixinKeyboard.java │ │ ├── MixinLivingEntity.java │ │ ├── MixinLivingEntityRenderer.java │ │ ├── MixinLlamaEntity.java │ │ ├── MixinMain.java │ │ ├── MixinMinecraft.java │ │ ├── MixinMouse.java │ │ ├── MixinMultiplayerScreen.java │ │ ├── MixinOptionsScreen.java │ │ ├── MixinParticleManager.java │ │ ├── MixinPersistentProjectileEntity.java │ │ ├── MixinPlayerEntity.java │ │ ├── MixinPlayerEntityModel.java │ │ ├── MixinPlayerEntityRenderer.java │ │ ├── MixinPowderSnowBlock.java │ │ ├── MixinProjectileEntity.java │ │ ├── MixinRenderLayers.java │ │ ├── MixinRenderTickCounter.java │ │ ├── MixinScreen.java │ │ ├── MixinServerInfo.java │ │ ├── MixinServerList.java │ │ ├── MixinShader.java │ │ ├── MixinSignEditScreen.java │ │ ├── MixinSimpleOption.java │ │ ├── MixinSliderWidget.java │ │ ├── MixinSoundSystem.java │ │ ├── MixinSplashOverlay.java │ │ ├── MixinWorld.java │ │ ├── MixinWorldChunk.java │ │ └── MixinWorldRenderer.java │ │ └── sodium │ │ ├── MixinBlockOcclusionCache.java │ │ ├── MixinBlockRenderer.java │ │ ├── MixinFluidRenderer.java │ │ ├── MixinGlProgram.java │ │ ├── MixinShaderChunkRenderer.java │ │ └── MixinShaderLoader.java └── net │ └── jodah │ └── typetools │ └── TypeResolver.java └── resources ├── assets ├── jex │ ├── comic │ │ ├── boom.png │ │ ├── kapow.png │ │ ├── pow.png │ │ └── wham.png │ ├── gui │ │ ├── click │ │ │ ├── cog.png │ │ │ ├── colorslider.png │ │ │ ├── pin.png │ │ │ └── visible.png │ │ ├── jex │ │ │ ├── folder.png │ │ │ ├── hats.png │ │ │ └── jex-logo.png │ │ └── mc │ │ │ └── shulker_background.png │ ├── hats │ │ ├── halo.png │ │ ├── mohawk.png │ │ ├── santa.png │ │ ├── techno.png │ │ └── top_hat.png │ ├── icon.png │ ├── lang │ │ └── en_us.json │ ├── legs │ │ ├── lightning_rod.png │ │ ├── robot.png │ │ └── stick.png │ ├── shaders │ │ ├── blur.fsh │ │ ├── blur.vsh │ │ ├── opacity_xray.fsh │ │ ├── opacity_xray.vsh │ │ ├── outline.fsh │ │ ├── outline.vsh │ │ ├── pos_color.fsh │ │ ├── pos_color.vsh │ │ ├── rainbow_enchant.fsh │ │ └── rainbow_enchant.vsh │ └── skin │ │ └── speedo.png └── sodium │ └── shaders │ ├── opacity_xray.fsh │ └── opacity_xray.vsh ├── fabric.mod.json └── jex.mixins.json /.github/workflows/build.yml: -------------------------------------------------------------------------------- 1 | name: Build 2 | 3 | on: [push] 4 | 5 | jobs: 6 | build: 7 | 8 | runs-on: ubuntu-latest 9 | 10 | steps: 11 | - name: Clone repo 12 | uses: actions/checkout@v2 13 | - name: Set up JDK 17 14 | uses: actions/setup-java@v2 15 | with: 16 | distribution: 'zulu' 17 | java-version: '17' 18 | - name: Grant execute permission for gradlew 19 | run: chmod +x gradlew 20 | - name: Build with Gradle 21 | run: ./gradlew build 22 | - name: Upload Artifact 23 | uses: actions/upload-artifact@v2 24 | with: 25 | name: JexClient 26 | path: build/libs/ 27 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | # gradle 2 | 3 | .gradle/ 4 | build/ 5 | out/ 6 | classes/ 7 | 8 | # eclipse 9 | 10 | *.launch 11 | 12 | # idea 13 | 14 | .idea/ 15 | *.iml 16 | *.ipr 17 | *.iws 18 | 19 | # vscode 20 | 21 | .settings/ 22 | .vscode/ 23 | bin/ 24 | .classpath 25 | .project 26 | 27 | # macos 28 | 29 | *.DS_Store 30 | 31 | # fabric 32 | 33 | run/ 34 | -------------------------------------------------------------------------------- /gradle.properties: -------------------------------------------------------------------------------- 1 | # Done to increase the memory available to gradle. 2 | org.gradle.jvmargs=-Xmx1G 3 | 4 | minecraft_version=1.19.2 5 | yarn_mappings=1.19.2+build.8 6 | loader_version=0.14.9 7 | 8 | #Fabric api 9 | fabric_version=0.60.0+1.19.2 10 | 11 | # Mod Properties 12 | mod_version=0.8.6 13 | maven_group=me.dustin 14 | archives_base_name=jex-client -------------------------------------------------------------------------------- /gradle/wrapper/gradle-wrapper.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DustinRepo/JexClient/017ce1229fc446f66eee5c564ce28af142368f3d/gradle/wrapper/gradle-wrapper.jar -------------------------------------------------------------------------------- /gradle/wrapper/gradle-wrapper.properties: -------------------------------------------------------------------------------- 1 | distributionBase=GRADLE_USER_HOME 2 | distributionPath=wrapper/dists 3 | distributionUrl=https\://services.gradle.org/distributions/gradle-7.4-bin.zip 4 | zipStoreBase=GRADLE_USER_HOME 5 | zipStorePath=wrapper/dists 6 | -------------------------------------------------------------------------------- /gradlew: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DustinRepo/JexClient/017ce1229fc446f66eee5c564ce28af142368f3d/gradlew -------------------------------------------------------------------------------- /lib/IRCClient.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DustinRepo/JexClient/017ce1229fc446f66eee5c564ce28af142368f3d/lib/IRCClient.jar -------------------------------------------------------------------------------- /lib/baritone-1.6.3-dev.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DustinRepo/JexClient/017ce1229fc446f66eee5c564ce28af142368f3d/lib/baritone-1.6.3-dev.jar -------------------------------------------------------------------------------- /lib/sodium.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DustinRepo/JexClient/017ce1229fc446f66eee5c564ce28af142368f3d/lib/sodium.jar -------------------------------------------------------------------------------- /settings.gradle: -------------------------------------------------------------------------------- 1 | pluginManagement { 2 | repositories { 3 | maven { 4 | name = 'Fabric' 5 | url = 'https://maven.fabricmc.net/' 6 | } 7 | mavenCentral() 8 | gradlePluginPortal() 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /src/main/java/bedrockminer/utils/BlockBreaker.java: -------------------------------------------------------------------------------- 1 | package bedrockminer.utils; 2 | 3 | import net.minecraft.client.MinecraftClient; 4 | import net.minecraft.client.world.ClientWorld; 5 | import net.minecraft.item.Items; 6 | import net.minecraft.util.math.BlockPos; 7 | import net.minecraft.util.math.Direction; 8 | 9 | //import java.util.ArrayList; 10 | 11 | //import static net.minecraft.block.Block.sideCoversSmallSquare; 12 | 13 | public class BlockBreaker { 14 | public static void breakBlock(ClientWorld world, BlockPos pos) { 15 | InventoryManager.switchToItem(Items.DIAMOND_PICKAXE); 16 | MinecraftClient.getInstance().interactionManager.attackBlock(pos, Direction.UP); 17 | } 18 | 19 | 20 | } -------------------------------------------------------------------------------- /src/main/java/bedrockminer/utils/Messager.java: -------------------------------------------------------------------------------- 1 | package bedrockminer.utils; 2 | 3 | 4 | import net.minecraft.client.MinecraftClient; 5 | import net.minecraft.text.Text; 6 | 7 | public class Messager { 8 | public static void actionBar(String message){ 9 | MinecraftClient minecraftClient = MinecraftClient.getInstance(); 10 | minecraftClient.inGameHud.setOverlayMessage(Text.of(message),false); 11 | } 12 | 13 | public static void chat(String message){ 14 | MinecraftClient minecraftClient = MinecraftClient.getInstance(); 15 | minecraftClient.inGameHud.getChatHud().addMessage(Text.of(message)); 16 | } 17 | } 18 | 19 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/events/core/Event.java: -------------------------------------------------------------------------------- 1 | package me.dustin.events.core; 2 | 3 | import me.dustin.events.EventManager; 4 | 5 | import java.util.ConcurrentModificationException; 6 | 7 | public class Event { 8 | 9 | private boolean cancelled; 10 | 11 | public T run() 12 | { 13 | try { 14 | EventManager.run(this); 15 | } catch (ConcurrentModificationException ignored){} 16 | return (T) this; 17 | } 18 | 19 | public void cancel() 20 | { 21 | this.cancelled = true; 22 | } 23 | 24 | public boolean isCancelled() { 25 | return cancelled; 26 | } 27 | 28 | public void setCancelled(boolean cancelled) { 29 | this.cancelled = cancelled; 30 | } 31 | 32 | public boolean equals(Class eventClass) 33 | { 34 | return this.getClass() == eventClass; 35 | } 36 | 37 | } 38 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/events/core/EventHook.java: -------------------------------------------------------------------------------- 1 | package me.dustin.events.core; 2 | 3 | public interface EventHook { 4 | 5 | /* 6 | * This is the method that gets called to run all of the code in each field you make for your event 7 | */ 8 | void invoke(T event); 9 | 10 | } 11 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/events/core/annotate/EventPointer.java: -------------------------------------------------------------------------------- 1 | package me.dustin.events.core.annotate; 2 | 3 | import java.lang.annotation.Retention; 4 | import java.lang.annotation.RetentionPolicy; 5 | 6 | @Retention(value = RetentionPolicy.RUNTIME) 7 | public @interface EventPointer { 8 | 9 | } 10 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/events/core/priority/Priority.java: -------------------------------------------------------------------------------- 1 | package me.dustin.events.core.priority; 2 | 3 | public class Priority { 4 | 5 | public final static int FIRST = 1; 6 | public final static int SECOND = 2; 7 | public final static int DEFAULT = 3; 8 | public final static int SECOND_LAST = 4; 9 | public final static int LAST = 5; 10 | 11 | public final static int[] VALUE_ARRAY = new int[]{1, 2, 3, 4, 5}; 12 | 13 | } 14 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/chat/EventSendMessage.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.chat; 2 | 3 | import me.dustin.events.core.Event; 4 | 5 | public class EventSendMessage extends Event { 6 | 7 | private String message; 8 | 9 | public EventSendMessage(String message) { 10 | this.message = message; 11 | } 12 | 13 | public String getMessage() { 14 | return message; 15 | } 16 | 17 | public void setMessage(String message) { 18 | this.message = message; 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/chat/EventShouldPreviewChat.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.chat; 2 | 3 | import me.dustin.events.core.Event; 4 | 5 | public class EventShouldPreviewChat extends Event { 6 | 7 | private boolean enabled; 8 | 9 | public EventShouldPreviewChat(boolean enabled) { 10 | this.enabled = enabled; 11 | } 12 | 13 | public boolean isEnabled() { 14 | return enabled; 15 | } 16 | 17 | public void setEnabled(boolean enabled) { 18 | this.enabled = enabled; 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/chat/EventSortSuggestions.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.chat; 2 | 3 | import com.mojang.brigadier.suggestion.Suggestion; 4 | import com.mojang.brigadier.suggestion.Suggestions; 5 | import me.dustin.events.core.Event; 6 | 7 | import java.util.List; 8 | 9 | 10 | public class EventSortSuggestions extends Event { 11 | 12 | private final Suggestions suggestions; 13 | private final String text; 14 | private final List output; 15 | 16 | public EventSortSuggestions(Suggestions suggestions, String text, List output) { 17 | this.suggestions = suggestions; 18 | this.text = text; 19 | this.output = output; 20 | } 21 | 22 | public Suggestions getSuggestions() { 23 | return suggestions; 24 | } 25 | 26 | public String getText() { 27 | return text; 28 | } 29 | 30 | public List getOutput() { 31 | return output; 32 | } 33 | } 34 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/filters/ApplyFogFilter.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.filters; 2 | 3 | import me.dustin.jex.event.render.EventSetupFog; 4 | import net.minecraft.client.render.CameraSubmersionType; 5 | import java.util.function.Predicate; 6 | 7 | public class ApplyFogFilter implements Predicate { 8 | 9 | private CameraSubmersionType[] cameraSubmersionTypes; 10 | 11 | public ApplyFogFilter(CameraSubmersionType... cameraSubmersionTypes) { 12 | this.cameraSubmersionTypes = cameraSubmersionTypes; 13 | } 14 | 15 | @Override 16 | public boolean test(EventSetupFog eventSetupFog) { 17 | if (cameraSubmersionTypes == null || cameraSubmersionTypes.length == 0) 18 | return true; 19 | for (CameraSubmersionType cameraSubmersionType : cameraSubmersionTypes) { 20 | if (cameraSubmersionType == eventSetupFog.getCameraSubmersionType()) 21 | return true; 22 | } 23 | return false; 24 | } 25 | } 26 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/filters/ClickBlockFilter.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.filters; 2 | 3 | import me.dustin.jex.event.world.EventClickBlock; 4 | 5 | import java.util.function.Predicate; 6 | 7 | public class ClickBlockFilter implements Predicate { 8 | 9 | private final EventClickBlock.Mode mode; 10 | 11 | public ClickBlockFilter(EventClickBlock.Mode mode) { 12 | this.mode = mode; 13 | } 14 | 15 | @Override 16 | public boolean test(EventClickBlock eventClickBlock) { 17 | return eventClickBlock.getMode() == mode; 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/filters/ClientPacketFilter.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.filters; 2 | 3 | import me.dustin.jex.event.packet.EventPacketSent; 4 | import net.minecraft.network.Packet; 5 | import java.util.function.Predicate; 6 | 7 | public class ClientPacketFilter implements Predicate { 8 | 9 | private EventPacketSent.Mode mode; 10 | private final Class>[] packets; 11 | 12 | @SafeVarargs 13 | public ClientPacketFilter(EventPacketSent.Mode mode, Class>... packets) { 14 | this.mode = mode; 15 | this.packets = packets; 16 | } 17 | 18 | @Override 19 | public boolean test(EventPacketSent eventPacketReceive) { 20 | if (packets.length > 0) { 21 | for (Class> packetClass : packets) { 22 | if (packetClass == eventPacketReceive.getPacket().getClass() || packetClass == eventPacketReceive.getPacket().getClass().getSuperclass()) { 23 | if (mode != null) { 24 | return eventPacketReceive.getMode() == mode; 25 | } 26 | return true; 27 | } 28 | } 29 | return false; 30 | } 31 | if (mode != null) 32 | return eventPacketReceive.getMode() == mode; 33 | return true; 34 | } 35 | } 36 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/filters/DrawScreenFilter.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.filters; 2 | 3 | import me.dustin.jex.event.render.EventDrawScreen; 4 | import net.minecraft.client.gui.screen.Screen; 5 | import java.util.function.Predicate; 6 | 7 | public class DrawScreenFilter implements Predicate { 8 | 9 | private final EventDrawScreen.Mode mode; 10 | private final Class[] screens; 11 | 12 | @SafeVarargs 13 | public DrawScreenFilter(EventDrawScreen.Mode mode, Class... screens) { 14 | this.mode = mode; 15 | this.screens = screens; 16 | } 17 | 18 | @Override 19 | public boolean test(EventDrawScreen eventDrawScreen) { 20 | if (screens.length <= 0) 21 | if (mode != null) 22 | return mode == eventDrawScreen.getMode(); 23 | else 24 | return true; 25 | for (Class screen : screens) { 26 | if (screen == eventDrawScreen.getScreen().getClass()) { 27 | if (mode != null) 28 | return mode == eventDrawScreen.getMode(); 29 | return true; 30 | } 31 | } 32 | return false; 33 | } 34 | } 35 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/filters/InteractBlockFilter.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.filters; 2 | 3 | import me.dustin.jex.event.world.EventInteractBlock; 4 | 5 | import java.util.function.Predicate; 6 | 7 | public class InteractBlockFilter implements Predicate { 8 | 9 | private final EventInteractBlock.Mode mode; 10 | 11 | public InteractBlockFilter(EventInteractBlock.Mode mode) { 12 | this.mode = mode; 13 | } 14 | 15 | @Override 16 | public boolean test(EventInteractBlock eventInteractBlock) { 17 | return eventInteractBlock.getMode() == mode; 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/filters/ItemStackDecrementFilter.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.filters; 2 | 3 | import me.dustin.jex.event.misc.EventItemStackDecrement; 4 | import net.minecraft.item.Item; 5 | 6 | import java.util.function.Predicate; 7 | 8 | public class ItemStackDecrementFilter implements Predicate { 9 | 10 | private final EventItemStackDecrement.Mode mode; 11 | private final Item[] items; 12 | 13 | @SafeVarargs 14 | public ItemStackDecrementFilter(EventItemStackDecrement.Mode mode, Item... items) { 15 | this.mode = mode; 16 | this.items = items; 17 | } 18 | 19 | @Override 20 | public boolean test(EventItemStackDecrement eventItemStackDecrement) { 21 | if (items.length <= 0) { 22 | if (mode != null) 23 | return eventItemStackDecrement.getMode() == mode; 24 | return true; 25 | } 26 | for (Item item : items) { 27 | if (item == eventItemStackDecrement.getItemStack().getItem()) { 28 | if (mode != null) { 29 | return eventItemStackDecrement.getMode() == mode; 30 | } 31 | return true; 32 | } 33 | } 34 | return false; 35 | } 36 | } 37 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/filters/ItemStackSetCountFilter.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.filters; 2 | 3 | import me.dustin.jex.event.misc.EventItemStackSetCount; 4 | import net.minecraft.item.Item; 5 | 6 | import java.util.function.Predicate; 7 | 8 | public class ItemStackSetCountFilter implements Predicate { 9 | 10 | private final EventItemStackSetCount.Mode mode; 11 | private final Item[] items; 12 | 13 | @SafeVarargs 14 | public ItemStackSetCountFilter(EventItemStackSetCount.Mode mode, Item... items) { 15 | this.mode = mode; 16 | this.items = items; 17 | } 18 | 19 | @Override 20 | public boolean test(EventItemStackSetCount EventItemStackSetCount) { 21 | if (items.length <= 0) { 22 | if (mode != null) 23 | return EventItemStackSetCount.getMode() == mode; 24 | return true; 25 | } 26 | for (Item item : items) { 27 | if (item == EventItemStackSetCount.getItemStack().getItem()) { 28 | if (mode != null) { 29 | return EventItemStackSetCount.getMode() == mode; 30 | } 31 | return true; 32 | } 33 | } 34 | return false; 35 | } 36 | } 37 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/filters/KeyPressFilter.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.filters; 2 | 3 | import me.dustin.jex.event.misc.EventKeyPressed; 4 | 5 | import java.util.function.Predicate; 6 | 7 | public class KeyPressFilter implements Predicate { 8 | 9 | private final EventKeyPressed.PressType pressType; 10 | private final int[] keys; 11 | public KeyPressFilter(EventKeyPressed.PressType pressType, int... keys) { 12 | this.pressType = pressType; 13 | this.keys = keys; 14 | } 15 | 16 | @Override 17 | public boolean test(EventKeyPressed eventKeyPressed) { 18 | if (keys.length > 0) { 19 | for (int key : keys) { 20 | if (pressType != null) 21 | return key == eventKeyPressed.getKey() && pressType == eventKeyPressed.getType(); 22 | return key == eventKeyPressed.getKey(); 23 | } 24 | return false; 25 | } 26 | if (pressType != null) 27 | return eventKeyPressed.getType() == pressType; 28 | return true; 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/filters/MousePressFilter.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.filters; 2 | 3 | import me.dustin.jex.event.misc.EventMouseButton; 4 | 5 | import java.util.function.Predicate; 6 | 7 | public class MousePressFilter implements Predicate { 8 | 9 | private final EventMouseButton.ClickType pressType; 10 | private final int[] keys; 11 | public MousePressFilter(EventMouseButton.ClickType pressType, int... keys) { 12 | this.pressType = pressType; 13 | this.keys = keys; 14 | } 15 | 16 | @Override 17 | public boolean test(EventMouseButton eventMouseButton) { 18 | if (keys.length <= 0) { 19 | if (pressType != null) 20 | return eventMouseButton.getClickType() == pressType; 21 | return true; 22 | } 23 | for (int key : keys) { 24 | if (pressType != null) 25 | return key == eventMouseButton.getButton() && pressType == eventMouseButton.getClickType(); 26 | return key == eventMouseButton.getButton(); 27 | } 28 | return false; 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/filters/PlayerPacketsFilter.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.filters; 2 | 3 | import me.dustin.jex.event.player.EventPlayerPackets; 4 | 5 | import java.util.function.Predicate; 6 | 7 | public class PlayerPacketsFilter implements Predicate { 8 | 9 | private final EventPlayerPackets.Mode mode; 10 | 11 | public PlayerPacketsFilter(EventPlayerPackets.Mode mode) { 12 | this.mode = mode; 13 | } 14 | 15 | @Override 16 | public boolean test(EventPlayerPackets eventPlayerPackets) { 17 | return eventPlayerPackets.getMode() == mode; 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/filters/ServerPacketFilter.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.filters; 2 | 3 | import me.dustin.jex.event.packet.EventPacketReceive; 4 | import net.minecraft.network.Packet; 5 | import java.util.function.Predicate; 6 | 7 | public class ServerPacketFilter implements Predicate { 8 | 9 | private final EventPacketReceive.Mode mode; 10 | private final Class>[] packets; 11 | 12 | @SafeVarargs 13 | public ServerPacketFilter(EventPacketReceive.Mode mode, Class>... packets) { 14 | this.mode = mode; 15 | this.packets = packets; 16 | } 17 | 18 | @Override 19 | public boolean test(EventPacketReceive eventPacketReceive) { 20 | if (packets.length <= 0) { 21 | if (mode != null) 22 | return eventPacketReceive.getMode() == mode; 23 | return true; 24 | } 25 | for (Class> packetClass : packets) { 26 | if (packetClass == eventPacketReceive.getPacket().getClass() || packetClass == eventPacketReceive.getPacket().getClass().getSuperclass()) { 27 | if (mode != null) { 28 | return eventPacketReceive.getMode() == mode; 29 | } 30 | return true; 31 | } 32 | } 33 | return false; 34 | } 35 | } 36 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/filters/SetScreenFilter.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.filters; 2 | 3 | import me.dustin.jex.event.misc.EventSetScreen; 4 | import net.minecraft.client.gui.screen.Screen; 5 | import java.util.function.Predicate; 6 | 7 | public class SetScreenFilter implements Predicate { 8 | 9 | private final Class[] screens; 10 | 11 | @SafeVarargs 12 | public SetScreenFilter(Class... screens) { 13 | this.screens = screens; 14 | } 15 | 16 | @Override 17 | public boolean test(EventSetScreen eventSetScreen) { 18 | if (screens.length <= 0) 19 | return true; 20 | for (Class screen : screens) { 21 | if (eventSetScreen.getScreen() == null) 22 | return screen == null; 23 | if (screen == eventSetScreen.getScreen().getClass()) { 24 | return true; 25 | } 26 | } 27 | return false; 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/filters/SoundFilter.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.filters; 2 | 3 | import me.dustin.jex.event.world.EventPlaySound; 4 | import net.minecraft.util.Identifier; 5 | 6 | import java.util.function.Predicate; 7 | 8 | public class SoundFilter implements Predicate { 9 | 10 | private final EventPlaySound.Mode mode; 11 | private final Identifier[] ids; 12 | 13 | @SafeVarargs 14 | public SoundFilter(EventPlaySound.Mode mode, Identifier... ids) { 15 | this.mode = mode; 16 | this.ids = ids; 17 | } 18 | 19 | @Override 20 | public boolean test(EventPlaySound eventPlaySound) { 21 | if (ids.length <= 0) 22 | if (mode != null) 23 | return mode == eventPlaySound.getMode(); 24 | else 25 | return true; 26 | for (Identifier id : ids) { 27 | if (compare(id, eventPlaySound.getIdentifier())) { 28 | if (mode != null) 29 | return mode == eventPlaySound.getMode(); 30 | return true; 31 | } 32 | } 33 | return false; 34 | } 35 | 36 | private boolean compare(Identifier first, Identifier second) { 37 | return first.getNamespace().equalsIgnoreCase(second.getNamespace()) && first.getPath().equalsIgnoreCase(second.getPath()); 38 | } 39 | } 40 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/filters/TickFilter.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.filters; 2 | 3 | import me.dustin.jex.event.misc.EventTick; 4 | 5 | import java.util.function.Predicate; 6 | 7 | public class TickFilter implements Predicate { 8 | 9 | private final EventTick.Mode mode; 10 | 11 | public TickFilter(EventTick.Mode mode) { 12 | this.mode = mode; 13 | } 14 | 15 | @Override 16 | public boolean test(EventTick eventTick) { 17 | return eventTick.getMode() == this.mode; 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/filters/TickParticleFilter.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.filters; 2 | 3 | import me.dustin.jex.event.world.EventTickParticle; 4 | import net.minecraft.client.particle.Particle; 5 | 6 | import java.util.function.Predicate; 7 | 8 | public class TickParticleFilter implements Predicate { 9 | 10 | private final Class[] particles; 11 | 12 | @SafeVarargs 13 | public TickParticleFilter(Class... particles) { 14 | this.particles = particles; 15 | } 16 | 17 | @Override 18 | public boolean test(EventTickParticle eventTickParticle) { 19 | if (particles.length <= 0) 20 | return true; 21 | for (Class particle : particles) { 22 | if (eventTickParticle.getParticle() == null) 23 | return particle == null; 24 | if (particle == eventTickParticle.getParticle().getClass()) { 25 | return true; 26 | } 27 | } 28 | return false; 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/filters/ToolTipFilter.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.filters; 2 | 3 | import me.dustin.jex.event.render.EventRenderToolTip; 4 | import net.minecraft.item.Item; 5 | import java.util.function.Predicate; 6 | 7 | public class ToolTipFilter implements Predicate { 8 | 9 | private final EventRenderToolTip.Mode mode; 10 | private final Item[] items; 11 | 12 | public ToolTipFilter(EventRenderToolTip.Mode mode, Item... items) { 13 | this.mode = mode; 14 | this.items = items; 15 | } 16 | 17 | @Override 18 | public boolean test(EventRenderToolTip eventRenderToolTip) { 19 | if (items.length > 0) { 20 | for (Item item : items) { 21 | if (mode != null) 22 | return item == eventRenderToolTip.getItemStack().getItem() && mode == eventRenderToolTip.getMode(); 23 | return item == eventRenderToolTip.getItemStack().getItem(); 24 | } 25 | return false; 26 | } 27 | if (mode != null) 28 | return eventRenderToolTip.getMode() == mode; 29 | return true; 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/filters/ToolTipItemFilter.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.filters; 2 | 3 | import me.dustin.jex.event.misc.EventGetToolTipFromItem; 4 | import net.minecraft.item.Item; 5 | import java.util.function.Predicate; 6 | 7 | public class ToolTipItemFilter implements Predicate { 8 | 9 | private final Item[] items; 10 | 11 | @SafeVarargs 12 | public ToolTipItemFilter(Item... items) { 13 | this.items = items; 14 | } 15 | 16 | @Override 17 | public boolean test(EventGetToolTipFromItem eventGetToolTipFromItem) { 18 | if (items.length <= 0) 19 | return true; 20 | for (Item item : items) { 21 | if (eventGetToolTipFromItem.getItemStack() == null) 22 | return item == null; 23 | if (item == eventGetToolTipFromItem.getItemStack().getItem()) { 24 | return true; 25 | } 26 | } 27 | return false; 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/misc/EventControlLlama.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.misc; 2 | 3 | import me.dustin.events.core.Event; 4 | 5 | public class EventControlLlama extends Event { 6 | 7 | private boolean control; 8 | 9 | public boolean isControl() { 10 | return control; 11 | } 12 | 13 | public void setControl(boolean control) { 14 | this.control = control; 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/misc/EventEntityHitbox.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.misc; 2 | 3 | import me.dustin.events.core.Event; 4 | import net.minecraft.entity.Entity; 5 | import net.minecraft.util.math.Box; 6 | 7 | public class EventEntityHitbox extends Event { 8 | 9 | private final Entity entity; 10 | private Box box; 11 | 12 | public EventEntityHitbox(Entity entity, Box box) { 13 | this.entity = entity; 14 | this.box = box; 15 | } 16 | 17 | public Entity getEntity() { 18 | return entity; 19 | } 20 | 21 | public Box getBox() { 22 | return box; 23 | } 24 | 25 | public void setBox(Box box) { 26 | this.box = box; 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/misc/EventGameFinishedLoading.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.misc; 2 | 3 | import me.dustin.events.core.Event; 4 | 5 | public class EventGameFinishedLoading extends Event { 6 | } 7 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/misc/EventGetFramerateLimit.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.misc; 2 | 3 | import me.dustin.events.core.Event; 4 | 5 | public class EventGetFramerateLimit extends Event { 6 | 7 | private int limit = -1; 8 | 9 | public int getLimit() { 10 | return limit; 11 | } 12 | 13 | public void setLimit(int limit) { 14 | this.limit = limit; 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/misc/EventGetToolTipFromItem.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.misc; 2 | 3 | import me.dustin.events.core.Event; 4 | import net.minecraft.item.ItemStack; 5 | import net.minecraft.text.Text; 6 | import java.util.ArrayList; 7 | import java.util.List; 8 | 9 | public class EventGetToolTipFromItem extends Event { 10 | 11 | private final ItemStack itemStack; 12 | private List textList; 13 | 14 | public EventGetToolTipFromItem(ItemStack itemStack, List textList) { 15 | this.itemStack = itemStack; 16 | this.textList = textList; 17 | } 18 | 19 | public ItemStack getItemStack() { 20 | return itemStack; 21 | } 22 | 23 | public List getTextList() { 24 | return textList; 25 | } 26 | 27 | public void setTextList(ArrayList textList) { 28 | this.textList = textList; 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/misc/EventHorseIsSaddled.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.misc; 2 | 3 | import me.dustin.events.core.Event; 4 | import net.minecraft.entity.Entity; 5 | 6 | public class EventHorseIsSaddled extends Event { 7 | 8 | private boolean isSaddled; 9 | private final Entity entity; 10 | 11 | public EventHorseIsSaddled(Entity entity) { 12 | this.entity = entity; 13 | } 14 | 15 | public boolean isSaddled() { 16 | return isSaddled; 17 | } 18 | 19 | public void setSaddled(boolean saddled) { 20 | isSaddled = saddled; 21 | } 22 | 23 | public Entity getEntity() { 24 | return entity; 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/misc/EventItemStackDecrement.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.misc; 2 | 3 | import me.dustin.events.core.Event; 4 | import net.minecraft.item.ItemStack; 5 | 6 | public class EventItemStackDecrement extends Event { 7 | private final Mode mode; 8 | private final ItemStack itemStack; 9 | private final int amount; 10 | private final int stackCount; 11 | 12 | public EventItemStackDecrement(Mode mode, ItemStack itemStack, int amount, int stackCount) { 13 | this.mode = mode; 14 | this.itemStack = itemStack; 15 | this.amount = amount; 16 | this.stackCount = stackCount; 17 | } 18 | 19 | public Mode getMode() { 20 | return mode; 21 | } 22 | 23 | public ItemStack getItemStack() { 24 | return itemStack; 25 | } 26 | 27 | public int getAmount() { 28 | return amount; 29 | } 30 | 31 | public int getStackCount() { 32 | return stackCount; 33 | } 34 | 35 | public enum Mode { 36 | PRE, POST 37 | } 38 | } 39 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/misc/EventItemStackSetCount.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.misc; 2 | 3 | import me.dustin.events.core.Event; 4 | import net.minecraft.item.ItemStack; 5 | 6 | public class EventItemStackSetCount extends Event { 7 | private final Mode mode; 8 | private final ItemStack itemStack; 9 | private final int count; 10 | 11 | public EventItemStackSetCount(Mode mode, ItemStack itemStack, int count) { 12 | this.mode = mode; 13 | this.itemStack = itemStack; 14 | this.count = count; 15 | } 16 | 17 | public Mode getMode() { 18 | return mode; 19 | } 20 | 21 | public ItemStack getItemStack() { 22 | return itemStack; 23 | } 24 | 25 | public int getCount() { 26 | return count; 27 | } 28 | 29 | public enum Mode { 30 | PRE, POST 31 | } 32 | } 33 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/misc/EventKeyPressed.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.misc; 2 | 3 | import me.dustin.events.core.Event; 4 | 5 | public class EventKeyPressed extends Event { 6 | 7 | private final int key; 8 | private final int scancode; 9 | private final PressType type; 10 | 11 | public EventKeyPressed(int key, int scancode, PressType type) { 12 | super(); 13 | this.key = key; 14 | this.scancode = scancode; 15 | this.type = type; 16 | } 17 | 18 | public int getKey() { 19 | return this.key; 20 | } 21 | 22 | public PressType getType() { 23 | return type; 24 | } 25 | 26 | public int getScancode() { 27 | return scancode; 28 | } 29 | 30 | public enum PressType { 31 | IN_GAME, 32 | IN_MENU 33 | } 34 | } 35 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/misc/EventMouseButton.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.misc; 2 | 3 | import me.dustin.events.core.Event; 4 | 5 | public class EventMouseButton extends Event { 6 | 7 | private final int button; 8 | private final ClickType clickType; 9 | 10 | public EventMouseButton(int button, ClickType clickType) { 11 | this.button = button; 12 | this.clickType = clickType; 13 | } 14 | 15 | public int getButton() { 16 | return button; 17 | } 18 | 19 | public ClickType getClickType() { 20 | return clickType; 21 | } 22 | 23 | public enum ClickType { 24 | IN_GAME, 25 | IN_MENU 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/misc/EventPortalCloseGUI.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.misc; 2 | 3 | import me.dustin.events.core.Event; 4 | 5 | public class EventPortalCloseGUI extends Event { 6 | 7 | } 8 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/misc/EventRenderTick.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.misc; 2 | 3 | import me.dustin.events.core.Event; 4 | 5 | public class EventRenderTick extends Event { 6 | 7 | public float timeScale; 8 | 9 | public EventRenderTick(float timeScale) 10 | { 11 | this.timeScale = timeScale; 12 | } 13 | 14 | } 15 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/misc/EventServerTurn.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.misc; 2 | 3 | import me.dustin.events.core.Event; 4 | 5 | public class EventServerTurn extends Event { 6 | } 7 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/misc/EventSetLevel.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.misc; 2 | 3 | import me.dustin.events.core.Event; 4 | 5 | public class EventSetLevel extends Event { 6 | 7 | } 8 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/misc/EventSetOptionInstance.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.misc; 2 | 3 | import me.dustin.events.core.Event; 4 | import net.minecraft.client.option.SimpleOption; 5 | 6 | public class EventSetOptionInstance extends Event { 7 | 8 | private final SimpleOption optionInstance; 9 | private boolean shouldIgnoreCheck; 10 | 11 | public EventSetOptionInstance(SimpleOption optionInstance) { 12 | this.optionInstance = optionInstance; 13 | } 14 | 15 | public SimpleOption getOptionInstance() { 16 | return optionInstance; 17 | } 18 | 19 | public boolean isShouldIgnoreCheck() { 20 | return shouldIgnoreCheck; 21 | } 22 | 23 | public void setShouldIgnoreCheck(boolean shouldIgnoreCheck) { 24 | this.shouldIgnoreCheck = shouldIgnoreCheck; 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/misc/EventSetScreen.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.misc; 2 | 3 | import me.dustin.events.core.Event; 4 | import net.minecraft.client.gui.screen.Screen; 5 | 6 | public class EventSetScreen extends Event { 7 | 8 | private Screen screen; 9 | 10 | public EventSetScreen(Screen screen) { 11 | this.screen = screen; 12 | } 13 | 14 | public Screen getScreen() { 15 | return screen; 16 | } 17 | 18 | public void setScreen(Screen screen) { 19 | this.screen = screen; 20 | } 21 | 22 | 23 | } 24 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/misc/EventStop.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.misc; 2 | 3 | import me.dustin.events.core.Event; 4 | 5 | public class EventStop extends Event { 6 | } 7 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/misc/EventTick.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.misc; 2 | 3 | import me.dustin.events.core.Event; 4 | 5 | public class EventTick extends Event { 6 | private Mode mode; 7 | 8 | public EventTick(Mode mode) { 9 | this.mode = mode; 10 | } 11 | 12 | public Mode getMode() { 13 | return mode; 14 | } 15 | 16 | public enum Mode { 17 | PRE, POST 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/packet/EventConnect.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.packet; 2 | 3 | import me.dustin.events.core.Event; 4 | import net.minecraft.client.network.ServerAddress; 5 | 6 | public class EventConnect extends Event { 7 | 8 | private final ServerAddress serverAddress; 9 | 10 | public EventConnect(ServerAddress serverAddress) { 11 | this.serverAddress = serverAddress; 12 | } 13 | 14 | public ServerAddress getServerAddress() { 15 | return serverAddress; 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/packet/EventHello.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.packet; 2 | 3 | import me.dustin.events.core.Event; 4 | import net.minecraft.network.ClientConnection; 5 | 6 | public class EventHello extends Event { 7 | 8 | private final ClientConnection clientConnection; 9 | private final String serverhash; 10 | 11 | public EventHello(ClientConnection clientConnection, String serverhash) { 12 | this.clientConnection = clientConnection; 13 | this.serverhash = serverhash; 14 | } 15 | 16 | public ClientConnection getClientConnection() { 17 | return clientConnection; 18 | } 19 | 20 | public String getServerhash() { 21 | return serverhash; 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/packet/EventPacketReceive.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.packet; 2 | 3 | import me.dustin.events.core.Event; 4 | import net.minecraft.network.Packet; 5 | 6 | public class EventPacketReceive extends Event { 7 | 8 | private Packet packet; 9 | private final Mode mode; 10 | 11 | public EventPacketReceive(Packet packet, Mode mode) { 12 | this.packet = packet; 13 | this.mode = mode; 14 | } 15 | 16 | public Packet getPacket() { 17 | return packet; 18 | } 19 | 20 | public Mode getMode() { 21 | return mode; 22 | } 23 | 24 | public void setPacket(Packet packet) { 25 | this.packet = packet; 26 | } 27 | 28 | public enum Mode { 29 | PRE, POST 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/player/EventAttackEntity.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.player; 2 | 3 | import me.dustin.events.core.Event; 4 | import net.minecraft.entity.Entity; 5 | 6 | public class EventAttackEntity extends Event { 7 | 8 | private Entity entity; 9 | 10 | public EventAttackEntity(Entity entity) { 11 | this.entity = entity; 12 | } 13 | 14 | public Entity getEntity() { 15 | return entity; 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/player/EventCurrentItemAttackStrengthDelay.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.player; 2 | 3 | import me.dustin.events.core.Event; 4 | 5 | public class EventCurrentItemAttackStrengthDelay extends Event { 6 | 7 | private double value = 1; 8 | 9 | public double getValue() { 10 | return value; 11 | } 12 | 13 | public void setValue(double value) { 14 | this.value = value; 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/player/EventExplosionVelocity.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.player; 2 | 3 | import me.dustin.events.core.Event; 4 | 5 | public class EventExplosionVelocity extends Event { 6 | 7 | private float multX; 8 | private float multY; 9 | private float multZ; 10 | 11 | public float getMultX() { 12 | return multX; 13 | } 14 | 15 | public float getMultY() { 16 | return multY; 17 | } 18 | 19 | public float getMultZ() { 20 | return multZ; 21 | } 22 | 23 | public void setMultX(float multX) { 24 | this.multX = multX; 25 | } 26 | 27 | public void setMultY(float multY) { 28 | this.multY = multY; 29 | } 30 | 31 | public void setMultZ(float multZ) { 32 | this.multZ = multZ; 33 | } 34 | } 35 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/player/EventGetPose.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.player; 2 | 3 | import me.dustin.events.core.Event; 4 | import net.minecraft.entity.EntityPose; 5 | 6 | public class EventGetPose extends Event { 7 | 8 | private EntityPose pose; 9 | 10 | public EventGetPose(EntityPose pose) { 11 | this.pose = pose; 12 | } 13 | 14 | public EntityPose getPose() { 15 | return pose; 16 | } 17 | 18 | public void setPose(EntityPose pose) { 19 | this.pose = pose; 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/player/EventGetReachDistance.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.player; 2 | 3 | import me.dustin.events.core.Event; 4 | 5 | public class EventGetReachDistance extends Event { 6 | private Float reachDistance; 7 | 8 | public Float getReachDistance() { 9 | return reachDistance; 10 | } 11 | 12 | public void setReachDistance(float reachDistance) { 13 | this.reachDistance = reachDistance; 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/player/EventGetSkinTexture.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.player; 2 | 3 | import me.dustin.events.core.Event; 4 | import net.minecraft.entity.player.PlayerEntity; 5 | import net.minecraft.util.Identifier; 6 | 7 | public class EventGetSkinTexture extends Event { 8 | private final PlayerEntity playerEntity; 9 | private Identifier skin; 10 | 11 | public EventGetSkinTexture(PlayerEntity playerEntity, Identifier skin) { 12 | this.playerEntity = playerEntity; 13 | this.skin = skin; 14 | } 15 | 16 | public PlayerEntity getPlayerEntity() { 17 | return playerEntity; 18 | } 19 | 20 | public Identifier getSkin() { 21 | return skin; 22 | } 23 | 24 | public void setSkin(Identifier skin) { 25 | this.skin = skin; 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/player/EventHasExtendedReach.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.player; 2 | 3 | import me.dustin.events.core.Event; 4 | 5 | public class EventHasExtendedReach extends Event { 6 | private Boolean extendedReach; 7 | 8 | public Boolean isExtendedReach() { 9 | return extendedReach; 10 | } 11 | 12 | public void setExtendedReach(boolean hasExtendedReach) { 13 | this.extendedReach = hasExtendedReach; 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/player/EventIsPlayerTouchingWater.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.player; 2 | 3 | import me.dustin.events.core.Event; 4 | 5 | public class EventIsPlayerTouchingWater extends Event { 6 | 7 | private boolean isTouchingWater; 8 | 9 | public EventIsPlayerTouchingWater(boolean isTouchingWater) { 10 | this.isTouchingWater = isTouchingWater; 11 | } 12 | 13 | public boolean isTouchingWater() { 14 | return isTouchingWater; 15 | } 16 | 17 | public void setTouchingWater(boolean touchingWater) { 18 | isTouchingWater = touchingWater; 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/player/EventMove.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.player; 2 | 3 | import me.dustin.events.core.Event; 4 | 5 | public class EventMove extends Event { 6 | private double x; 7 | private double y; 8 | private double z; 9 | 10 | public EventMove(double x, double y, double z) { 11 | this.x = x; 12 | this.y = y; 13 | this.z = z; 14 | } 15 | 16 | public double getX() { 17 | return x; 18 | } 19 | 20 | public void setX(double x) { 21 | this.x = x; 22 | } 23 | 24 | public double getY() { 25 | return y; 26 | } 27 | 28 | public void setY(double y) { 29 | this.y = y; 30 | } 31 | 32 | public double getZ() { 33 | return z; 34 | } 35 | 36 | public void setZ(double z) { 37 | this.z = z; 38 | } 39 | 40 | } -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/player/EventPlayerUpdates.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.player; 2 | 3 | import me.dustin.events.core.Event; 4 | 5 | public class EventPlayerUpdates extends Event { 6 | 7 | private final Mode mode; 8 | 9 | public EventPlayerUpdates(Mode mode) { 10 | this.mode = mode; 11 | } 12 | 13 | public Mode getMode() { 14 | return mode; 15 | } 16 | 17 | public enum Mode { 18 | PRE, POST 19 | } 20 | 21 | } 22 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/player/EventPlayerVelocity.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.player; 2 | 3 | import me.dustin.events.core.Event; 4 | 5 | public class EventPlayerVelocity extends Event { 6 | 7 | private int velocityX, velocityY, velocityZ; 8 | 9 | public EventPlayerVelocity(int velocityX, int velocityY, int velocityZ) { 10 | this.velocityX = velocityX; 11 | this.velocityY = velocityY; 12 | this.velocityZ = velocityZ; 13 | } 14 | 15 | public int getVelocityX() { 16 | return velocityX; 17 | } 18 | 19 | public void setVelocityX(int velocityX) { 20 | this.velocityX = velocityX; 21 | } 22 | 23 | public int getVelocityY() { 24 | return velocityY; 25 | } 26 | 27 | public void setVelocityY(int velocityY) { 28 | this.velocityY = velocityY; 29 | } 30 | 31 | public int getVelocityZ() { 32 | return velocityZ; 33 | } 34 | 35 | public void setVelocityZ(int velocityZ) { 36 | this.velocityZ = velocityZ; 37 | } 38 | } 39 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/player/EventPushAwayFromEntity.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.player; 2 | 3 | import me.dustin.events.core.Event; 4 | 5 | public class EventPushAwayFromEntity extends Event { 6 | } 7 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/player/EventPushOutOfBlocks.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.player; 2 | 3 | import me.dustin.events.core.Event; 4 | 5 | public class EventPushOutOfBlocks extends Event { 6 | 7 | } 8 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/player/EventSetPlayerHealth.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.player; 2 | 3 | import me.dustin.events.core.Event; 4 | 5 | public class EventSetPlayerHealth extends Event { 6 | 7 | private float health; 8 | 9 | public EventSetPlayerHealth(float health) { 10 | this.health = health; 11 | } 12 | 13 | public float getHealth() { 14 | return health; 15 | } 16 | 17 | public void setHealth(float health) { 18 | this.health = health; 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/player/EventSetSprint.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.player; 2 | 3 | import me.dustin.events.core.Event; 4 | 5 | public class EventSetSprint extends Event { 6 | 7 | private boolean sprint; 8 | 9 | public EventSetSprint(boolean sprint) { 10 | this.sprint = sprint; 11 | } 12 | 13 | public boolean isSprint() { 14 | return sprint; 15 | } 16 | 17 | public void setSprint(boolean sprint) { 18 | this.sprint = sprint; 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/player/EventSlowdown.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.player; 2 | 3 | import me.dustin.events.core.Event; 4 | 5 | public class EventSlowdown extends Event { 6 | 7 | private final State state; 8 | 9 | public EventSlowdown(State state) { 10 | this.state = state; 11 | } 12 | 13 | public State getState() { 14 | return state; 15 | } 16 | 17 | public enum State { 18 | USE_ITEM, SOULSAND, COBWEB, BERRY_BUSH, POWDERED_SNOW 19 | } 20 | 21 | } 22 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/player/EventStep.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.player; 2 | 3 | import me.dustin.events.core.Event; 4 | import net.minecraft.entity.Entity; 5 | 6 | public class EventStep extends Event { 7 | private final Entity entity; 8 | private final Mode mode; 9 | private final double stepHeight; 10 | 11 | public EventStep(Entity entity, Mode mode, double stepHeight) { 12 | this.entity = entity; 13 | this.mode = mode; 14 | this.stepHeight = stepHeight; 15 | } 16 | 17 | public Entity getEntity() { 18 | return entity; 19 | } 20 | 21 | public Mode getMode() { 22 | return mode; 23 | } 24 | 25 | public double getStepHeight() { 26 | return stepHeight; 27 | } 28 | 29 | public enum Mode { 30 | PRE, MID, END, POST 31 | } 32 | } 33 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/player/EventStopUsingItem.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.player; 2 | 3 | import me.dustin.events.core.Event; 4 | 5 | public class EventStopUsingItem extends Event { 6 | 7 | } -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/player/EventWalkOffBlock.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.player; 2 | 3 | import me.dustin.events.core.Event; 4 | 5 | public class EventWalkOffBlock extends Event { 6 | 7 | } 8 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/render/EventBindShader.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.render; 2 | 3 | import me.dustin.events.core.Event; 4 | import net.minecraft.client.render.Shader; 5 | 6 | public class EventBindShader extends Event { 7 | private final Shader shader; 8 | private final Mode mode; 9 | 10 | public EventBindShader(Shader shader, Mode mode) { 11 | this.shader = shader; 12 | this.mode = mode; 13 | } 14 | 15 | public Shader getShader() { 16 | return shader; 17 | } 18 | 19 | public Mode getMode() { 20 | return mode; 21 | } 22 | 23 | public enum Mode { 24 | PRE, POST 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/render/EventBlockBrightness.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.render; 2 | 3 | import me.dustin.events.core.Event; 4 | import net.minecraft.block.Block; 5 | 6 | public class EventBlockBrightness extends Event { 7 | 8 | private final Block block; 9 | private int brightness; 10 | 11 | public EventBlockBrightness(Block block, int brightness) { 12 | this.block = block; 13 | this.brightness = brightness; 14 | } 15 | 16 | public int getBrightness() { 17 | return brightness; 18 | } 19 | 20 | public Block getBlock() { 21 | return this.block; 22 | } 23 | 24 | public void setBrightness(int brightness) { 25 | this.brightness = brightness; 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/render/EventBlockOutlineColor.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.render; 2 | 3 | import me.dustin.events.core.Event; 4 | 5 | public class EventBlockOutlineColor extends Event { 6 | 7 | private int color; 8 | 9 | public void setColor(int color) { 10 | this.color = color; 11 | } 12 | 13 | public int getColor() { 14 | return this.color; 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/render/EventBobView.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.render; 2 | 3 | import me.dustin.events.core.Event; 4 | 5 | public class EventBobView extends Event { 6 | 7 | 8 | } 9 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/render/EventClipCamera.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.render; 2 | 3 | import me.dustin.events.core.Event; 4 | 5 | public class EventClipCamera extends Event { 6 | } 7 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/render/EventDrawScreen.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.render; 2 | 3 | import me.dustin.events.core.Event; 4 | import net.minecraft.client.gui.screen.Screen; 5 | import net.minecraft.client.util.math.MatrixStack; 6 | 7 | public class EventDrawScreen extends Event { 8 | 9 | private final Screen screen; 10 | private final MatrixStack poseStack; 11 | private final Mode mode; 12 | 13 | public EventDrawScreen(Screen screen, MatrixStack poseStack, Mode mode) { 14 | this.screen = screen; 15 | this.poseStack = poseStack; 16 | this.mode = mode; 17 | } 18 | 19 | public Screen getScreen() { 20 | return screen; 21 | } 22 | 23 | public MatrixStack getPoseStack() { 24 | return poseStack; 25 | } 26 | 27 | public Mode getMode() { 28 | return mode; 29 | } 30 | 31 | public enum Mode { 32 | PRE, POST, POST_CONTAINER 33 | } 34 | } 35 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/render/EventGetGlintShaders.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.render; 2 | 3 | import me.dustin.events.core.Event; 4 | import net.minecraft.client.render.Shader; 5 | 6 | public class EventGetGlintShaders extends Event { 7 | 8 | private Shader shader; 9 | 10 | public EventGetGlintShaders(Shader shader) { 11 | this.shader = shader; 12 | } 13 | 14 | public Shader getShader() { 15 | return shader; 16 | } 17 | 18 | public void setShader(Shader shader) { 19 | this.shader = shader; 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/render/EventGetRenderType.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.render; 2 | 3 | import me.dustin.events.core.Event; 4 | import net.minecraft.block.BlockState; 5 | import net.minecraft.client.render.RenderLayer; 6 | 7 | public class EventGetRenderType extends Event { 8 | private final BlockState state; 9 | private RenderLayer renderType; 10 | 11 | public EventGetRenderType(BlockState state, RenderLayer renderType) { 12 | this.state = state; 13 | this.renderType = renderType; 14 | } 15 | 16 | public BlockState getState() { 17 | return state; 18 | } 19 | 20 | public RenderLayer getRenderType() { 21 | return renderType; 22 | } 23 | 24 | public void setRenderType(RenderLayer renderType) { 25 | this.renderType = renderType; 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/render/EventHurtCam.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.render; 2 | 3 | import me.dustin.events.core.Event; 4 | 5 | public class EventHurtCam extends Event { 6 | 7 | } 8 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/render/EventInitPlayerModel.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.render; 2 | 3 | import me.dustin.events.core.Event; 4 | import net.minecraft.client.model.ModelPart; 5 | 6 | public class EventInitPlayerModel extends Event { 7 | private final ModelPart root; 8 | 9 | public EventInitPlayerModel(ModelPart root) { 10 | this.root = root; 11 | } 12 | 13 | public ModelPart getRoot() { 14 | return root; 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/render/EventIsBlockOpaque.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.render; 2 | 3 | import me.dustin.events.core.Event; 4 | 5 | public class EventIsBlockOpaque extends Event { 6 | private boolean opaque; 7 | 8 | public EventIsBlockOpaque(boolean opaque) { 9 | this.opaque = opaque; 10 | } 11 | 12 | public boolean isOpaque() { 13 | return opaque; 14 | } 15 | 16 | public void setOpaque(boolean opaque) { 17 | this.opaque = opaque; 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/render/EventLivingEntityCallRender.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.render; 2 | 3 | import me.dustin.events.core.Event; 4 | import net.minecraft.entity.LivingEntity; 5 | 6 | public class EventLivingEntityCallRender extends Event { 7 | private final LivingEntity livingEntity; 8 | 9 | public EventLivingEntityCallRender(LivingEntity livingEntity) { 10 | this.livingEntity = livingEntity; 11 | } 12 | 13 | public LivingEntity getLivingEntity() { 14 | return livingEntity; 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/render/EventMarkChunkClosed.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.render; 2 | 3 | import me.dustin.events.core.Event; 4 | 5 | public class EventMarkChunkClosed extends Event { 6 | 7 | } 8 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/render/EventNametagShouldRender.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.render; 2 | 3 | import me.dustin.events.core.Event; 4 | import net.minecraft.entity.Entity; 5 | 6 | 7 | public class EventNametagShouldRender extends Event { 8 | 9 | private final Entity entity; 10 | 11 | public EventNametagShouldRender(Entity entity) { 12 | this.entity = entity; 13 | } 14 | 15 | public Entity getEntity() { 16 | return entity; 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/render/EventPlayerEntityGetBodyParts.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.render; 2 | 3 | import me.dustin.events.core.Event; 4 | import net.minecraft.client.model.ModelPart; 5 | import net.minecraft.client.render.entity.model.PlayerEntityModel; 6 | 7 | import java.util.ArrayList; 8 | 9 | public class EventPlayerEntityGetBodyParts extends Event { 10 | private final PlayerEntityModel playerEntityModel; 11 | private final ArrayList bodyParts; 12 | 13 | public EventPlayerEntityGetBodyParts(PlayerEntityModel playerEntityModel, ArrayList bodyParts) { 14 | this.playerEntityModel = playerEntityModel; 15 | this.bodyParts = bodyParts; 16 | } 17 | 18 | public ArrayList getBodyParts() { 19 | return bodyParts; 20 | } 21 | 22 | public PlayerEntityModel getPlayerEntityModel() { 23 | return playerEntityModel; 24 | } 25 | } 26 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/render/EventPlayerEntityTexturedModelData.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.render; 2 | 3 | import me.dustin.events.core.Event; 4 | import net.minecraft.client.model.Dilation; 5 | import net.minecraft.client.model.ModelData; 6 | 7 | public class EventPlayerEntityTexturedModelData extends Event { 8 | private final ModelData modelData; 9 | private final Dilation dilation; 10 | 11 | public EventPlayerEntityTexturedModelData(ModelData modelData, Dilation dilation) { 12 | this.modelData = modelData; 13 | this.dilation = dilation; 14 | } 15 | 16 | public ModelData getModelData() { 17 | return modelData; 18 | } 19 | 20 | public Dilation getDilation() { 21 | return dilation; 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/render/EventRender2D.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.render; 2 | 3 | import me.dustin.events.core.Event; 4 | import net.minecraft.client.util.math.MatrixStack; 5 | 6 | public class EventRender2D extends Event { 7 | 8 | private final MatrixStack poseStack; 9 | 10 | public EventRender2D(MatrixStack poseStack) { 11 | this.poseStack = poseStack; 12 | } 13 | 14 | public MatrixStack getPoseStack() { 15 | return this.poseStack; 16 | } 17 | 18 | } 19 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/render/EventRender2DItem.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.render; 2 | 3 | import me.dustin.events.core.Event; 4 | import net.minecraft.client.font.TextRenderer; 5 | import net.minecraft.client.render.item.ItemRenderer; 6 | import net.minecraft.item.ItemStack; 7 | 8 | public class EventRender2DItem extends Event { 9 | private final ItemRenderer itemRenderer; 10 | private final TextRenderer fontRenderer; 11 | private final ItemStack stack; 12 | private final int x, y; 13 | 14 | public EventRender2DItem(ItemRenderer itemRenderer, TextRenderer fontRenderer, ItemStack stack, int x, int y) { 15 | this.itemRenderer = itemRenderer; 16 | this.fontRenderer = fontRenderer; 17 | this.stack = stack; 18 | this.x = x; 19 | this.y = y; 20 | } 21 | 22 | public ItemRenderer getItemRenderer() { 23 | return this.itemRenderer; 24 | } 25 | 26 | public final TextRenderer getFontRenderer() { 27 | return this.fontRenderer; 28 | } 29 | 30 | public final ItemStack getStack() { 31 | return this.stack; 32 | } 33 | 34 | public final int getX() { 35 | return this.x; 36 | } 37 | 38 | public final int getY() { 39 | return this.y; 40 | } 41 | } 42 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/render/EventRender2DNoScale.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.render; 2 | 3 | import me.dustin.events.core.Event; 4 | 5 | public class EventRender2DNoScale extends Event { 6 | 7 | } 8 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/render/EventRender3D.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.render; 2 | 3 | import me.dustin.events.core.Event; 4 | import net.minecraft.client.util.math.MatrixStack; 5 | 6 | public class EventRender3D extends Event { 7 | 8 | private final float partialTicks; 9 | private final MatrixStack poseStack; 10 | 11 | public EventRender3D(MatrixStack poseStack, float partialTicks2) { 12 | this.partialTicks = partialTicks2; 13 | this.poseStack = poseStack; 14 | } 15 | 16 | public float getPartialTicks() { 17 | return partialTicks; 18 | } 19 | 20 | public MatrixStack getPoseStack() { 21 | return poseStack; 22 | } 23 | 24 | public static class EventRender3DNoBob extends EventRender3D { 25 | 26 | public EventRender3DNoBob(MatrixStack poseStack, float partialTicks2) { 27 | super(poseStack, partialTicks2); 28 | } 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/render/EventRenderBackground.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.render; 2 | 3 | import me.dustin.events.core.Event; 4 | import net.minecraft.client.util.math.MatrixStack; 5 | 6 | public class EventRenderBackground extends Event { 7 | 8 | private final MatrixStack poseStack; 9 | 10 | public EventRenderBackground(MatrixStack poseStack) { 11 | this.poseStack = poseStack; 12 | } 13 | 14 | public MatrixStack getPoseStack() { 15 | return poseStack; 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/render/EventRenderBlock.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.render; 2 | 3 | import me.dustin.events.core.Event; 4 | import net.minecraft.block.Block; 5 | 6 | public class EventRenderBlock extends Event { 7 | 8 | public Block block; 9 | 10 | public EventRenderBlock(Block block) { 11 | this.block = block; 12 | } 13 | 14 | } 15 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/render/EventRenderBlockEntity.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.render; 2 | 3 | import me.dustin.events.core.Event; 4 | import net.minecraft.block.entity.BlockEntity; 5 | 6 | public class EventRenderBlockEntity extends Event { 7 | 8 | public BlockEntity blockEntity; 9 | 10 | public EventRenderBlockEntity(BlockEntity blockEntity) { 11 | this.blockEntity = blockEntity; 12 | } 13 | 14 | } 15 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/render/EventRenderBodyPart.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.render; 2 | 3 | import me.dustin.events.core.Event; 4 | 5 | public class EventRenderBodyPart extends Event { 6 | } 7 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/render/EventRenderChatHud.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.render; 2 | 3 | import me.dustin.events.core.Event; 4 | import net.minecraft.client.gui.hud.ChatHud; 5 | import net.minecraft.client.util.math.MatrixStack; 6 | 7 | public class EventRenderChatHud extends Event { 8 | private final ChatHud chatHud; 9 | private final MatrixStack poseStack; 10 | private final int tickDelta; 11 | 12 | public EventRenderChatHud(ChatHud chatHud, MatrixStack poseStack, int tickDelta) { 13 | this.chatHud = chatHud; 14 | this.poseStack = poseStack; 15 | this.tickDelta = tickDelta; 16 | } 17 | 18 | public ChatHud getChatHud() { 19 | return chatHud; 20 | } 21 | 22 | public MatrixStack getPoseStack() { 23 | return poseStack; 24 | } 25 | 26 | public int getTickDelta() { 27 | return tickDelta; 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/render/EventRenderChest.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.render; 2 | 3 | import me.dustin.events.core.Event; 4 | 5 | public class EventRenderChest extends Event { 6 | 7 | private boolean christmas; 8 | private final Mode mode; 9 | 10 | public EventRenderChest(Mode mode, boolean christmas) { 11 | this.christmas = christmas; 12 | this.mode = mode; 13 | } 14 | 15 | public boolean isChristmas() { 16 | return christmas; 17 | } 18 | 19 | public void setChristmas(boolean christmas) { 20 | this.christmas = christmas; 21 | } 22 | 23 | public Mode getMode() { 24 | return mode; 25 | } 26 | 27 | public enum Mode { 28 | PRE, POST 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/render/EventRenderCrosshair.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.render; 2 | 3 | import me.dustin.events.core.Event; 4 | import net.minecraft.client.util.math.MatrixStack; 5 | 6 | public class EventRenderCrosshair extends Event { 7 | 8 | private final MatrixStack poseStack; 9 | 10 | public EventRenderCrosshair(MatrixStack poseStack) { 11 | this.poseStack = poseStack; 12 | } 13 | 14 | public MatrixStack getPoseStack() { 15 | return this.poseStack; 16 | } 17 | 18 | } 19 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/render/EventRenderEffects.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.render; 2 | 3 | import me.dustin.events.core.Event; 4 | 5 | public class EventRenderEffects extends Event { 6 | } 7 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/render/EventRenderFeature.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.render; 2 | 3 | import me.dustin.events.core.Event; 4 | import net.minecraft.client.render.entity.feature.FeatureRenderer; 5 | import net.minecraft.entity.Entity; 6 | 7 | public class EventRenderFeature extends Event { 8 | private final FeatureRenderer featureRenderer; 9 | private final Entity entity; 10 | 11 | public EventRenderFeature(FeatureRenderer featureRenderer, Entity entity) { 12 | this.featureRenderer = featureRenderer; 13 | this.entity = entity; 14 | } 15 | 16 | public FeatureRenderer getFeatureRenderer() { 17 | return featureRenderer; 18 | } 19 | 20 | public Entity getEntity() { 21 | return entity; 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/render/EventRenderFluid.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.render; 2 | 3 | import me.dustin.events.core.Event; 4 | import net.minecraft.block.Block; 5 | 6 | public class EventRenderFluid extends Event { 7 | 8 | private final Block block; 9 | 10 | public EventRenderFluid(Block block) { 11 | this.block = block; 12 | } 13 | 14 | public Block getBlock() { 15 | return block; 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/render/EventRenderHand.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.render; 2 | 3 | import me.dustin.events.core.Event; 4 | 5 | public class EventRenderHand extends Event { 6 | 7 | } 8 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/render/EventRenderHeldItem.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.render; 2 | 3 | import me.dustin.events.core.Event; 4 | import net.minecraft.client.util.math.MatrixStack; 5 | import net.minecraft.item.ItemStack; 6 | import net.minecraft.util.Hand; 7 | 8 | public class EventRenderHeldItem extends Event { 9 | 10 | private final ItemStack itemStack; 11 | private final Hand hand; 12 | private final float partialTicks; 13 | private final MatrixStack poseStack; 14 | 15 | public EventRenderHeldItem(ItemStack itemStack, Hand hand, float partialTicks, MatrixStack poseStack) { 16 | this.itemStack = itemStack; 17 | this.hand = hand; 18 | this.partialTicks = partialTicks; 19 | this.poseStack = poseStack; 20 | } 21 | 22 | public ItemStack getItemStack() { 23 | return itemStack; 24 | } 25 | 26 | public Hand getHand() { 27 | return hand; 28 | } 29 | 30 | public float getPartialTicks() { 31 | return partialTicks; 32 | } 33 | 34 | public MatrixStack getPoseStack() { 35 | return poseStack; 36 | } 37 | } 38 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/render/EventRenderNametags.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.render; 2 | 3 | import me.dustin.events.core.Event; 4 | import net.minecraft.client.render.VertexConsumerProvider; 5 | import net.minecraft.client.util.math.MatrixStack; 6 | import net.minecraft.entity.LivingEntity; 7 | 8 | public class EventRenderNametags extends Event { 9 | 10 | private final LivingEntity entity; 11 | private final MatrixStack poseStack; 12 | private final VertexConsumerProvider multiBufferSource; 13 | 14 | public EventRenderNametags(LivingEntity entity, MatrixStack poseStack, VertexConsumerProvider multiBufferSource) { 15 | this.entity = entity; 16 | this.poseStack = poseStack; 17 | this.multiBufferSource = multiBufferSource; 18 | } 19 | 20 | public LivingEntity getEntity() { 21 | return entity; 22 | } 23 | 24 | public MatrixStack getPoseStack() { 25 | return poseStack; 26 | } 27 | 28 | public VertexConsumerProvider getMultiBufferSource() { 29 | return multiBufferSource; 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/render/EventRenderOverlay.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.render; 2 | 3 | import me.dustin.events.core.Event; 4 | 5 | public class EventRenderOverlay extends Event { 6 | 7 | private final Overlay overlay; 8 | 9 | public EventRenderOverlay(Overlay overlay) { 10 | this.overlay = overlay; 11 | } 12 | 13 | public Overlay getOverlay() { 14 | return overlay; 15 | } 16 | 17 | public enum Overlay { 18 | UNDERWATER, LAVA, IN_WALL, FIRE, VIGNETTE, PUMPKIN, PORTAL, COLD, SPYGLASS 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/render/EventRenderRain.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.render; 2 | 3 | import me.dustin.events.core.Event; 4 | 5 | public class EventRenderRain extends Event { 6 | 7 | } 8 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/render/EventRenderShadowAndFire.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.render; 2 | 3 | import me.dustin.events.core.Event; 4 | 5 | public class EventRenderShadowAndFire extends Event { 6 | 7 | } 8 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/render/EventRenderWidget.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.render; 2 | 3 | import me.dustin.events.core.Event; 4 | import net.minecraft.client.gui.widget.ClickableWidget; 5 | import net.minecraft.client.util.math.MatrixStack; 6 | 7 | public class EventRenderWidget extends Event { 8 | 9 | private final ClickableWidget abstractWidget; 10 | private final MatrixStack poseStack; 11 | 12 | public EventRenderWidget(ClickableWidget abstractWidget, MatrixStack poseStack) { 13 | this.abstractWidget = abstractWidget; 14 | this.poseStack = poseStack; 15 | } 16 | 17 | public ClickableWidget getAbstractWidget() { 18 | return abstractWidget; 19 | } 20 | 21 | public MatrixStack getPoseStack() { 22 | return poseStack; 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/render/EventRenderWithShader.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.render; 2 | 3 | import me.dustin.events.core.Event; 4 | import net.minecraft.client.render.BufferBuilder; 5 | 6 | public class EventRenderWithShader extends Event { 7 | private final BufferBuilder.BuiltBuffer buffer; 8 | 9 | public EventRenderWithShader(BufferBuilder.BuiltBuffer buffer) { 10 | this.buffer = buffer; 11 | } 12 | 13 | public BufferBuilder.BuiltBuffer getBuffer() { 14 | return buffer; 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/render/EventRotateItemEntity.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.render; 2 | 3 | import me.dustin.events.core.Event; 4 | import net.minecraft.client.util.math.MatrixStack; 5 | import net.minecraft.entity.ItemEntity; 6 | 7 | public class EventRotateItemEntity extends Event { 8 | 9 | private final ItemEntity itemEntity; 10 | private final MatrixStack poseStack; 11 | private final float g; 12 | 13 | public EventRotateItemEntity(ItemEntity itemEntity, MatrixStack poseStack, float g) { 14 | this.itemEntity = itemEntity; 15 | this.poseStack = poseStack; 16 | this.g = g; 17 | } 18 | 19 | public ItemEntity getItemEntity() { 20 | return itemEntity; 21 | } 22 | 23 | public MatrixStack getPoseStack() { 24 | return poseStack; 25 | } 26 | 27 | public float getG() { 28 | return g; 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/render/EventSetupFog.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.render; 2 | 3 | import me.dustin.events.core.Event; 4 | import net.minecraft.client.render.CameraSubmersionType; 5 | 6 | public class EventSetupFog extends Event { 7 | 8 | private final CameraSubmersionType cameraSubmersionType; 9 | 10 | public EventSetupFog(CameraSubmersionType cameraSubmersionType) { 11 | this.cameraSubmersionType = cameraSubmersionType; 12 | } 13 | 14 | public CameraSubmersionType getCameraSubmersionType() { 15 | return cameraSubmersionType; 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/render/EventShouldDrawSide.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.render; 2 | 3 | import me.dustin.events.core.Event; 4 | import net.minecraft.block.Block; 5 | import net.minecraft.util.math.BlockPos; 6 | import net.minecraft.util.math.Direction; 7 | 8 | public class EventShouldDrawSide extends Event { 9 | 10 | private Block block; 11 | private final Direction side; 12 | private final BlockPos blockPos; 13 | private boolean shouldDrawSide; 14 | 15 | public EventShouldDrawSide(Block block, Direction side, BlockPos blockPos) { 16 | this.block = block; 17 | this.side = side; 18 | this.blockPos = blockPos; 19 | } 20 | 21 | public Block getBlock() { 22 | return block; 23 | } 24 | 25 | public void setBlock(Block block) { 26 | this.block = block; 27 | } 28 | 29 | public boolean isShouldDrawSide() { 30 | return shouldDrawSide; 31 | } 32 | 33 | public void setShouldDrawSide(boolean shouldDrawSide) { 34 | this.shouldDrawSide = shouldDrawSide; 35 | } 36 | 37 | public Direction getSide() { 38 | return side; 39 | } 40 | 41 | public BlockPos getBlockPos() { 42 | return blockPos; 43 | } 44 | } 45 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/render/EventShouldFlipUpsideDown.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.render; 2 | 3 | import me.dustin.events.core.Event; 4 | import net.minecraft.entity.LivingEntity; 5 | 6 | public class EventShouldFlipUpsideDown extends Event { 7 | private final LivingEntity livingEntity; 8 | private boolean flip; 9 | 10 | public EventShouldFlipUpsideDown(LivingEntity livingEntity, boolean flip) { 11 | this.livingEntity = livingEntity; 12 | this.flip = flip; 13 | } 14 | 15 | public LivingEntity getLivingEntity() { 16 | return livingEntity; 17 | } 18 | 19 | public boolean isFlip() { 20 | return flip; 21 | } 22 | 23 | public void setFlip(boolean flip) { 24 | this.flip = flip; 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/render/EventSodiumBeginShader.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.render; 2 | 3 | import me.dustin.events.core.Event; 4 | 5 | public class EventSodiumBeginShader extends Event { 6 | } 7 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/render/EventSodiumQuadAlpha.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.render; 2 | 3 | import me.dustin.events.core.Event; 4 | 5 | public class EventSodiumQuadAlpha extends Event { 6 | private int alpha; 7 | 8 | public EventSodiumQuadAlpha(int alpha) { 9 | this.alpha = alpha; 10 | } 11 | 12 | public int getAlpha() { 13 | return alpha; 14 | } 15 | 16 | public void setAlpha(int alpha) { 17 | this.alpha = alpha; 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/render/EventVisualCooldown.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.render; 2 | 3 | import me.dustin.events.core.Event; 4 | 5 | public class EventVisualCooldown extends Event { 6 | } 7 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/render/EventWorldRender.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.render; 2 | 3 | import me.dustin.events.core.Event; 4 | import net.minecraft.client.util.math.MatrixStack; 5 | import net.minecraft.util.math.Matrix4f; 6 | 7 | public class EventWorldRender extends Event { 8 | 9 | private final float partialTicks; 10 | private final MatrixStack poseStack; 11 | private final Matrix4f posMatrix; 12 | private final Mode mode; 13 | 14 | public EventWorldRender(MatrixStack poseStack, float partialTicks2, Matrix4f posMatrix, Mode mode) { 15 | this.partialTicks = partialTicks2; 16 | this.poseStack = poseStack; 17 | this.posMatrix = posMatrix; 18 | this.mode = mode; 19 | } 20 | 21 | public float getPartialTicks() { 22 | return partialTicks; 23 | } 24 | 25 | public MatrixStack getPoseStack() { 26 | return poseStack; 27 | } 28 | 29 | public Mode getMode() { 30 | return mode; 31 | } 32 | 33 | public Matrix4f getPosMatrix() { 34 | return posMatrix; 35 | } 36 | 37 | public enum Mode { 38 | PRE, POST 39 | } 40 | } 41 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/render/EventWorldRenderEntity.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.render; 2 | 3 | import me.dustin.events.core.Event; 4 | import net.minecraft.client.render.VertexConsumerProvider; 5 | import net.minecraft.client.util.math.MatrixStack; 6 | import net.minecraft.entity.Entity; 7 | 8 | public class EventWorldRenderEntity extends Event { 9 | private final Entity entity; 10 | private final MatrixStack matrixStack; 11 | private final VertexConsumerProvider vertexConsumerProvider; 12 | private final float tickDelta; 13 | 14 | public EventWorldRenderEntity(Entity entity, MatrixStack matrixStack, VertexConsumerProvider vertexConsumerProvider, float tickDelta) { 15 | this.entity = entity; 16 | this.matrixStack = matrixStack; 17 | this.vertexConsumerProvider = vertexConsumerProvider; 18 | this.tickDelta = tickDelta; 19 | } 20 | 21 | public Entity getEntity() { 22 | return entity; 23 | } 24 | 25 | public MatrixStack getMatrixStack() { 26 | return matrixStack; 27 | } 28 | 29 | public VertexConsumerProvider getVertexConsumerProvider() { 30 | return vertexConsumerProvider; 31 | } 32 | 33 | public float getTickDelta() { 34 | return tickDelta; 35 | } 36 | } 37 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/world/EventBlockCollisionShape.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.world; 2 | 3 | import me.dustin.events.core.Event; 4 | import net.minecraft.block.Block; 5 | import net.minecraft.util.math.BlockPos; 6 | import net.minecraft.util.shape.VoxelShape; 7 | 8 | public class EventBlockCollisionShape extends Event { 9 | 10 | private final BlockPos blockPos; 11 | private final Block block; 12 | private VoxelShape voxelShape; 13 | 14 | public EventBlockCollisionShape(BlockPos blockPos, Block block, VoxelShape voxelShape) { 15 | this.blockPos = blockPos; 16 | this.block = block; 17 | this.voxelShape = voxelShape; 18 | } 19 | 20 | public BlockPos getBlockPos() { 21 | return blockPos; 22 | } 23 | 24 | public Block getBlock() { 25 | return block; 26 | } 27 | 28 | public VoxelShape getVoxelShape() { 29 | return voxelShape; 30 | } 31 | 32 | public void setVoxelShape(VoxelShape voxelShape) { 33 | this.voxelShape = voxelShape; 34 | } 35 | } 36 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/world/EventBreakBlock.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.world; 2 | 3 | import me.dustin.events.core.Event; 4 | import net.minecraft.block.BlockState; 5 | import net.minecraft.util.math.BlockPos; 6 | 7 | public class EventBreakBlock extends Event { 8 | private final BlockState blockState; 9 | private final BlockPos pos; 10 | 11 | public EventBreakBlock(BlockState blockState, BlockPos blockPos) { 12 | this.blockState = blockState; 13 | this.pos = blockPos; 14 | } 15 | 16 | public BlockState getBlockState() { 17 | return blockState; 18 | } 19 | 20 | public BlockPos getPos() { 21 | return pos; 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/world/EventClickBlock.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.world; 2 | 3 | import me.dustin.events.core.Event; 4 | import net.minecraft.util.math.BlockPos; 5 | import net.minecraft.util.math.Direction; 6 | 7 | public class EventClickBlock extends Event { 8 | 9 | private final BlockPos blockPos; 10 | private final Direction face; 11 | private final Mode mode; 12 | 13 | public EventClickBlock(BlockPos loc, Direction face, Mode mode) { 14 | this.blockPos = loc; 15 | this.face = face; 16 | this.mode = mode; 17 | } 18 | 19 | public BlockPos getBlockPos() { 20 | return blockPos; 21 | } 22 | 23 | public Direction getFace() { 24 | return face; 25 | } 26 | 27 | public Mode getMode() { 28 | return this.mode; 29 | } 30 | 31 | public enum Mode { 32 | PRE, POST 33 | } 34 | } 35 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/world/EventInteractBlock.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.world; 2 | 3 | import me.dustin.events.core.Event; 4 | import net.minecraft.util.hit.BlockHitResult; 5 | import net.minecraft.util.math.BlockPos; 6 | 7 | public class EventInteractBlock extends Event { 8 | private final BlockPos pos; 9 | private final BlockHitResult blockHitResult; 10 | private final Mode mode; 11 | 12 | public EventInteractBlock(BlockPos blockPos, BlockHitResult blockHitResult, Mode mode) { 13 | this.pos = blockPos; 14 | this.blockHitResult = blockHitResult; 15 | this.mode = mode; 16 | } 17 | 18 | public BlockPos getPos() { 19 | return pos; 20 | } 21 | 22 | public BlockHitResult getBlockHitResult() { 23 | return this.blockHitResult; 24 | } 25 | 26 | public Mode getMode() { 27 | return this.mode; 28 | } 29 | 30 | public enum Mode { 31 | PRE, POST 32 | } 33 | } 34 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/world/EventLoadChunk.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.world; 2 | 3 | import me.dustin.events.core.Event; 4 | import net.minecraft.world.chunk.WorldChunk; 5 | 6 | public class EventLoadChunk extends Event { 7 | 8 | private final WorldChunk worldChunk; 9 | 10 | public EventLoadChunk(WorldChunk worldChunk) { 11 | this.worldChunk = worldChunk; 12 | } 13 | 14 | public WorldChunk getWorldChunk() { 15 | return worldChunk; 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/world/EventPlaySound.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.world; 2 | 3 | import me.dustin.events.core.Event; 4 | import net.minecraft.util.Identifier; 5 | 6 | public class EventPlaySound extends Event { 7 | 8 | private final Mode mode; 9 | private final Identifier identifier; 10 | 11 | public EventPlaySound(Mode mode, Identifier identifier) { 12 | this.mode = mode; 13 | this.identifier = identifier; 14 | } 15 | 16 | public Identifier getIdentifier() { 17 | return identifier; 18 | } 19 | 20 | public Mode getMode() { 21 | return mode; 22 | } 23 | 24 | public enum Mode { 25 | PRE, POST 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/world/EventPlayerInteractionTick.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.world; 2 | 3 | import me.dustin.events.core.Event; 4 | 5 | public class EventPlayerInteractionTick extends Event { 6 | } 7 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/world/EventSpawnEntity.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.world; 2 | 3 | import me.dustin.events.core.Event; 4 | import net.minecraft.entity.Entity; 5 | 6 | public class EventSpawnEntity extends Event { 7 | 8 | private final Entity entity; 9 | 10 | public EventSpawnEntity(Entity entity) { 11 | this.entity = entity; 12 | } 13 | 14 | public Entity getEntity() { 15 | return entity; 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/world/EventTickParticle.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.world; 2 | 3 | import me.dustin.events.core.Event; 4 | import net.minecraft.client.particle.Particle; 5 | 6 | public class EventTickParticle extends Event { 7 | 8 | private final Particle particle; 9 | 10 | public EventTickParticle(Particle particle) { 11 | this.particle = particle; 12 | } 13 | 14 | public Particle getParticle() { 15 | return particle; 16 | } 17 | 18 | public enum Type { 19 | FIREWORK, EXPLOSION, SMOKE 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/world/EventWaterVelocity.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.world; 2 | 3 | import me.dustin.events.core.Event; 4 | 5 | public class EventWaterVelocity extends Event { 6 | } 7 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/event/world/EventWeatherGradient.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.event.world; 2 | 3 | import me.dustin.events.core.Event; 4 | 5 | public class EventWeatherGradient extends Event { 6 | 7 | private float weatherGradient; 8 | 9 | public EventWeatherGradient(float weatherGradient) { 10 | this.weatherGradient = weatherGradient; 11 | } 12 | 13 | public float getWeatherGradient() { 14 | return weatherGradient; 15 | } 16 | 17 | public void setWeatherGradient(float weatherGradient) { 18 | this.weatherGradient = weatherGradient; 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/feature/command/core/annotate/Cmd.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.feature.command.core.annotate; 2 | 3 | import java.lang.annotation.Retention; 4 | import java.lang.annotation.RetentionPolicy; 5 | 6 | /* 7 | * @Author Dustin 8 | * 9/29/2019 9 | */ 10 | @Retention(RetentionPolicy.RUNTIME) 11 | public @interface Cmd { 12 | 13 | String name(); 14 | String description(); 15 | String[] syntax() default {}; 16 | String[] alias() default {}; 17 | 18 | } 19 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/feature/command/core/arguments/impl/PosArgument.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.feature.command.core.arguments.impl; 2 | 3 | import net.fabricmc.fabric.api.client.command.v2.FabricClientCommandSource; 4 | import net.minecraft.util.math.BlockPos; 5 | import net.minecraft.util.math.Vec2f; 6 | import net.minecraft.util.math.Vec3d; 7 | 8 | public interface PosArgument { 9 | Vec3d toAbsolutePos(FabricClientCommandSource source); 10 | 11 | Vec2f toAbsoluteRotation(FabricClientCommandSource source); 12 | 13 | default BlockPos toAbsoluteBlockPos(FabricClientCommandSource source) { 14 | return new BlockPos(this.toAbsolutePos(source)); 15 | } 16 | 17 | boolean isXRelative(); 18 | 19 | boolean isYRelative(); 20 | 21 | boolean isZRelative(); 22 | } 23 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/feature/mod/core/Category.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.feature.mod.core; 2 | 3 | import java.awt.*; 4 | import java.util.ArrayList; 5 | 6 | public record Category(String name, int color) { 7 | private static final ArrayList categories = new ArrayList<>(); 8 | public static final Category COMBAT = new Category("Combat", new Color(255, 61, 56).getRGB()); 9 | public static final Category PLAYER = new Category("Player", new Color(64, 255, 83).getRGB()); 10 | public static final Category MOVEMENT = new Category("Movement", new Color(141, 95, 255).getRGB()); 11 | public static final Category WORLD = new Category("World", new Color(74, 84, 255).getRGB()); 12 | public static final Category VISUAL = new Category("Visual", new Color(255, 92, 252).getRGB()); 13 | public static final Category MISC = new Category("Misc", new Color(247, 255, 65).getRGB()); 14 | 15 | public Category(String name, int color) { 16 | this.name = name; 17 | this.color = color; 18 | categories.add(this); 19 | } 20 | 21 | public static ArrayList values() { 22 | return categories; 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/feature/mod/core/FeatureManager.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.feature.mod.core; 2 | 3 | import me.dustin.jex.feature.plugin.JexPlugin; 4 | import me.dustin.jex.helper.misc.ClassHelper; 5 | 6 | import java.util.ArrayList; 7 | import java.util.List; 8 | 9 | public enum FeatureManager { 10 | INSTANCE; 11 | private final ArrayList features = new ArrayList<>(); 12 | 13 | public void initializeFeatureManager() { 14 | this.getFeatures().forEach(feature -> feature.setState(false)); 15 | this.getFeatures().clear(); 16 | 17 | List> classList = ClassHelper.INSTANCE.getClasses("me.dustin.jex.feature.mod.impl", Feature.class); 18 | classList.forEach(clazz -> { 19 | try { 20 | Feature instance = (Feature) clazz.newInstance(); 21 | this.getFeatures().add(instance); 22 | } catch (InstantiationException | IllegalAccessException e) { 23 | e.printStackTrace(); 24 | } 25 | }); 26 | JexPlugin.featuresLoad(); 27 | features.sort((f1, f2) -> f1.getName().compareToIgnoreCase(f2.getName())); 28 | features.forEach(Feature::loadFeature); 29 | } 30 | 31 | public ArrayList getFeatures() { 32 | return features; 33 | } 34 | } 35 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/feature/mod/impl/combat/Hitboxes.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.feature.mod.impl.combat; 2 | 3 | import me.dustin.events.core.EventListener; 4 | import me.dustin.events.core.annotate.EventPointer; 5 | import me.dustin.jex.event.misc.EventEntityHitbox; 6 | import me.dustin.jex.feature.mod.core.Category; 7 | import me.dustin.jex.feature.property.Property; 8 | import me.dustin.jex.helper.misc.Wrapper; 9 | import me.dustin.jex.feature.mod.core.Feature; 10 | 11 | public class Hitboxes extends Feature { 12 | 13 | public final Property expansionProperty = new Property.PropertyBuilder(this.getClass()) 14 | .name("Expansion") 15 | .value(0.5f) 16 | .min(0.5f) 17 | .max(2) 18 | .inc(0.1f) 19 | .build(); 20 | 21 | public Hitboxes() { 22 | super(Category.COMBAT, "Resize entity hitboxes to make them easier to hit"); 23 | } 24 | 25 | @EventPointer 26 | private final EventListener eventEntityHitboxEventListener = new EventListener<>(event -> { 27 | if (event.getEntity() == null || Wrapper.INSTANCE.getLocalPlayer() == null || event.getEntity().getId() == Wrapper.INSTANCE.getLocalPlayer().getId()) 28 | return; 29 | event.setBox(event.getBox().expand(expansionProperty.value(), 0, expansionProperty.value())); 30 | }); 31 | } 32 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/feature/mod/impl/combat/NoFriendDMG.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.feature.mod.impl.combat; 2 | 3 | import me.dustin.events.core.EventListener; 4 | import me.dustin.events.core.annotate.EventPointer; 5 | import me.dustin.jex.event.player.EventAttackEntity; 6 | import me.dustin.jex.feature.mod.core.Category; 7 | import me.dustin.jex.helper.entity.EntityHelper; 8 | import me.dustin.jex.helper.player.FriendHelper; 9 | import net.minecraft.entity.player.PlayerEntity; 10 | import me.dustin.jex.feature.mod.core.Feature; 11 | 12 | public class NoFriendDMG extends Feature { 13 | 14 | public NoFriendDMG() { 15 | super(Category.COMBAT, "Prevent yourself from attacking your friends and pets"); 16 | } 17 | 18 | @EventPointer 19 | private final EventListener eventAttackEntityEventListener = new EventListener<>(event -> { 20 | if (event.getEntity() instanceof PlayerEntity) { 21 | if (FriendHelper.INSTANCE.isFriend(event.getEntity().getName().getString())) 22 | event.cancel(); 23 | } else if (EntityHelper.INSTANCE.doesPlayerOwn(event.getEntity())) 24 | event.cancel(); 25 | }); 26 | } 27 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/feature/mod/impl/combat/TPSSync.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.feature.mod.impl.combat; 2 | 3 | import me.dustin.events.core.EventListener; 4 | import me.dustin.events.core.annotate.EventPointer; 5 | import me.dustin.jex.event.player.EventCurrentItemAttackStrengthDelay; 6 | import me.dustin.jex.feature.mod.core.Category; 7 | import me.dustin.jex.feature.property.Property; 8 | import me.dustin.jex.helper.math.TPSHelper; 9 | import me.dustin.jex.feature.mod.core.Feature; 10 | 11 | public class TPSSync extends Feature { 12 | 13 | public Property sampleSizeProperty = new Property.PropertyBuilder(this.getClass()) 14 | .name("Sample Size") 15 | .description("The amount of ticks to store for the average.") 16 | .value(15) 17 | .min(2) 18 | .max(100) 19 | .build(); 20 | 21 | public TPSSync() { 22 | super(Category.COMBAT, "Sync attacks to server TPS to deal more damage on laggy servers."); 23 | } 24 | 25 | @EventPointer 26 | private final EventListener eventAttackCooldownPerTickEventListener = new EventListener<>(event -> { 27 | double tps = TPSHelper.INSTANCE.getAverageTPS(); 28 | double value = 20 / tps; 29 | this.setSuffix(String.format("%.2f", tps)); 30 | event.setValue(value); 31 | }); 32 | } 33 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/feature/mod/impl/misc/AutoRespawn.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.feature.mod.impl.misc; 2 | 3 | import me.dustin.events.core.EventListener; 4 | import me.dustin.events.core.annotate.EventPointer; 5 | import me.dustin.jex.event.filters.PlayerPacketsFilter; 6 | import me.dustin.jex.event.player.EventPlayerPackets; 7 | import me.dustin.jex.feature.mod.core.Category; 8 | import me.dustin.jex.helper.misc.Wrapper; 9 | import me.dustin.jex.feature.mod.core.Feature; 10 | 11 | public class AutoRespawn extends Feature { 12 | 13 | public AutoRespawn() { 14 | super(Category.MISC, "Respawn without having to click anything."); 15 | } 16 | 17 | @EventPointer 18 | private final EventListener eventPlayerPacketsEventListener = new EventListener<>(event -> { 19 | if (!Wrapper.INSTANCE.getLocalPlayer().isAlive()) 20 | Wrapper.INSTANCE.getLocalPlayer().requestRespawn(); 21 | }, new PlayerPacketsFilter(EventPlayerPackets.Mode.PRE)); 22 | } 23 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/feature/mod/impl/misc/InventoryPlus.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.feature.mod.impl.misc; 2 | 3 | import me.dustin.events.core.EventListener; 4 | import me.dustin.events.core.annotate.EventPointer; 5 | import me.dustin.jex.event.filters.ClientPacketFilter; 6 | import me.dustin.jex.event.packet.EventPacketSent; 7 | import me.dustin.jex.feature.mod.core.Category; 8 | import me.dustin.jex.helper.misc.Wrapper; 9 | import net.minecraft.client.gui.screen.ingame.InventoryScreen; 10 | import net.minecraft.network.packet.c2s.play.CloseHandledScreenC2SPacket; 11 | import me.dustin.jex.feature.mod.core.Feature; 12 | 13 | public class InventoryPlus extends Feature { 14 | 15 | public InventoryPlus() { 16 | super(Category.MISC, "Keep items in your crafting space in inventory."); 17 | } 18 | 19 | @EventPointer 20 | private final EventListener eventPacketSentEventListener = new EventListener<>(event -> { 21 | if (Wrapper.INSTANCE.getMinecraft().currentScreen instanceof InventoryScreen) { 22 | event.cancel(); 23 | } 24 | }, new ClientPacketFilter(EventPacketSent.Mode.PRE, CloseHandledScreenC2SPacket.class)); 25 | } 26 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/feature/mod/impl/misc/UnfocusedFPS.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.feature.mod.impl.misc; 2 | 3 | import me.dustin.events.core.EventListener; 4 | import me.dustin.events.core.annotate.EventPointer; 5 | import me.dustin.jex.event.misc.EventGetFramerateLimit; 6 | import me.dustin.jex.feature.mod.core.Category; 7 | import me.dustin.jex.feature.mod.core.Feature; 8 | import me.dustin.jex.feature.property.Property; 9 | import me.dustin.jex.helper.misc.Wrapper; 10 | 11 | public class UnfocusedFPS extends Feature { 12 | 13 | public final Property unfocusedFPSProperty = new Property.PropertyBuilder(this.getClass()) 14 | .name("Unfocused FPS") 15 | .value(15) 16 | .min(1) 17 | .max(25) 18 | .build(); 19 | 20 | public UnfocusedFPS() { 21 | super(Category.MISC, "Limit the FPS while Minecraft isn't in focus to save resources"); 22 | setState(true); 23 | } 24 | 25 | @EventPointer 26 | private final EventListener eventGetFramerateLimitEventListener = new EventListener<>(event -> { 27 | boolean focused = Wrapper.INSTANCE.getMinecraft().isWindowFocused(); 28 | if (!focused) { 29 | event.setLimit(unfocusedFPSProperty.value()); 30 | } 31 | }); 32 | } 33 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/feature/mod/impl/movement/Parkour.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.feature.mod.impl.movement; 2 | 3 | import me.dustin.events.core.EventListener; 4 | import me.dustin.events.core.annotate.EventPointer; 5 | import me.dustin.jex.event.filters.PlayerPacketsFilter; 6 | import me.dustin.jex.event.player.EventPlayerPackets; 7 | import me.dustin.jex.feature.mod.core.Category; 8 | import me.dustin.jex.helper.entity.EntityHelper; 9 | import me.dustin.jex.helper.misc.Wrapper; 10 | import me.dustin.jex.helper.player.PlayerHelper; 11 | import me.dustin.jex.feature.mod.core.Feature; 12 | 13 | public class Parkour extends Feature { 14 | 15 | public Parkour() { 16 | super(Category.MOVEMENT, "Jump while on edge of block."); 17 | } 18 | 19 | @EventPointer 20 | private final EventListener eventPlayerPacketsEventListener = new EventListener<>(event -> { 21 | if (Wrapper.INSTANCE.getLocalPlayer().isOnGround() && EntityHelper.INSTANCE.distanceFromGround(Wrapper.INSTANCE.getLocalPlayer()) > 0.5f && PlayerHelper.INSTANCE.isMoving()) { 22 | Wrapper.INSTANCE.getLocalPlayer().jump(); 23 | Wrapper.INSTANCE.getLocalPlayer().getVelocity().multiply(1.2f, 1, 1.2f); 24 | } 25 | }, new PlayerPacketsFilter(EventPlayerPackets.Mode.PRE)); 26 | } 27 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/feature/mod/impl/movement/Safewalk.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.feature.mod.impl.movement; 2 | 3 | import me.dustin.events.core.EventListener; 4 | import me.dustin.events.core.annotate.EventPointer; 5 | import me.dustin.jex.event.player.EventWalkOffBlock; 6 | import me.dustin.jex.feature.mod.core.Category; 7 | import me.dustin.jex.feature.mod.core.Feature; 8 | 9 | public class Safewalk extends Feature { 10 | 11 | public Safewalk() { 12 | super(Category.MOVEMENT, "Prevent yourself from walking off of blocks like you're sneaking"); 13 | } 14 | 15 | @EventPointer 16 | private final EventListener eventWalkOffBlockEventListener = new EventListener<>(event -> event.cancel()); 17 | } 18 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/feature/mod/impl/movement/YawLock.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.feature.mod.impl.movement; 2 | 3 | import me.dustin.events.core.EventListener; 4 | import me.dustin.events.core.annotate.EventPointer; 5 | import me.dustin.jex.event.filters.PlayerPacketsFilter; 6 | import me.dustin.jex.event.player.EventPlayerPackets; 7 | import me.dustin.jex.feature.mod.core.Category; 8 | import me.dustin.jex.helper.misc.Wrapper; 9 | import me.dustin.jex.feature.mod.core.Feature; 10 | import me.dustin.jex.helper.player.PlayerHelper; 11 | 12 | public class YawLock extends Feature { 13 | 14 | public YawLock() { 15 | super(Category.MOVEMENT, "Keep your yaw locked to walk straight."); 16 | } 17 | 18 | @EventPointer 19 | private final EventListener eventPlayerPacketsEventListener = new EventListener<>(event -> { 20 | switch (Wrapper.INSTANCE.getLocalPlayer().getHorizontalFacing()) { 21 | case NORTH -> PlayerHelper.INSTANCE.setYaw(-180); 22 | case SOUTH -> PlayerHelper.INSTANCE.setYaw(0); 23 | case EAST -> PlayerHelper.INSTANCE.setYaw(-90); 24 | case WEST -> PlayerHelper.INSTANCE.setYaw(90); 25 | } 26 | }, new PlayerPacketsFilter(EventPlayerPackets.Mode.PRE)); 27 | } 28 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/feature/mod/impl/movement/elytraplus/impl/AlwaysBoostElytraFly.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.feature.mod.impl.movement.elytraplus.impl; 2 | 3 | import me.dustin.events.core.Event; 4 | import me.dustin.jex.event.player.EventMove; 5 | import me.dustin.jex.feature.mod.core.FeatureExtension; 6 | import me.dustin.jex.feature.mod.impl.movement.elytraplus.ElytraPlus; 7 | import me.dustin.jex.helper.misc.Wrapper; 8 | import net.minecraft.util.math.Vec3d; 9 | 10 | public class AlwaysBoostElytraFly extends FeatureExtension { 11 | public AlwaysBoostElytraFly() { 12 | super(ElytraPlus.Mode.ALWAYS_BOOST, ElytraPlus.class); 13 | } 14 | 15 | @Override 16 | public void pass(Event event) { 17 | if (event instanceof EventMove eventMove) { 18 | if (Wrapper.INSTANCE.getLocalPlayer().isFallFlying()) { 19 | Vec3d vec3d_1 = Wrapper.INSTANCE.getLocalPlayer().getRotationVector(); 20 | Vec3d vec3d_2 = Wrapper.INSTANCE.getLocalPlayer().getVelocity(); 21 | Wrapper.INSTANCE.getLocalPlayer().setVelocity(vec3d_2.add(vec3d_1.x * 0.1D + (vec3d_1.x * 1.5D - vec3d_2.x) * 0.5D, vec3d_1.y * 0.1D + (vec3d_1.y * 1.5D - vec3d_2.y) * 0.5D, vec3d_1.z * 0.1D + (vec3d_1.z * 1.5D - vec3d_2.z) * 0.5D)); 22 | } 23 | } 24 | } 25 | } 26 | 27 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/feature/mod/impl/movement/fly/impl/CreativeFly.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.feature.mod.impl.movement.fly.impl; 2 | 3 | import me.dustin.events.core.Event; 4 | import me.dustin.jex.event.player.EventPlayerPackets; 5 | import me.dustin.jex.feature.mod.core.FeatureExtension; 6 | import me.dustin.jex.feature.mod.impl.movement.fly.Fly; 7 | import me.dustin.jex.helper.misc.Wrapper; 8 | 9 | public class CreativeFly extends FeatureExtension { 10 | 11 | public CreativeFly() { 12 | super(Fly.Mode.CREATIVE, Fly.class); 13 | } 14 | 15 | @Override 16 | public void pass(Event event) { 17 | if (event instanceof EventPlayerPackets eventPlayerPackets && eventPlayerPackets.getMode() == EventPlayerPackets.Mode.PRE) { 18 | Wrapper.INSTANCE.getLocalPlayer().getAbilities().flying = true; 19 | } 20 | } 21 | 22 | @Override 23 | public void disable() { 24 | if (Wrapper.INSTANCE.getLocalPlayer() != null && !Wrapper.INSTANCE.getLocalPlayer().isCreative()) { 25 | Wrapper.INSTANCE.getLocalPlayer().getAbilities().flying = false; 26 | } 27 | super.disable(); 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/feature/mod/impl/player/AntiHunger.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.feature.mod.impl.player; 2 | 3 | import me.dustin.events.core.EventListener; 4 | import me.dustin.events.core.annotate.EventPointer; 5 | import me.dustin.jex.event.filters.PlayerPacketsFilter; 6 | import me.dustin.jex.event.player.EventPlayerPackets; 7 | import me.dustin.jex.feature.mod.core.Category; 8 | import me.dustin.jex.helper.misc.Wrapper; 9 | import me.dustin.jex.feature.mod.core.Feature; 10 | 11 | public class AntiHunger extends Feature { 12 | 13 | public AntiHunger() { 14 | super(Category.PLAYER, "Lose less hunger while sprinting."); 15 | } 16 | 17 | @EventPointer 18 | private final EventListener eventPlayerPacketsEventListener = new EventListener<>(event -> { 19 | if (Wrapper.INSTANCE.getLocalPlayer() == null) 20 | return; 21 | if (Wrapper.INSTANCE.getLocalPlayer().prevY == Wrapper.INSTANCE.getLocalPlayer().getY()) 22 | event.setOnGround(false); 23 | }, new PlayerPacketsFilter(EventPlayerPackets.Mode.PRE)); 24 | } 25 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/feature/mod/impl/player/AutoWalk.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.feature.mod.impl.player; 2 | 3 | import me.dustin.events.core.EventListener; 4 | import me.dustin.events.core.annotate.EventPointer; 5 | import me.dustin.jex.event.filters.PlayerPacketsFilter; 6 | import me.dustin.jex.event.player.EventPlayerPackets; 7 | import me.dustin.jex.feature.mod.core.Category; 8 | import me.dustin.jex.helper.misc.Wrapper; 9 | import net.minecraft.client.option.KeyBinding; 10 | import me.dustin.jex.feature.mod.core.Feature; 11 | 12 | public class AutoWalk extends Feature { 13 | 14 | public AutoWalk() { 15 | super(Category.PLAYER, "Automatically hold W"); 16 | } 17 | 18 | @EventPointer 19 | private final EventListener eventPlayerPacketsEventListener = new EventListener<>(event -> { 20 | KeyBinding.setKeyPressed(Wrapper.INSTANCE.getOptions().forwardKey.getDefaultKey(), true); 21 | }, new PlayerPacketsFilter(EventPlayerPackets.Mode.PRE)); 22 | 23 | @Override 24 | public void onDisable() { 25 | try { 26 | KeyBinding.setKeyPressed(Wrapper.INSTANCE.getOptions().forwardKey.getDefaultKey(), false); 27 | } catch (NullPointerException ignored) { 28 | } 29 | super.onDisable(); 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/feature/mod/impl/player/FastPlace.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.feature.mod.impl.player; 2 | 3 | import me.dustin.events.core.EventListener; 4 | import me.dustin.events.core.annotate.EventPointer; 5 | import me.dustin.jex.event.filters.PlayerPacketsFilter; 6 | import me.dustin.jex.event.player.EventPlayerPackets; 7 | import me.dustin.jex.feature.mod.core.Category; 8 | import me.dustin.jex.helper.misc.Wrapper; 9 | import me.dustin.jex.feature.mod.core.Feature; 10 | 11 | public class FastPlace extends Feature { 12 | 13 | public FastPlace() { 14 | super(Category.PLAYER, "Place fast."); 15 | } 16 | 17 | @EventPointer 18 | private final EventListener eventPlayerPacketsEventListener = new EventListener<>(event -> { 19 | Wrapper.INSTANCE.getIMinecraft().setRightClickDelayTimer(0); 20 | }, new PlayerPacketsFilter(EventPlayerPackets.Mode.PRE)); 21 | 22 | @Override 23 | public void onDisable() { 24 | Wrapper.INSTANCE.getIMinecraft().setRightClickDelayTimer(4); 25 | super.onDisable(); 26 | } 27 | 28 | } 29 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/feature/mod/impl/player/NoTurn.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.feature.mod.impl.player; 2 | 3 | import me.dustin.events.core.EventListener; 4 | import me.dustin.events.core.annotate.EventPointer; 5 | import me.dustin.jex.event.misc.EventSetLevel; 6 | import me.dustin.jex.event.misc.EventServerTurn; 7 | import me.dustin.jex.feature.mod.core.Category; 8 | import me.dustin.jex.feature.mod.core.Feature; 9 | 10 | public class NoTurn extends Feature { 11 | 12 | private boolean reconnected; 13 | 14 | public NoTurn() { 15 | super(Category.PLAYER, "Ignore the server telling you to look somewhere."); 16 | } 17 | 18 | @EventPointer 19 | private final EventListener eventServerTurnEventListener = new EventListener<>(event -> { 20 | if (reconnected) { 21 | reconnected = false; 22 | return; 23 | } 24 | event.cancel(); 25 | }); 26 | 27 | @EventPointer 28 | private final EventListener eventJoinWorldEventListener = new EventListener<>(event -> { 29 | reconnected = true; 30 | }); 31 | } 32 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/feature/mod/impl/player/PortalGui.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.feature.mod.impl.player; 2 | 3 | import me.dustin.events.core.EventListener; 4 | import me.dustin.events.core.annotate.EventPointer; 5 | import me.dustin.jex.event.misc.EventPortalCloseGUI; 6 | import me.dustin.jex.feature.mod.core.Category; 7 | import me.dustin.jex.feature.mod.core.Feature; 8 | 9 | public class PortalGui extends Feature { 10 | 11 | public PortalGui() { 12 | super(Category.PLAYER, "Open GUIs while in portals."); 13 | } 14 | 15 | @EventPointer 16 | private final EventListener eventPortalCloseGUIEventListener = new EventListener<>(event -> event.cancel()); 17 | } 18 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/feature/mod/impl/render/CameraClip.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.feature.mod.impl.render; 2 | 3 | import me.dustin.events.core.EventListener; 4 | import me.dustin.events.core.annotate.EventPointer; 5 | import me.dustin.jex.event.render.EventClipCamera; 6 | import me.dustin.jex.feature.mod.core.Category; 7 | import me.dustin.jex.feature.mod.core.Feature; 8 | 9 | public class CameraClip extends Feature { 10 | 11 | public CameraClip() { 12 | super(Category.VISUAL, "Remove the restriction forcing cameras close near a wall"); 13 | } 14 | 15 | @EventPointer 16 | private final EventListener eventClipCameraEventListener = new EventListener<>(event -> event.cancel()); 17 | } 18 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/feature/mod/impl/render/Gui.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.feature.mod.impl.render; 2 | 3 | import me.dustin.jex.feature.mod.core.Category; 4 | import me.dustin.jex.feature.mod.core.Feature; 5 | import me.dustin.jex.feature.property.Property; 6 | import me.dustin.jex.gui.jexgui.JexGuiScreen; 7 | import me.dustin.jex.helper.misc.Wrapper; 8 | import org.lwjgl.glfw.GLFW; 9 | 10 | public class Gui extends Feature { 11 | 12 | public final Property noCategoriesProperty = new Property.PropertyBuilder(this.getClass()) 13 | .name("No Categories") 14 | .description("Display all mods on the first page rather than grouping by category.") 15 | .value(false) 16 | .build(); 17 | 18 | public Gui() { 19 | super(Category.VISUAL, "Opens the ClickGui.", GLFW.GLFW_KEY_RIGHT_SHIFT); 20 | } 21 | 22 | @Override 23 | public void onEnable() { 24 | Wrapper.INSTANCE.getMinecraft().setScreen(new JexGuiScreen(Wrapper.INSTANCE.getMinecraft().currentScreen, noCategoriesProperty.value())); 25 | this.toggleState(); 26 | } 27 | 28 | } 29 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/feature/mod/impl/render/NoFog.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.feature.mod.impl.render; 2 | 3 | import com.mojang.blaze3d.systems.RenderSystem; 4 | import me.dustin.events.core.EventListener; 5 | import me.dustin.events.core.annotate.EventPointer; 6 | import me.dustin.jex.event.render.EventSetupFog; 7 | import me.dustin.jex.feature.mod.core.Category; 8 | import me.dustin.jex.feature.mod.core.Feature; 9 | 10 | public class NoFog extends Feature { 11 | 12 | public NoFog() { 13 | super(Category.VISUAL, "Removes all fog from the game."); 14 | } 15 | 16 | @EventPointer 17 | private final EventListener eventApplyFogEventListener = new EventListener<>(event -> { 18 | RenderSystem.setShaderFogStart(0); 19 | RenderSystem.setShaderFogEnd(10000); 20 | }); 21 | 22 | } 23 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/feature/mod/impl/render/NoHurtCam.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.feature.mod.impl.render; 2 | 3 | import me.dustin.events.core.EventListener; 4 | import me.dustin.events.core.annotate.EventPointer; 5 | import me.dustin.jex.event.render.EventHurtCam; 6 | import me.dustin.jex.feature.mod.core.Category; 7 | import me.dustin.jex.feature.mod.core.Feature; 8 | 9 | public class NoHurtCam extends Feature { 10 | 11 | public NoHurtCam() { 12 | super(Category.VISUAL, "Remove the hurt-cam effect that bobs your view when damaged."); 13 | } 14 | 15 | @EventPointer 16 | private final EventListener eventHurtCamEventListener = new EventListener<>(event -> event.cancel()); 17 | } 18 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/feature/mod/impl/render/NoVisualCooldown.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.feature.mod.impl.render; 2 | 3 | import me.dustin.events.core.EventListener; 4 | import me.dustin.events.core.annotate.EventPointer; 5 | import me.dustin.jex.event.render.EventVisualCooldown; 6 | import me.dustin.jex.feature.mod.core.Category; 7 | import me.dustin.jex.feature.mod.core.Feature; 8 | 9 | public class NoVisualCooldown extends Feature { 10 | 11 | public NoVisualCooldown() { 12 | super(Category.VISUAL, "Removes the visual effect of your weapon lowering after attacking."); 13 | } 14 | 15 | @EventPointer 16 | private final EventListener eventVisualCooldownEventListener = new EventListener<>(event -> event.cancel()); 17 | } 18 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/feature/mod/impl/render/TargetHud.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.feature.mod.impl.render; 2 | 3 | import me.dustin.jex.feature.mod.core.Category; 4 | import me.dustin.jex.feature.mod.core.Feature; 5 | import me.dustin.jex.feature.property.Property; 6 | 7 | import java.awt.*; 8 | 9 | public class TargetHud extends Feature { 10 | public TargetHud() { 11 | super(Category.VISUAL, "Display information on the HUD of the entity you are attacking"); 12 | } 13 | 14 | public final Property markTargetProperty = new Property.PropertyBuilder(this.getClass()) 15 | .name("Mark Target") 16 | .description("Show a triangle on the target on your HUD") 17 | .value(true) 18 | .build(); 19 | public final Property markColorProperty = new Property.PropertyBuilder(this.getClass()) 20 | .name("Color") 21 | .value(new Color(0, 180, 255)) 22 | .parent(markTargetProperty) 23 | .depends(parent -> (boolean) parent.value()) 24 | .build(); 25 | public final Property stopTargetDistanceProperty = new Property.PropertyBuilder(this.getClass()) 26 | .name("Stop Targeting Distance") 27 | .value(15) 28 | .min(10) 29 | .max(100) 30 | .build(); 31 | } 32 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/feature/mod/impl/render/esp/impl/BoxESP.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.feature.mod.impl.render.esp.impl; 2 | 3 | import me.dustin.events.core.Event; 4 | import me.dustin.jex.event.render.EventRender3D; 5 | import me.dustin.jex.feature.mod.core.FeatureExtension; 6 | import me.dustin.jex.helper.misc.Wrapper; 7 | import me.dustin.jex.helper.render.Render3DHelper; 8 | import net.minecraft.util.math.Vec3d; 9 | import me.dustin.jex.feature.mod.impl.render.esp.ESP; 10 | 11 | public class BoxESP extends FeatureExtension { 12 | 13 | public BoxESP() { 14 | super(ESP.Mode.BOX, ESP.class); 15 | } 16 | 17 | @Override 18 | public void pass(Event event1) { 19 | if (!event1.equals(EventRender3D.class)) 20 | return; 21 | EventRender3D event = (EventRender3D) event1; 22 | 23 | Wrapper.INSTANCE.getWorld().getEntities().forEach(entity -> { 24 | if (ESP.INSTANCE.isValid(entity)) { 25 | try { 26 | Vec3d vec = Render3DHelper.INSTANCE.getEntityRenderPosition(entity, event.getPartialTicks()); 27 | Render3DHelper.INSTANCE.drawEntityBox(event.getPoseStack(), entity, vec.getX(), vec.getY(), vec.getZ(), ESP.INSTANCE.getColor(entity)); 28 | } catch (Exception e) { 29 | e.printStackTrace(); 30 | } 31 | } 32 | }); 33 | } 34 | } 35 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/feature/mod/impl/render/hud/elements/FPSElement.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.feature.mod.impl.render.hud.elements; 2 | 3 | import me.dustin.jex.helper.math.ColorHelper; 4 | import me.dustin.jex.helper.math.TPSHelper; 5 | import me.dustin.jex.helper.misc.Wrapper; 6 | import me.dustin.jex.helper.render.font.FontHelper; 7 | import net.minecraft.client.util.math.MatrixStack; 8 | 9 | public class FPSElement extends HudElement { 10 | public FPSElement(float x, float y, float minWidth, float minHeight) { 11 | super("FPS", x, y, minWidth, minHeight); 12 | } 13 | 14 | @Override 15 | public void render(MatrixStack matrixStack) { 16 | if (!isVisible()) 17 | return; 18 | super.render(matrixStack); 19 | String str = String.format("FPS\247f: \2477%s", Wrapper.INSTANCE.getMinecraft().fpsDebugString.split(" ")[0]); 20 | float x = isLeftSide() ? getX() + 2.5f : getX() + getWidth() - 0.5f - FontHelper.INSTANCE.getStringWidth(str); 21 | FontHelper.INSTANCE.drawWithShadow(matrixStack, str, x, getY() + 1.5f, ColorHelper.INSTANCE.getClientColor()); 22 | this.setWidth(FontHelper.INSTANCE.getStringWidth(str) + 3); 23 | } 24 | 25 | @Override 26 | public boolean isVisible() { 27 | return getHud().infoProperty.value() && getHud().fpsProperty.value(); 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/feature/mod/impl/render/hud/elements/SaturationElement.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.feature.mod.impl.render.hud.elements; 2 | 3 | import me.dustin.jex.helper.math.ColorHelper; 4 | import me.dustin.jex.helper.misc.Wrapper; 5 | import me.dustin.jex.helper.render.font.FontHelper; 6 | import net.minecraft.client.util.math.MatrixStack; 7 | 8 | public class SaturationElement extends HudElement { 9 | public SaturationElement(float x, float y, float minWidth, float minHeight) { 10 | super("Saturation", x, y, minWidth, minHeight); 11 | } 12 | 13 | @Override 14 | public void render(MatrixStack matrixStack) { 15 | if (!isVisible()) 16 | return; 17 | super.render(matrixStack); 18 | String str = String.format("Saturation\247f: \2477%s", Wrapper.INSTANCE.getLocalPlayer().getHungerManager().getSaturationLevel()); 19 | float x = isLeftSide() ? getX() + 2.5f : getX() + getWidth() - 0.5f - FontHelper.INSTANCE.getStringWidth(str); 20 | FontHelper.INSTANCE.drawWithShadow(matrixStack, str, x, getY() + 1.5f, ColorHelper.INSTANCE.getClientColor()); 21 | this.setWidth(FontHelper.INSTANCE.getStringWidth(str) + 3); 22 | } 23 | 24 | @Override 25 | public boolean isVisible() { 26 | return getHud().infoProperty.value() && getHud().saturationProperty.value(); 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/feature/mod/impl/render/hud/elements/UsernameElement.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.feature.mod.impl.render.hud.elements; 2 | 3 | import me.dustin.jex.helper.math.ColorHelper; 4 | import me.dustin.jex.helper.misc.Wrapper; 5 | import me.dustin.jex.helper.render.font.FontHelper; 6 | import net.minecraft.client.util.math.MatrixStack; 7 | 8 | public class UsernameElement extends HudElement { 9 | public UsernameElement(float x, float y, float minWidth, float minHeight) { 10 | super("Username", x, y, minWidth, minHeight); 11 | } 12 | 13 | @Override 14 | public void render(MatrixStack matrixStack) { 15 | if (!isVisible()) 16 | return; 17 | super.render(matrixStack); 18 | String str = String.format("Username\247f: \2477%s", Wrapper.INSTANCE.getMinecraft().getSession().getUsername()); 19 | float x = isLeftSide() ? getX() + 2.5f : getX() + getWidth() - 0.5f - FontHelper.INSTANCE.getStringWidth(str); 20 | FontHelper.INSTANCE.drawWithShadow(matrixStack, str, x, getY() + 1.5f, ColorHelper.INSTANCE.getClientColor()); 21 | this.setWidth(FontHelper.INSTANCE.getStringWidth(str) + 3); 22 | } 23 | 24 | @Override 25 | public boolean isVisible() { 26 | return getHud().infoProperty.value() && getHud().showUsernameProperty.value(); 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/feature/mod/impl/world/AntiGhostBlock.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.feature.mod.impl.world; 2 | 3 | import me.dustin.events.core.EventListener; 4 | import me.dustin.events.core.annotate.EventPointer; 5 | import me.dustin.jex.event.world.EventBreakBlock; 6 | import me.dustin.jex.feature.mod.core.Category; 7 | import me.dustin.jex.helper.network.NetworkHelper; 8 | import net.minecraft.network.packet.c2s.play.PlayerActionC2SPacket; 9 | import net.minecraft.util.math.Direction; 10 | import me.dustin.jex.feature.mod.core.Feature; 11 | 12 | public class AntiGhostBlock extends Feature { 13 | 14 | public AntiGhostBlock() { 15 | super(Category.WORLD, "Prevent the game from creating ghost blocks."); 16 | } 17 | 18 | @EventPointer 19 | private final EventListener eventBreakBlockEventListener = new EventListener<>(event -> NetworkHelper.INSTANCE.sendPacket(new PlayerActionC2SPacket(PlayerActionC2SPacket.Action.ABORT_DESTROY_BLOCK, event.getPos(), Direction.UP))); 20 | } 21 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/feature/mod/impl/world/AutoMine.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.feature.mod.impl.world; 2 | 3 | import me.dustin.events.core.EventListener; 4 | import me.dustin.events.core.annotate.EventPointer; 5 | import me.dustin.jex.event.filters.PlayerPacketsFilter; 6 | import me.dustin.jex.event.player.EventPlayerPackets; 7 | import me.dustin.jex.feature.mod.core.Category; 8 | import me.dustin.jex.feature.mod.core.Feature; 9 | import me.dustin.jex.helper.misc.Wrapper; 10 | 11 | public class AutoMine extends Feature { 12 | 13 | public AutoMine() { 14 | super(Category.WORLD, "Automatically mine any block you hover over."); 15 | } 16 | 17 | @EventPointer 18 | private final EventListener eventPlayerPacketsEventListener = new EventListener<>(event -> { 19 | Wrapper.INSTANCE.getOptions().attackKey.setPressed(true); 20 | }, new PlayerPacketsFilter(EventPlayerPackets.Mode.PRE)); 21 | 22 | @Override 23 | public void onDisable() { 24 | Wrapper.INSTANCE.getOptions().attackKey.setPressed(false); 25 | super.onDisable(); 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/file/impl/ServerListFile.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.file.impl; 2 | 3 | import me.dustin.jex.file.core.ConfigFile; 4 | import me.dustin.jex.helper.file.FileHelper; 5 | import me.dustin.jex.helper.network.ServerScrubber; 6 | 7 | @ConfigFile.CFG(fileName = "scrub.txt", folder = "") 8 | public class ServerListFile extends ConfigFile { 9 | 10 | @Override 11 | public void read() { 12 | if (!getFile().exists()) { 13 | ServerScrubber.INSTANCE.loadDefaultList(); 14 | write(); 15 | return; 16 | } 17 | 18 | ServerScrubber.INSTANCE.getServers().clear(); 19 | String fileStr = FileHelper.INSTANCE.readFile(getFile()); 20 | for (String ip : fileStr.split("\n")) { 21 | ServerScrubber.INSTANCE.getServers().add(ip); 22 | } 23 | } 24 | 25 | @Override 26 | public void write() { 27 | FileHelper.INSTANCE.writeFile(getFile(), ServerScrubber.INSTANCE.getServers()); 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/gui/changelog/changelog/ChangelogLine.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.gui.changelog.changelog; 2 | 3 | import java.awt.*; 4 | 5 | public record ChangelogLine(String text, Color color) { 6 | 7 | public String getText() { 8 | return text; 9 | } 10 | 11 | public Color getColor() { 12 | return color; 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/gui/jexgui/impl/JexCategoryButton.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.gui.jexgui.impl; 2 | 3 | import me.dustin.jex.feature.mod.core.Category; 4 | import me.dustin.jex.helper.render.Button; 5 | import me.dustin.jex.helper.render.ButtonListener; 6 | import net.minecraft.client.util.math.MatrixStack; 7 | 8 | public class JexCategoryButton extends Button { 9 | private final Category category; 10 | public JexCategoryButton(Category category, float x, float y, float width, float height, ButtonListener listener) { 11 | super(category.name(), x, y, width, height, listener); 12 | this.category = category; 13 | setBackgroundColor(0xa0000000); 14 | } 15 | 16 | @Override 17 | public void render(MatrixStack matrixStack) { 18 | setTextColor(isHovered() ? category.color() : 0xff676767); 19 | super.render(matrixStack); 20 | } 21 | 22 | public Category getCategory() { 23 | return this.category; 24 | } 25 | } 26 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/gui/jexgui/impl/JexFeatureButton.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.gui.jexgui.impl; 2 | 3 | import me.dustin.jex.feature.mod.core.Category; 4 | import me.dustin.jex.feature.mod.core.Feature; 5 | import me.dustin.jex.helper.render.Button; 6 | import me.dustin.jex.helper.render.ButtonListener; 7 | import net.minecraft.client.util.math.MatrixStack; 8 | 9 | public class JexFeatureButton extends Button { 10 | private final Feature feature; 11 | public JexFeatureButton(Feature feature, float x, float y, float width, float height, ButtonListener listener) { 12 | super(feature.getName(), x, y, width, height, listener); 13 | this.feature = feature; 14 | setBackgroundColor(0xa0000000); 15 | } 16 | 17 | @Override 18 | public void render(MatrixStack matrixStack) { 19 | setTextColor(feature.getState() ? getFeature().getCategory().color() : 0xff676767); 20 | super.render(matrixStack); 21 | } 22 | 23 | public Feature getFeature() { 24 | return this.feature; 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/helper/baritone/process/PauseProcess.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.helper.baritone.process; 2 | 3 | import baritone.api.BaritoneAPI; 4 | import baritone.api.process.IBaritoneProcess; 5 | import baritone.api.process.PathingCommand; 6 | import baritone.api.process.PathingCommandType; 7 | 8 | public class PauseProcess implements IBaritoneProcess { 9 | 10 | boolean pause = false; 11 | 12 | @Override 13 | public boolean isActive() { 14 | return pause; 15 | } 16 | 17 | public void pause(boolean pause) { 18 | this.pause = pause; 19 | } 20 | 21 | @Override 22 | public PathingCommand onTick(boolean b, boolean b1) { 23 | return new PathingCommand(BaritoneAPI.getProvider().getPrimaryBaritone().getCustomGoalProcess().getGoal(), PathingCommandType.REQUEST_PAUSE); 24 | } 25 | 26 | @Override 27 | public boolean isTemporary() { 28 | return true; 29 | } 30 | 31 | @Override 32 | public void onLostControl() { 33 | } 34 | 35 | @Override 36 | public double priority() { 37 | return 5; 38 | } 39 | 40 | @Override 41 | public String displayName() { 42 | return "Pause Process"; 43 | } 44 | 45 | @Override 46 | public String displayName0() { 47 | return "pauseProcess"; 48 | } 49 | } 50 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/helper/entity/FakePlayerEntity.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.helper.entity; 2 | 3 | import com.mojang.authlib.GameProfile; 4 | import me.dustin.jex.feature.mod.impl.player.Freecam; 5 | import me.dustin.jex.helper.misc.Wrapper; 6 | import me.dustin.jex.helper.network.MCAPIHelper; 7 | import net.minecraft.client.network.AbstractClientPlayerEntity; 8 | import net.minecraft.client.world.ClientWorld; 9 | import net.minecraft.util.Identifier; 10 | import java.util.UUID; 11 | 12 | public class FakePlayerEntity extends AbstractClientPlayerEntity { 13 | 14 | public FakePlayerEntity(ClientWorld world, GameProfile profile) { 15 | super(world, profile, null); 16 | } 17 | 18 | public void setUuid(UUID uuid) { 19 | this.uuid = uuid; 20 | } 21 | 22 | @Override 23 | public Identifier getSkinTexture() { 24 | if (hasSkinTexture()) 25 | return super.getSkinTexture(); 26 | else 27 | return MCAPIHelper.INSTANCE.getPlayerSkin(this == Freecam.playerEntity ? Wrapper.INSTANCE.getMinecraft().getSession().getProfile().getId() : this.uuid); 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/helper/file/JsonHelper.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.helper.file; 2 | 3 | import com.google.gson.Gson; 4 | import com.google.gson.GsonBuilder; 5 | 6 | public enum JsonHelper { 7 | INSTANCE; 8 | public final Gson gson = new GsonBuilder().disableHtmlEscaping().create(); 9 | public final Gson prettyGson = new GsonBuilder().setPrettyPrinting().disableHtmlEscaping().create(); 10 | 11 | } 12 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/helper/misc/HWID.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.helper.misc; 2 | 3 | import org.apache.commons.codec.digest.DigestUtils; 4 | 5 | import java.net.InetAddress; 6 | 7 | public enum HWID { 8 | INSTANCE; 9 | 10 | private String getLocalHostName() { 11 | try { 12 | return InetAddress.getLocalHost().getHostName(); 13 | } catch (Exception e) { 14 | } 15 | return "UNKNOWN"; 16 | } 17 | 18 | public String getHWID() { 19 | return DigestUtils.md5Hex(System.getenv("COMPUTERNAME") + System.getenv(new StringBuilder("PROCESSOR_IDENTIFIER").append(getLocalHostName()).toString())); 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/helper/misc/Lagometer.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.helper.misc; 2 | 3 | import me.dustin.events.core.EventListener; 4 | import me.dustin.events.core.annotate.EventPointer; 5 | import me.dustin.jex.event.filters.ServerPacketFilter; 6 | import me.dustin.jex.event.packet.EventPacketReceive; 7 | import net.minecraft.network.packet.s2c.play.ChatMessageS2CPacket; 8 | 9 | public enum Lagometer { 10 | INSTANCE; 11 | 12 | private StopWatch lagStopWatch = new StopWatch(); 13 | 14 | @EventPointer 15 | private final EventListener eventPacketReceiveEventListener = new EventListener<>(event -> { 16 | if (!(event.getPacket() instanceof ChatMessageS2CPacket)) 17 | lagStopWatch.reset(); 18 | }, new ServerPacketFilter(EventPacketReceive.Mode.PRE)); 19 | 20 | public boolean isServerLagging() { 21 | return lagStopWatch.getPassed() > 1000 && !(Wrapper.INSTANCE.getMinecraft().isInSingleplayer() && Wrapper.INSTANCE.getMinecraft().isPaused()); 22 | } 23 | 24 | public long getLagTime() { 25 | return lagStopWatch.getPassed(); 26 | } 27 | 28 | } 29 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/helper/misc/MouseHelper.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.helper.misc; 2 | 3 | import me.dustin.jex.helper.render.Render2DHelper; 4 | import org.lwjgl.glfw.GLFW; 5 | 6 | public enum MouseHelper { 7 | INSTANCE; 8 | 9 | public int getMouseX() { 10 | return (int)(Wrapper.INSTANCE.getMinecraft().mouse.getX() * Render2DHelper.INSTANCE.getScaledWidth() / Wrapper.INSTANCE.getWindow().getWidth()); 11 | } 12 | 13 | public double getMouseX_D() { 14 | return Wrapper.INSTANCE.getMinecraft().mouse.getX() * Render2DHelper.INSTANCE.getScaledWidth() / Wrapper.INSTANCE.getWindow().getWidth(); 15 | } 16 | 17 | public int getMouseY() { 18 | return Render2DHelper.INSTANCE.getScaledHeight() - (Render2DHelper.INSTANCE.getScaledHeight() - (int) Wrapper.INSTANCE.getMinecraft().mouse.getY() * Render2DHelper.INSTANCE.getScaledHeight() / Wrapper.INSTANCE.getWindow().getHeight() - 1); 19 | } 20 | 21 | public double getMouseY_D() { 22 | return Render2DHelper.INSTANCE.getScaledHeight() - (Render2DHelper.INSTANCE.getScaledHeight() - Wrapper.INSTANCE.getMinecraft().mouse.getY() * Render2DHelper.INSTANCE.getScaledHeight() / Wrapper.INSTANCE.getWindow().getHeight() - 1); 23 | } 24 | 25 | public boolean isMouseButtonDown(int button) { 26 | return GLFW.glfwGetMouseButton(Wrapper.INSTANCE.getWindow().getHandle(), button) != 0; 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/helper/misc/StopWatch.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.helper.misc; 2 | 3 | public class StopWatch { 4 | 5 | private long currentMS = 0L; 6 | private long lastMS = -1L; 7 | 8 | public void update() { 9 | currentMS = System.currentTimeMillis(); 10 | } 11 | 12 | public void reset() { 13 | lastMS = System.currentTimeMillis(); 14 | } 15 | 16 | public boolean hasPassed(long MS) { 17 | update(); 18 | return currentMS >= lastMS + MS; 19 | } 20 | 21 | public long getPassed() { 22 | update(); 23 | return currentMS - lastMS; 24 | } 25 | 26 | public long getCurrentMS() { 27 | return currentMS; 28 | } 29 | 30 | public long getLastMS() { 31 | return lastMS; 32 | } 33 | } 34 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/helper/network/ConnectedServerHelper.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.helper.network; 2 | 3 | import me.dustin.events.core.EventListener; 4 | import me.dustin.events.core.annotate.EventPointer; 5 | import me.dustin.jex.event.packet.EventConnect; 6 | import net.minecraft.client.network.ServerAddress; 7 | 8 | public enum ConnectedServerHelper { 9 | INSTANCE; 10 | private ServerAddress serverAddress; 11 | 12 | @EventPointer 13 | private final EventListener eventConnectEventListener = new EventListener<>(event -> { 14 | this.serverAddress = event.getServerAddress(); 15 | }); 16 | 17 | public ServerAddress getServerAddress() { 18 | return serverAddress; 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/helper/network/login/minecraft/MinecraftAccountManager.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.helper.network.login.minecraft; 2 | 3 | import me.dustin.jex.gui.account.account.MinecraftAccount; 4 | 5 | import java.util.ArrayList; 6 | 7 | public enum MinecraftAccountManager { 8 | INSTANCE; 9 | 10 | private ArrayList minecraftAccounts = new ArrayList<>(); 11 | 12 | public ArrayList getAccounts() { 13 | return minecraftAccounts; 14 | } 15 | 16 | public MinecraftAccount getAccount(String username) { 17 | for (MinecraftAccount account : getAccounts()) { 18 | if (account.getUsername().equalsIgnoreCase(username)) 19 | return account; 20 | } 21 | return null; 22 | } 23 | 24 | public ArrayList accountsContainChars(String chars) { 25 | ArrayList accountList = new ArrayList<>(); 26 | for (MinecraftAccount account : getAccounts()) { 27 | if (account.getUsername().toLowerCase().contains(chars.toLowerCase())) 28 | accountList.add(account); 29 | } 30 | return accountList; 31 | } 32 | } 33 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/helper/player/bot/BotClientConnection.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.helper.player.bot; 2 | 3 | import io.netty.channel.Channel; 4 | import io.netty.channel.ChannelHandlerContext; 5 | import net.minecraft.network.ClientConnection; 6 | import net.minecraft.network.NetworkSide; 7 | 8 | public class BotClientConnection extends ClientConnection { 9 | private Channel channel; 10 | 11 | public BotClientConnection(NetworkSide side) { 12 | super(side); 13 | } 14 | 15 | @Override 16 | public void channelActive(ChannelHandlerContext context) throws Exception { 17 | super.channelActive(context); 18 | this.channel = context.channel(); 19 | } 20 | 21 | @Override 22 | public void handleDisconnection() { 23 | } 24 | 25 | public void close() { 26 | if (this.channel != null && channel.isOpen()) { 27 | channel.close(); 28 | } 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/helper/player/bot/UncaughtExceptionLogger.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.helper.player.bot; 2 | 3 | import org.apache.logging.log4j.Logger; 4 | 5 | import java.lang.Thread.UncaughtExceptionHandler; 6 | 7 | public class UncaughtExceptionLogger implements UncaughtExceptionHandler { 8 | private final Logger logger; 9 | 10 | public UncaughtExceptionLogger(Logger logger) { 11 | this.logger = logger; 12 | } 13 | 14 | public void uncaughtException(Thread thread, Throwable throwable) { 15 | this.logger.error("Caught previously unhandled exception :", throwable); 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/helper/render/BufferHelper.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.helper.render; 2 | 3 | import com.mojang.blaze3d.systems.RenderSystem; 4 | import me.dustin.jex.helper.render.shader.ShaderProgram; 5 | import net.minecraft.client.render.*; 6 | 7 | import java.util.function.Supplier; 8 | 9 | public enum BufferHelper { 10 | INSTANCE; 11 | 12 | public void begin(BufferBuilder bufferBuilder, VertexFormat.DrawMode drawMode, VertexFormat format) { 13 | bufferBuilder.begin(drawMode, format); 14 | } 15 | 16 | public BufferBuilder begin(VertexFormat.DrawMode drawMode, VertexFormat format) { 17 | BufferBuilder bufferBuilder = Tessellator.getInstance().getBuffer(); 18 | begin(bufferBuilder, drawMode, format); 19 | return bufferBuilder; 20 | } 21 | 22 | public void drawWithShader(BufferBuilder bufferBuilder, ShaderProgram shaderProgram) { 23 | bufferBuilder.clear(); 24 | shaderProgram.bind(); 25 | BufferRenderer.drawWithoutShader(bufferBuilder.end()); 26 | shaderProgram.detach(); 27 | } 28 | 29 | public void drawWithShader(BufferBuilder bufferBuilder, Supplier shaderProgram) { 30 | RenderSystem.setShader(shaderProgram); 31 | bufferBuilder.clear(); 32 | BufferRenderer.drawWithShader(bufferBuilder.end()); 33 | } 34 | } 35 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/helper/render/ButtonListener.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.helper.render; 2 | 3 | public abstract class ButtonListener { 4 | public Button button; 5 | 6 | public ButtonListener() { 7 | } 8 | 9 | public ButtonListener(Button button) { 10 | this.button = button; 11 | } 12 | 13 | public abstract void invoke(); 14 | } 15 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/helper/render/Scissor.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.helper.render; 2 | 3 | import me.dustin.jex.helper.misc.Wrapper; 4 | import org.lwjgl.opengl.GL11; 5 | 6 | public enum Scissor { 7 | INSTANCE; 8 | 9 | public void cut(int x, int y, int width, int height) { 10 | double factor = Render2DHelper.INSTANCE.getScaleFactor(); 11 | GL11.glScissor((int)(x * factor), (int)((Wrapper.INSTANCE.getWindow().getScaledHeight() - (y + height)) * factor), (int)(width * factor), (int)(height * factor)); 12 | GL11.glEnable(GL11.GL_SCISSOR_TEST); 13 | } 14 | 15 | public void seal() { 16 | GL11.glDisable(GL11.GL_SCISSOR_TEST); 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/helper/render/shader/ShaderHelper.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.helper.render.shader; 2 | 3 | import me.dustin.jex.helper.render.shader.impl.*; 4 | 5 | public enum ShaderHelper { 6 | INSTANCE; 7 | private PosColorShader posColorShader; 8 | private OutlineShader outlineShader; 9 | private EnchantColorShader enchantColorShader; 10 | private BlurShader blurShader; 11 | private OpacityXrayShader opacityXrayShader; 12 | 13 | public void loadShaders() { 14 | posColorShader = new PosColorShader(); 15 | outlineShader = new OutlineShader(); 16 | enchantColorShader = new EnchantColorShader(); 17 | blurShader = new BlurShader(); 18 | opacityXrayShader = new OpacityXrayShader(); 19 | } 20 | 21 | public PosColorShader getPosColorShader() { 22 | return posColorShader; 23 | } 24 | 25 | public OutlineShader getOutlineShader() { 26 | return outlineShader; 27 | } 28 | 29 | public EnchantColorShader getEnchantColorShader() { 30 | return enchantColorShader; 31 | } 32 | 33 | public BlurShader getBlurShader() { 34 | return blurShader; 35 | } 36 | 37 | public OpacityXrayShader getOpacityXrayShader() { 38 | return opacityXrayShader; 39 | } 40 | } 41 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/helper/render/shader/impl/PosColorShader.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.helper.render.shader.impl; 2 | 3 | import com.mojang.blaze3d.systems.RenderSystem; 4 | import me.dustin.jex.helper.math.Matrix4x4; 5 | import me.dustin.jex.helper.misc.Wrapper; 6 | import me.dustin.jex.helper.render.shader.ShaderProgram; 7 | import me.dustin.jex.helper.render.shader.ShaderUniform; 8 | import net.minecraft.util.math.Matrix4f; 9 | import net.minecraft.util.math.Vec2f; 10 | 11 | public class PosColorShader extends ShaderProgram { 12 | private final ShaderUniform projection, modelView; 13 | public PosColorShader() { 14 | super("pos_color"); 15 | this.projection = addUniform("Projection"); 16 | this.modelView = addUniform("ModelView"); 17 | this.bindAttribute("Position", 0); 18 | this.bindAttribute("Color", 1); 19 | } 20 | 21 | @Override 22 | public void updateUniforms() { 23 | this.projection.setMatrix(RenderSystem.getProjectionMatrix()); 24 | this.modelView.setMatrix(RenderSystem.getModelViewMatrix()); 25 | } 26 | } -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/helper/world/SeedHelper.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.helper.world; 2 | 3 | import org.apache.commons.lang3.StringUtils; 4 | 5 | import java.util.OptionalLong; 6 | 7 | public enum SeedHelper { 8 | INSTANCE; 9 | public OptionalLong getSeed(String string) { 10 | OptionalLong optionalLong4; 11 | if (StringUtils.isEmpty(string)) { 12 | optionalLong4 = OptionalLong.empty(); 13 | } else { 14 | OptionalLong optionalLong2 = tryParseLong(string); 15 | if (optionalLong2.isPresent() && optionalLong2.getAsLong() != 0L) { 16 | optionalLong4 = optionalLong2; 17 | } else { 18 | optionalLong4 = OptionalLong.of(string.hashCode()); 19 | } 20 | } 21 | 22 | return optionalLong4; 23 | } 24 | 25 | public static OptionalLong tryParseLong(String string) { 26 | try { 27 | return OptionalLong.of(Long.parseLong(string)); 28 | } catch (NumberFormatException var2) { 29 | return OptionalLong.empty(); 30 | } 31 | } 32 | } 33 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/helper/world/wurstpathfinder/PathPos.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2014-2021 Wurst-Imperium and contributors. 3 | * 4 | * This source code is subject to the terms of the GNU General Public 5 | * License, version 3. If a copy of the GPL was not distributed with this 6 | * file, You can obtain one at: https://www.gnu.org/licenses/gpl-3.0.txt 7 | */ 8 | package me.dustin.jex.helper.world.wurstpathfinder; 9 | 10 | import net.minecraft.util.math.BlockPos; 11 | 12 | public class PathPos extends BlockPos 13 | { 14 | private final boolean jumping; 15 | 16 | public PathPos(BlockPos pos) 17 | { 18 | this(pos, false); 19 | } 20 | 21 | public PathPos(BlockPos pos, boolean jumping) 22 | { 23 | super(pos); 24 | this.jumping = jumping; 25 | } 26 | 27 | public boolean isJumping() 28 | { 29 | return jumping; 30 | } 31 | 32 | @Override 33 | public boolean equals(Object obj) 34 | { 35 | if(this == obj) 36 | return true; 37 | 38 | if(!(obj instanceof PathPos node)) 39 | return false; 40 | 41 | return getX() == node.getX() && getY() == node.getY() 42 | && getZ() == node.getZ() && isJumping() == node.isJumping(); 43 | } 44 | 45 | @Override 46 | public int hashCode() 47 | { 48 | return super.hashCode() * 2 + (isJumping() ? 1 : 0); 49 | } 50 | } 51 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/load/JexLoad.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.load; 2 | 3 | import me.dustin.jex.feature.plugin.JexPlugin; 4 | import me.dustin.jex.helper.render.shader.ShaderHelper; 5 | import net.fabricmc.api.ModInitializer; 6 | import net.fabricmc.fabric.api.resource.ResourceManagerHelper; 7 | import net.fabricmc.fabric.api.resource.SimpleSynchronousResourceReloadListener; 8 | import net.minecraft.resource.ResourceManager; 9 | import net.minecraft.resource.ResourceType; 10 | import net.minecraft.util.Identifier; 11 | 12 | public class JexLoad implements ModInitializer { 13 | @Override 14 | public void onInitialize() { 15 | //Place for things that require fabric to load assets before being loaded 16 | ResourceManagerHelper.get(ResourceType.CLIENT_RESOURCES).registerReloadListener(new SimpleSynchronousResourceReloadListener() { 17 | @Override 18 | public void reload(ResourceManager manager) { 19 | ShaderHelper.INSTANCE.loadShaders(); 20 | } 21 | 22 | @Override 23 | public Identifier getFabricId() { 24 | return new Identifier("jex", "shaders/core/"); 25 | } 26 | }); 27 | JexPlugin.fabricLoad(); 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/load/PreLaunch.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.load; 2 | 3 | import me.dustin.jex.feature.plugin.JexPluginManager; 4 | import net.fabricmc.loader.api.entrypoint.PreLaunchEntrypoint; 5 | import org.apache.logging.log4j.LogManager; 6 | import org.apache.logging.log4j.Logger; 7 | import org.spongepowered.asm.mixin.Mixins; 8 | 9 | public class PreLaunch implements PreLaunchEntrypoint { 10 | private final Logger LOGGER = LogManager.getFormatterLogger("JexPlugins"); 11 | @Override 12 | public void onPreLaunch() { 13 | LOGGER.info("Adding Jex plugins to class path"); 14 | JexPluginManager.INSTANCE.loadPlugins(); 15 | JexPluginManager.INSTANCE.getPlugins().forEach(jexPlugin -> { 16 | if (!jexPlugin.getInfo().getMixinFile().isEmpty()) { 17 | LOGGER.info("Adding mixin config %s from plugin %s".formatted(jexPlugin.getInfo().getMixinFile(), jexPlugin.getInfo().getName())); 18 | Mixins.addConfiguration(jexPlugin.getInfo().getMixinFile()); 19 | } 20 | }); 21 | } 22 | } -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/load/impl/IAbstractHorseEntity.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.load.impl; 2 | 3 | public interface IAbstractHorseEntity { 4 | 5 | void setJumpPower(double power); 6 | 7 | void setJumpStrength(double strength); 8 | 9 | void setSpeed(double speed); 10 | 11 | } 12 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/load/impl/IChatHud.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.load.impl; 2 | 3 | import java.util.List; 4 | import net.minecraft.client.gui.hud.ChatHudLine; 5 | 6 | public interface IChatHud { 7 | boolean containsMessage(String message); 8 | List getMessages(); 9 | } 10 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/load/impl/IChatInputSuggestor.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.load.impl; 2 | 3 | public interface IChatInputSuggestor { 4 | boolean isWindowActive(); 5 | } 6 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/load/impl/IChatScreen.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.load.impl; 2 | 3 | import net.minecraft.client.gui.widget.TextFieldWidget; 4 | 5 | public interface IChatScreen { 6 | String getText(); 7 | void setText(String text); 8 | TextFieldWidget getWidget(); 9 | } 10 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/load/impl/IClientPlayNetworkHandler.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.load.impl; 2 | 3 | import net.minecraft.client.world.ClientWorld; 4 | 5 | public interface IClientPlayNetworkHandler { 6 | void setWorld(ClientWorld world); 7 | } 8 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/load/impl/IClientPlayerEntity.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.load.impl; 2 | 3 | import com.mojang.brigadier.ParseResults; 4 | import net.minecraft.command.CommandSource; 5 | import net.minecraft.network.message.ArgumentSignatureDataMap; 6 | import net.minecraft.network.message.LastSeenMessageList; 7 | import net.minecraft.network.message.MessageMetadata; 8 | import net.minecraft.text.Text; 9 | import org.jetbrains.annotations.Nullable; 10 | 11 | public interface IClientPlayerEntity { 12 | ArgumentSignatureDataMap callSignArguments(MessageMetadata signer, ParseResults parseResults, @Nullable Text preview, LastSeenMessageList lastSeenMessages); 13 | } 14 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/load/impl/IClientPlayerInteractionManager.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.load.impl; 2 | 3 | import net.minecraft.client.network.ClientPlayNetworkHandler; 4 | import net.minecraft.util.math.BlockPos; 5 | 6 | public interface IClientPlayerInteractionManager { 7 | 8 | void setBlockBreakProgress(float progress); 9 | void setBlockBreakingCooldown(int cooldown); 10 | float getBlockBreakProgress(); 11 | int getBlockBreakingCooldown(); 12 | BlockPos currentBreakingPos(); 13 | void setNetworkHandler(ClientPlayNetworkHandler clientPlayNetworkHandler); 14 | } 15 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/load/impl/IFrameBuffer.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.load.impl; 2 | 3 | public interface IFrameBuffer { 4 | void setDepthAttachment(int depth); 5 | } 6 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/load/impl/IHandledScreen.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.load.impl; 2 | 3 | import net.minecraft.screen.slot.Slot; 4 | 5 | public interface IHandledScreen { 6 | 7 | Slot focusedSlot(); 8 | 9 | int getX(); 10 | 11 | int getY(); 12 | } 13 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/load/impl/IItemRenderer.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.load.impl; 2 | 3 | import net.minecraft.item.ItemStack; 4 | 5 | public interface IItemRenderer { 6 | 7 | void renderItemIntoGUI(ItemStack itemStack, float x, float y); 8 | 9 | } 10 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/load/impl/IKeyBinding.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.load.impl; 2 | 3 | public interface IKeyBinding { 4 | 5 | boolean isActuallyPressed(); 6 | 7 | } 8 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/load/impl/IMinecraft.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.load.impl; 2 | 3 | import com.mojang.authlib.minecraft.MinecraftSessionService; 4 | import com.mojang.authlib.minecraft.UserApiService; 5 | import com.mojang.authlib.yggdrasil.YggdrasilAuthenticationService; 6 | import net.minecraft.client.util.ProfileKeys; 7 | import net.minecraft.client.util.Session; 8 | 9 | public interface IMinecraft { 10 | 11 | void setSession(Session session); 12 | 13 | void setRightClickDelayTimer(int timer); 14 | 15 | void setSessionService(MinecraftSessionService sessionService); 16 | 17 | void setProfileKeys(ProfileKeys profileKeys); 18 | 19 | UserApiService getUserApiService(); 20 | YggdrasilAuthenticationService getAuthenticationService(); 21 | } 22 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/load/impl/IPersistentProjectileEntity.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.load.impl; 2 | 3 | import net.minecraft.entity.Entity; 4 | 5 | public interface IPersistentProjectileEntity { 6 | 7 | boolean callCanHit(Entity entity); 8 | 9 | } 10 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/load/impl/IProjectile.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.load.impl; 2 | 3 | import net.minecraft.entity.Entity; 4 | 5 | public interface IProjectile { 6 | 7 | boolean callCanHit(Entity entity); 8 | 9 | } 10 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/load/impl/IShader.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.load.impl; 2 | 3 | import net.minecraft.client.gl.GlUniform; 4 | 5 | public interface IShader { 6 | GlUniform getCustomUniform(String name); 7 | } 8 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/load/impl/ISliderWidget.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.load.impl; 2 | 3 | public interface ISliderWidget { 4 | 5 | double getValue(); 6 | 7 | } 8 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/load/impl/IWorldRenderer.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.load.impl; 2 | 3 | import net.minecraft.client.gl.Framebuffer; 4 | 5 | public interface IWorldRenderer { 6 | Framebuffer getEntityOutlinesFramebuffer(); 7 | void setEntityOutlinesFramebuffer(Framebuffer framebuffer); 8 | } 9 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/load/mixin/indigo/MixinTerrainRenderContext.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.load.mixin.indigo; 2 | 3 | import me.dustin.jex.event.render.EventRenderBlock; 4 | import net.fabricmc.fabric.impl.client.indigo.renderer.render.TerrainRenderContext; 5 | import net.minecraft.block.BlockState; 6 | import net.minecraft.client.render.model.BakedModel; 7 | import net.minecraft.client.util.math.MatrixStack; 8 | import net.minecraft.util.math.BlockPos; 9 | import org.spongepowered.asm.mixin.Mixin; 10 | import org.spongepowered.asm.mixin.Pseudo; 11 | import org.spongepowered.asm.mixin.injection.At; 12 | import org.spongepowered.asm.mixin.injection.Inject; 13 | import org.spongepowered.asm.mixin.injection.callback.CallbackInfoReturnable; 14 | 15 | @Pseudo 16 | @Mixin(TerrainRenderContext.class) 17 | public class MixinTerrainRenderContext { 18 | 19 | @Inject(at = { @At("HEAD") }, method = "tessellateBlock", cancellable = true, remap = false) 20 | private void tesselateBlock(BlockState blockState, BlockPos blockPos, BakedModel model, MatrixStack matrixStack, CallbackInfoReturnable cir) { 21 | EventRenderBlock eventRenderBlock = new EventRenderBlock(blockState.getBlock()).run(); 22 | if (eventRenderBlock.isCancelled()) 23 | cir.setReturnValue(false); 24 | } 25 | 26 | } 27 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/load/mixin/minecraft/MixinAbstractClientPlayerEntity.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.load.mixin.minecraft; 2 | 3 | import me.dustin.jex.event.player.EventGetSkinTexture; 4 | import net.minecraft.client.network.AbstractClientPlayerEntity; 5 | import net.minecraft.util.Identifier; 6 | import org.spongepowered.asm.mixin.Mixin; 7 | import org.spongepowered.asm.mixin.injection.At; 8 | import org.spongepowered.asm.mixin.injection.Inject; 9 | import org.spongepowered.asm.mixin.injection.callback.CallbackInfoReturnable; 10 | 11 | @Mixin(AbstractClientPlayerEntity.class) 12 | public class MixinAbstractClientPlayerEntity { 13 | 14 | @Inject(method = "getSkinTexture", at = @At("HEAD"), cancellable = true) 15 | public void getSkinTexture(CallbackInfoReturnable cir) { 16 | EventGetSkinTexture eventGetSkinTexture = new EventGetSkinTexture((AbstractClientPlayerEntity)(Object)this, cir.getReturnValue()).run(); 17 | if (eventGetSkinTexture.isCancelled()) 18 | cir.setReturnValue(eventGetSkinTexture.getSkin()); 19 | } 20 | 21 | } 22 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/load/mixin/minecraft/MixinBackgroundRenderer.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.load.mixin.minecraft; 2 | 3 | import me.dustin.jex.event.render.EventSetupFog; 4 | import net.minecraft.client.render.BackgroundRenderer; 5 | import net.minecraft.client.render.Camera; 6 | import org.spongepowered.asm.mixin.Mixin; 7 | import org.spongepowered.asm.mixin.injection.At; 8 | import org.spongepowered.asm.mixin.injection.Inject; 9 | import org.spongepowered.asm.mixin.injection.callback.CallbackInfo; 10 | 11 | @Mixin(BackgroundRenderer.class) 12 | public class MixinBackgroundRenderer { 13 | 14 | @Inject(method = {"applyFog"}, at = @At("RETURN")) 15 | private static void applyFogModifyDensity(Camera camera, BackgroundRenderer.FogType fogType, float viewDistance, boolean thickFog, float f, CallbackInfo ci) { 16 | new EventSetupFog(camera.getSubmersionType()).run(); 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/load/mixin/minecraft/MixinBlock.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.load.mixin.minecraft; 2 | 3 | import me.dustin.jex.event.render.EventShouldDrawSide; 4 | import me.dustin.jex.helper.world.WorldHelper; 5 | import net.minecraft.block.Block; 6 | import net.minecraft.block.BlockState; 7 | import net.minecraft.util.math.BlockPos; 8 | import net.minecraft.util.math.Direction; 9 | import net.minecraft.world.BlockView; 10 | import org.spongepowered.asm.mixin.Mixin; 11 | import org.spongepowered.asm.mixin.injection.At; 12 | import org.spongepowered.asm.mixin.injection.Inject; 13 | import org.spongepowered.asm.mixin.injection.callback.CallbackInfoReturnable; 14 | 15 | @Mixin(Block.class) 16 | public class MixinBlock { 17 | 18 | @Inject(method = "shouldDrawSide", at = @At("HEAD"), cancellable = true) 19 | private static void shouldDrawSide1(BlockState state, BlockView world, BlockPos pos, Direction side, BlockPos blockPos, CallbackInfoReturnable cir) { 20 | try { 21 | EventShouldDrawSide eventShouldDrawSide = new EventShouldDrawSide(WorldHelper.INSTANCE.getBlock(pos), side, pos).run(); 22 | if (eventShouldDrawSide.isCancelled()) 23 | cir.setReturnValue(eventShouldDrawSide.isShouldDrawSide()); 24 | } catch (Exception e) { 25 | } 26 | } 27 | 28 | } 29 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/load/mixin/minecraft/MixinBufferRenderer.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.load.mixin.minecraft; 2 | 3 | import me.dustin.jex.event.render.EventRenderWithShader; 4 | import net.minecraft.client.render.BufferBuilder; 5 | import net.minecraft.client.render.BufferRenderer; 6 | import org.spongepowered.asm.mixin.Mixin; 7 | import org.spongepowered.asm.mixin.injection.At; 8 | import org.spongepowered.asm.mixin.injection.Inject; 9 | import org.spongepowered.asm.mixin.injection.callback.CallbackInfo; 10 | 11 | @Mixin(BufferRenderer.class) 12 | public class MixinBufferRenderer { 13 | @Inject(method = "drawWithShader", at = @At("HEAD"), cancellable = true) 14 | private static void drawWithShader(BufferBuilder.BuiltBuffer buffer, CallbackInfo ci) { 15 | EventRenderWithShader eventRenderWithShader = new EventRenderWithShader(buffer).run(); 16 | if (eventRenderWithShader.isCancelled()) 17 | ci.cancel(); 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/load/mixin/minecraft/MixinCamera.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.load.mixin.minecraft; 2 | 3 | import me.dustin.jex.event.render.EventClipCamera; 4 | import net.minecraft.client.render.Camera; 5 | import net.minecraft.util.hit.HitResult; 6 | import net.minecraft.util.math.Vec3d; 7 | import org.spongepowered.asm.mixin.Mixin; 8 | import org.spongepowered.asm.mixin.injection.At; 9 | import org.spongepowered.asm.mixin.injection.Inject; 10 | import org.spongepowered.asm.mixin.injection.callback.CallbackInfoReturnable; 11 | import org.spongepowered.asm.mixin.injection.callback.LocalCapture; 12 | 13 | @Mixin(Camera.class) 14 | public class MixinCamera { 15 | 16 | @Inject(method = "clipToSpace", at = @At(value = "INVOKE", target = "net/minecraft/util/math/Vec3d.distanceTo(Lnet/minecraft/util/math/Vec3d;)D"), cancellable = true, locals = LocalCapture.CAPTURE_FAILHARD) 17 | public void clipToSpace(double double_1, CallbackInfoReturnable cir, int int_1, float float_1, float float_2, float float_3, Vec3d vec3d_1, Vec3d vec3d_2, HitResult hitResult_1) { 18 | EventClipCamera eventClipCamera = new EventClipCamera().run(); 19 | if (eventClipCamera.isCancelled()) 20 | cir.setReturnValue(double_1); 21 | } 22 | 23 | } 24 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/load/mixin/minecraft/MixinChunkOcclusionDataBuilder.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.load.mixin.minecraft; 2 | 3 | import me.dustin.jex.event.render.EventMarkChunkClosed; 4 | import net.minecraft.client.render.chunk.ChunkOcclusionDataBuilder; 5 | import net.minecraft.util.math.BlockPos; 6 | import org.spongepowered.asm.mixin.Mixin; 7 | import org.spongepowered.asm.mixin.injection.At; 8 | import org.spongepowered.asm.mixin.injection.Inject; 9 | import org.spongepowered.asm.mixin.injection.callback.CallbackInfo; 10 | 11 | @Mixin(ChunkOcclusionDataBuilder.class) 12 | public class MixinChunkOcclusionDataBuilder { 13 | 14 | @Inject(method = "markClosed", at = @At("HEAD"), cancellable = true) 15 | public void markClosed(BlockPos blockPos, CallbackInfo ci) { 16 | try { 17 | EventMarkChunkClosed eventMarkChunkClosed = new EventMarkChunkClosed().run(); 18 | if (eventMarkChunkClosed.isCancelled()) 19 | ci.cancel(); 20 | } catch (Exception e) { 21 | e.printStackTrace(); 22 | } 23 | } 24 | 25 | } 26 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/load/mixin/minecraft/MixinClickableWidget.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.load.mixin.minecraft; 2 | 3 | import me.dustin.jex.event.render.EventRenderWidget; 4 | import net.minecraft.client.gui.widget.ClickableWidget; 5 | import net.minecraft.client.util.math.MatrixStack; 6 | import org.spongepowered.asm.mixin.Mixin; 7 | import org.spongepowered.asm.mixin.injection.At; 8 | import org.spongepowered.asm.mixin.injection.Inject; 9 | import org.spongepowered.asm.mixin.injection.callback.CallbackInfo; 10 | 11 | @Mixin(ClickableWidget.class) 12 | public class MixinClickableWidget { 13 | 14 | @Inject(method = "renderButton", at = @At("HEAD"), cancellable = true) 15 | public void renderButton1(MatrixStack matrices, int mouseX, int mouseY, float delta, CallbackInfo ci) { 16 | EventRenderWidget eventRenderWidget = new EventRenderWidget((ClickableWidget)(Object)this, matrices).run(); 17 | if (eventRenderWidget.isCancelled()) 18 | ci.cancel(); 19 | } 20 | 21 | } 22 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/load/mixin/minecraft/MixinClientWorld.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.load.mixin.minecraft; 2 | 3 | import me.dustin.jex.event.world.EventSpawnEntity; 4 | import net.minecraft.client.world.ClientWorld; 5 | import net.minecraft.entity.Entity; 6 | import org.spongepowered.asm.mixin.Mixin; 7 | import org.spongepowered.asm.mixin.injection.At; 8 | import org.spongepowered.asm.mixin.injection.Inject; 9 | import org.spongepowered.asm.mixin.injection.callback.CallbackInfo; 10 | 11 | @Mixin(ClientWorld.class) 12 | public class MixinClientWorld { 13 | 14 | @Inject(method = "addEntityPrivate", at = @At("HEAD")) 15 | public void addEntityPrivate1(int id, Entity entity, CallbackInfo ci) { 16 | new EventSpawnEntity(entity).run(); 17 | } 18 | 19 | } 20 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/load/mixin/minecraft/MixinConnectScreen.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.load.mixin.minecraft; 2 | 3 | import me.dustin.jex.event.packet.EventConnect; 4 | import net.minecraft.client.MinecraftClient; 5 | import net.minecraft.client.gui.screen.ConnectScreen; 6 | import net.minecraft.client.network.ServerAddress; 7 | import org.spongepowered.asm.mixin.Mixin; 8 | import org.spongepowered.asm.mixin.injection.At; 9 | import org.spongepowered.asm.mixin.injection.Inject; 10 | import org.spongepowered.asm.mixin.injection.callback.CallbackInfo; 11 | 12 | @Mixin(ConnectScreen.class) 13 | public class MixinConnectScreen { 14 | 15 | @Inject(method = "connect(Lnet/minecraft/client/MinecraftClient;Lnet/minecraft/client/network/ServerAddress;)V", at = @At("HEAD"), cancellable = true) 16 | public void onConnect(MinecraftClient client, ServerAddress address, CallbackInfo ci) { 17 | EventConnect eventConnect = new EventConnect(address).run(); 18 | if (eventConnect.isCancelled()) 19 | ci.cancel(); 20 | } 21 | 22 | } 23 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/load/mixin/minecraft/MixinFluidState.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.load.mixin.minecraft; 2 | 3 | import me.dustin.jex.event.world.EventWaterVelocity; 4 | import net.minecraft.fluid.FluidState; 5 | import net.minecraft.util.math.BlockPos; 6 | import net.minecraft.util.math.Vec3d; 7 | import net.minecraft.world.BlockView; 8 | import org.spongepowered.asm.mixin.Mixin; 9 | import org.spongepowered.asm.mixin.injection.At; 10 | import org.spongepowered.asm.mixin.injection.Inject; 11 | import org.spongepowered.asm.mixin.injection.callback.CallbackInfoReturnable; 12 | 13 | @Mixin(FluidState.class) 14 | public class MixinFluidState { 15 | 16 | @Inject(method = "getVelocity", at = @At("HEAD"), cancellable = true) 17 | public void getVelocity(BlockView world, BlockPos pos, CallbackInfoReturnable cir) { 18 | if (((EventWaterVelocity) new EventWaterVelocity().run()).isCancelled()) 19 | cir.setReturnValue(Vec3d.ZERO); 20 | } 21 | 22 | } 23 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/load/mixin/minecraft/MixinFramebuffer.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.load.mixin.minecraft; 2 | 3 | import me.dustin.jex.load.impl.IFrameBuffer; 4 | import net.minecraft.client.gl.Framebuffer; 5 | import org.spongepowered.asm.mixin.Mixin; 6 | import org.spongepowered.asm.mixin.Shadow; 7 | 8 | @Mixin(Framebuffer.class) 9 | public class MixinFramebuffer implements IFrameBuffer { 10 | @Shadow 11 | private int depthAttachment; 12 | 13 | @Override 14 | public void setDepthAttachment(int depth) { 15 | this.depthAttachment = depth; 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/load/mixin/minecraft/MixinItemEntityRenderer.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.load.mixin.minecraft; 2 | 3 | import me.dustin.jex.event.render.EventRotateItemEntity; 4 | import net.minecraft.client.render.VertexConsumerProvider; 5 | import net.minecraft.client.render.entity.ItemEntityRenderer; 6 | import net.minecraft.client.util.math.MatrixStack; 7 | import net.minecraft.entity.ItemEntity; 8 | import org.spongepowered.asm.mixin.Mixin; 9 | import org.spongepowered.asm.mixin.injection.At; 10 | import org.spongepowered.asm.mixin.injection.Inject; 11 | import org.spongepowered.asm.mixin.injection.callback.CallbackInfo; 12 | 13 | @Mixin(ItemEntityRenderer.class) 14 | public class MixinItemEntityRenderer { 15 | 16 | @Inject(method = "render(Lnet/minecraft/entity/ItemEntity;FFLnet/minecraft/client/util/math/MatrixStack;Lnet/minecraft/client/render/VertexConsumerProvider;I)V", at = @At(value = "INVOKE", target = "net/minecraft/util/math/random/Random.setSeed(J)V ")) 17 | public void renderItemEntity(ItemEntity itemEntity, float f, float g, MatrixStack matrixStack, VertexConsumerProvider vertexConsumerProvider, int i, CallbackInfo ci) { 18 | new EventRotateItemEntity(itemEntity, matrixStack, g).run(); 19 | } 20 | 21 | } 22 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/load/mixin/minecraft/MixinKeybinding.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.load.mixin.minecraft; 2 | 3 | import me.dustin.jex.helper.misc.Wrapper; 4 | import me.dustin.jex.load.impl.IKeyBinding; 5 | import net.minecraft.client.option.KeyBinding; 6 | import net.minecraft.client.util.InputUtil; 7 | import org.spongepowered.asm.mixin.Mixin; 8 | import org.spongepowered.asm.mixin.Shadow; 9 | 10 | @Mixin(KeyBinding.class) 11 | public class MixinKeybinding implements IKeyBinding { 12 | 13 | @Shadow private InputUtil.Key boundKey; 14 | 15 | @Override 16 | public boolean isActuallyPressed() { 17 | long handle = Wrapper.INSTANCE.getWindow().getHandle(); 18 | int code = this.boundKey.getCode(); 19 | return InputUtil.isKeyPressed(handle, code); 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/load/mixin/minecraft/MixinKeyboard.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.load.mixin.minecraft; 2 | 3 | import me.dustin.jex.event.misc.EventKeyPressed; 4 | import me.dustin.jex.helper.misc.Wrapper; 5 | import net.minecraft.client.Keyboard; 6 | import org.spongepowered.asm.mixin.Mixin; 7 | import org.spongepowered.asm.mixin.injection.At; 8 | import org.spongepowered.asm.mixin.injection.Inject; 9 | import org.spongepowered.asm.mixin.injection.callback.CallbackInfo; 10 | 11 | @Mixin(Keyboard.class) 12 | public class MixinKeyboard { 13 | @Inject(method = "onKey", at = @At("HEAD"), cancellable = true) 14 | public void onKeyListener(long window, int key, int scancode, int action, int modifiers, CallbackInfo ci) { 15 | if (action == 1) { 16 | EventKeyPressed eventKeyPressed = new EventKeyPressed(key, scancode, Wrapper.INSTANCE.getMinecraft().currentScreen == null ? EventKeyPressed.PressType.IN_GAME : EventKeyPressed.PressType.IN_MENU).run(); 17 | if (eventKeyPressed.isCancelled()) 18 | ci.cancel(); 19 | } 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/load/mixin/minecraft/MixinLivingEntity.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.load.mixin.minecraft; 2 | 3 | import me.dustin.jex.event.player.EventSetPlayerHealth; 4 | import me.dustin.jex.helper.misc.Wrapper; 5 | import net.minecraft.entity.LivingEntity; 6 | import org.spongepowered.asm.mixin.Mixin; 7 | import org.spongepowered.asm.mixin.Shadow; 8 | import org.spongepowered.asm.mixin.injection.At; 9 | import org.spongepowered.asm.mixin.injection.Inject; 10 | import org.spongepowered.asm.mixin.injection.callback.CallbackInfo; 11 | 12 | @Mixin(LivingEntity.class) 13 | public abstract class MixinLivingEntity { 14 | 15 | @Shadow public abstract void setHealth(float health); 16 | 17 | @Shadow public abstract float getHealth(); 18 | 19 | @Inject(method = "setHealth", at = @At("HEAD"), cancellable = true) 20 | public void checkHealth(float health, CallbackInfo ci) { 21 | if (getThis() != Wrapper.INSTANCE.getLocalPlayer()) 22 | return; 23 | EventSetPlayerHealth eventSetPlayerHealth = new EventSetPlayerHealth(health).run(); 24 | if (eventSetPlayerHealth.isCancelled()) { 25 | ci.cancel(); 26 | if (eventSetPlayerHealth.getHealth() != health) 27 | setHealth(eventSetPlayerHealth.getHealth()); 28 | } 29 | } 30 | 31 | private LivingEntity getThis() { 32 | return (LivingEntity) (Object)this; 33 | } 34 | 35 | } 36 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/load/mixin/minecraft/MixinLlamaEntity.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.load.mixin.minecraft; 2 | 3 | import me.dustin.jex.event.misc.EventControlLlama; 4 | import net.minecraft.entity.passive.LlamaEntity; 5 | import org.spongepowered.asm.mixin.Mixin; 6 | import org.spongepowered.asm.mixin.injection.At; 7 | import org.spongepowered.asm.mixin.injection.Inject; 8 | import org.spongepowered.asm.mixin.injection.callback.CallbackInfoReturnable; 9 | 10 | @Mixin(LlamaEntity.class) 11 | public class MixinLlamaEntity { 12 | 13 | @Inject(method = "canBeSaddled", at = @At("HEAD"), cancellable = true) 14 | public void canBeControlledByRider(CallbackInfoReturnable ci) { 15 | EventControlLlama eventControlLlama = new EventControlLlama().run(); 16 | if (eventControlLlama.isCancelled()) 17 | ci.setReturnValue(eventControlLlama.isControl()); 18 | } 19 | 20 | } 21 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/load/mixin/minecraft/MixinOptionsScreen.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.load.mixin.minecraft; 2 | 3 | import me.dustin.jex.gui.jex.JexOptionsScreen; 4 | import me.dustin.jex.helper.misc.Wrapper; 5 | import net.minecraft.client.gui.screen.Screen; 6 | import net.minecraft.client.gui.screen.option.OptionsScreen; 7 | import net.minecraft.client.gui.widget.ButtonWidget; 8 | import net.minecraft.text.Text; 9 | import net.minecraft.util.Formatting; 10 | import org.spongepowered.asm.mixin.Mixin; 11 | import org.spongepowered.asm.mixin.injection.At; 12 | import org.spongepowered.asm.mixin.injection.Inject; 13 | import org.spongepowered.asm.mixin.injection.callback.CallbackInfo; 14 | 15 | @Mixin(OptionsScreen.class) 16 | public class MixinOptionsScreen extends Screen { 17 | 18 | protected MixinOptionsScreen(Text title) { 19 | super(title); 20 | } 21 | 22 | @Inject(method = "init", at = @At("RETURN")) 23 | public void init(CallbackInfo ci) { 24 | this.addDrawableChild(new ButtonWidget(this.width / 2 - 100, this.height / 6 + 143, 200, 20, Text.of(Formatting.AQUA + "Jex Options"),button -> { 25 | Wrapper.INSTANCE.getMinecraft().setScreen(new JexOptionsScreen()); 26 | })); 27 | } 28 | 29 | } 30 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/load/mixin/minecraft/MixinPersistentProjectileEntity.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.load.mixin.minecraft; 2 | 3 | import me.dustin.jex.load.impl.IPersistentProjectileEntity; 4 | import net.minecraft.entity.Entity; 5 | import net.minecraft.entity.projectile.PersistentProjectileEntity; 6 | import org.spongepowered.asm.mixin.Mixin; 7 | import org.spongepowered.asm.mixin.Shadow; 8 | 9 | @Mixin(PersistentProjectileEntity.class) 10 | public abstract class MixinPersistentProjectileEntity implements IPersistentProjectileEntity { 11 | 12 | @Shadow protected abstract boolean canHit(Entity entity); 13 | 14 | @Override 15 | public boolean callCanHit(Entity entity) { 16 | return this.canHit(entity); 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/load/mixin/minecraft/MixinProjectileEntity.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.load.mixin.minecraft; 2 | 3 | import me.dustin.jex.load.impl.IProjectile; 4 | import net.minecraft.entity.Entity; 5 | import net.minecraft.entity.projectile.ProjectileEntity; 6 | import org.spongepowered.asm.mixin.Mixin; 7 | import org.spongepowered.asm.mixin.Shadow; 8 | 9 | @Mixin(ProjectileEntity.class) 10 | public abstract class MixinProjectileEntity implements IProjectile { 11 | 12 | 13 | @Shadow protected abstract boolean canHit(Entity entity); 14 | 15 | @Override 16 | public boolean callCanHit(Entity entity) { 17 | return this.canHit(entity); 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/load/mixin/minecraft/MixinRenderLayers.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.load.mixin.minecraft; 2 | 3 | import me.dustin.jex.event.render.EventGetRenderType; 4 | import net.minecraft.block.BlockState; 5 | import net.minecraft.client.render.RenderLayer; 6 | import net.minecraft.client.render.RenderLayers; 7 | import org.spongepowered.asm.mixin.Mixin; 8 | import org.spongepowered.asm.mixin.injection.At; 9 | import org.spongepowered.asm.mixin.injection.Inject; 10 | import org.spongepowered.asm.mixin.injection.callback.CallbackInfoReturnable; 11 | 12 | @Mixin(RenderLayers.class) 13 | public class MixinRenderLayers { 14 | @Inject(method = "getBlockLayer", at = @At("HEAD"), cancellable = true) 15 | private static void getBlockLayer(BlockState state, CallbackInfoReturnable cir) { 16 | EventGetRenderType eventGetRenderType = new EventGetRenderType(state, cir.getReturnValue()).run(); 17 | if (eventGetRenderType.isCancelled()) { 18 | cir.setReturnValue(eventGetRenderType.getRenderType()); 19 | cir.cancel(); 20 | } 21 | } 22 | } 23 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/load/mixin/minecraft/MixinRenderTickCounter.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.load.mixin.minecraft; 2 | 3 | import me.dustin.jex.event.misc.EventRenderTick; 4 | import net.minecraft.client.render.RenderTickCounter; 5 | import org.spongepowered.asm.mixin.Final; 6 | import org.spongepowered.asm.mixin.Mixin; 7 | import org.spongepowered.asm.mixin.Mutable; 8 | import org.spongepowered.asm.mixin.Shadow; 9 | import org.spongepowered.asm.mixin.injection.At; 10 | import org.spongepowered.asm.mixin.injection.Inject; 11 | import org.spongepowered.asm.mixin.injection.callback.CallbackInfoReturnable; 12 | 13 | @Mixin(RenderTickCounter.class) 14 | public class MixinRenderTickCounter { 15 | @Mutable 16 | @Shadow @Final private float tickTime; 17 | 18 | @Inject(method = "beginRenderTick", at = @At("HEAD")) 19 | public void beingRenderTick(long timeMillis, CallbackInfoReturnable cir) { 20 | this.tickTime = ((EventRenderTick)new EventRenderTick(this.tickTime).run()).timeScale; 21 | } 22 | } 23 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/load/mixin/minecraft/MixinServerInfo.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.load.mixin.minecraft; 2 | 3 | import me.dustin.jex.event.chat.EventShouldPreviewChat; 4 | import net.minecraft.client.network.ServerInfo; 5 | import org.jetbrains.annotations.Nullable; 6 | import org.spongepowered.asm.mixin.Mixin; 7 | import org.spongepowered.asm.mixin.Shadow; 8 | import org.spongepowered.asm.mixin.injection.At; 9 | import org.spongepowered.asm.mixin.injection.Inject; 10 | import org.spongepowered.asm.mixin.injection.callback.CallbackInfoReturnable; 11 | 12 | @Mixin(ServerInfo.class) 13 | public class MixinServerInfo { 14 | 15 | @Shadow @Nullable private ServerInfo.@Nullable ChatPreview chatPreview; 16 | 17 | @Shadow private boolean temporaryChatPreviewState; 18 | 19 | @Inject(method = "shouldPreviewChat", at = @At("HEAD"), cancellable = true) 20 | public void shouldPreviewChat(CallbackInfoReturnable cir) { 21 | EventShouldPreviewChat eventShouldPreviewChat = new EventShouldPreviewChat(this.temporaryChatPreviewState && this.chatPreview != null).run(); 22 | if (eventShouldPreviewChat.isCancelled()) 23 | cir.setReturnValue(eventShouldPreviewChat.isEnabled()); 24 | } 25 | 26 | } 27 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/load/mixin/minecraft/MixinServerList.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.load.mixin.minecraft; 2 | 3 | import net.minecraft.client.network.ServerInfo; 4 | import net.minecraft.client.option.ServerList; 5 | import org.spongepowered.asm.mixin.Final; 6 | import org.spongepowered.asm.mixin.Mixin; 7 | import org.spongepowered.asm.mixin.Shadow; 8 | import org.spongepowered.asm.mixin.injection.At; 9 | import org.spongepowered.asm.mixin.injection.Inject; 10 | import org.spongepowered.asm.mixin.injection.callback.CallbackInfo; 11 | 12 | import java.util.List; 13 | 14 | @Mixin(ServerList.class) 15 | public class MixinServerList { 16 | 17 | @Shadow @Final private List servers; 18 | 19 | @Inject(method = "loadFile", at = @At("RETURN")) 20 | public void loadFile1(CallbackInfo ci) { 21 | //TODO: maybe add this back at some point 22 | for (ServerInfo server : this.servers) { 23 | if (server.address.equalsIgnoreCase("play.jexclient.com")) 24 | return; 25 | } 26 | this.servers.add(new ServerInfo("Jex Anarchy Server", "play.jexclient.com", false)); 27 | } 28 | 29 | } 30 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/load/mixin/minecraft/MixinShader.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.load.mixin.minecraft; 2 | 3 | import me.dustin.jex.event.render.EventBindShader; 4 | import net.minecraft.client.render.Shader; 5 | import org.spongepowered.asm.mixin.Mixin; 6 | import org.spongepowered.asm.mixin.injection.At; 7 | import org.spongepowered.asm.mixin.injection.Inject; 8 | import org.spongepowered.asm.mixin.injection.callback.CallbackInfo; 9 | 10 | @Mixin(Shader.class) 11 | public class MixinShader { 12 | 13 | @Inject(method = "bind", at = @At("HEAD"), cancellable = true) 14 | public void bindPre(CallbackInfo ci) { 15 | EventBindShader eventBindShader = new EventBindShader((Shader)(Object)this, EventBindShader.Mode.PRE).run(); 16 | if (eventBindShader.isCancelled()) 17 | ci.cancel(); 18 | } 19 | 20 | @Inject(method = "bind", at = @At("RETURN")) 21 | public void bindPost(CallbackInfo ci) { 22 | new EventBindShader((Shader)(Object)this, EventBindShader.Mode.POST).run(); 23 | } 24 | 25 | } 26 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/load/mixin/minecraft/MixinSliderWidget.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.load.mixin.minecraft; 2 | 3 | import me.dustin.jex.load.impl.ISliderWidget; 4 | import net.minecraft.client.gui.widget.SliderWidget; 5 | import org.spongepowered.asm.mixin.Mixin; 6 | import org.spongepowered.asm.mixin.Shadow; 7 | 8 | @Mixin(SliderWidget.class) 9 | public class MixinSliderWidget implements ISliderWidget { 10 | 11 | @Shadow protected double value; 12 | 13 | @Override 14 | public double getValue() { 15 | return this.value; 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/load/mixin/minecraft/MixinSoundSystem.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.load.mixin.minecraft; 2 | 3 | import me.dustin.jex.event.world.EventPlaySound; 4 | import net.minecraft.client.sound.SoundInstance; 5 | import net.minecraft.client.sound.SoundSystem; 6 | import org.spongepowered.asm.mixin.Mixin; 7 | import org.spongepowered.asm.mixin.injection.At; 8 | import org.spongepowered.asm.mixin.injection.Inject; 9 | import org.spongepowered.asm.mixin.injection.callback.CallbackInfo; 10 | 11 | @Mixin(SoundSystem.class) 12 | public class MixinSoundSystem { 13 | 14 | @Inject(method = "play(Lnet/minecraft/client/sound/SoundInstance;)V", at = @At("HEAD"), cancellable = true) 15 | private void onPlayPre(SoundInstance soundInstance, CallbackInfo ci) { 16 | EventPlaySound eventPlaySound = new EventPlaySound(EventPlaySound.Mode.PRE, soundInstance.getId()).run(); 17 | if (eventPlaySound.isCancelled()) 18 | ci.cancel(); 19 | } 20 | 21 | @Inject(method = "play(Lnet/minecraft/client/sound/SoundInstance;)V", at = @At("RETURN"), cancellable = true) 22 | private void onPlayPost(SoundInstance soundInstance, CallbackInfo ci) { 23 | EventPlaySound eventPlaySound = new EventPlaySound(EventPlaySound.Mode.POST, soundInstance.getId()).run(); 24 | if (eventPlaySound.isCancelled()) 25 | ci.cancel(); 26 | } 27 | } -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/load/mixin/minecraft/MixinSplashOverlay.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.load.mixin.minecraft; 2 | 3 | import me.dustin.jex.JexClient; 4 | import me.dustin.jex.event.misc.EventGameFinishedLoading; 5 | import net.minecraft.client.MinecraftClient; 6 | import net.minecraft.client.gui.screen.SplashOverlay; 7 | import org.spongepowered.asm.mixin.Mixin; 8 | import org.spongepowered.asm.mixin.injection.At; 9 | import org.spongepowered.asm.mixin.injection.Inject; 10 | import org.spongepowered.asm.mixin.injection.callback.CallbackInfo; 11 | 12 | @Mixin(SplashOverlay.class) 13 | public class MixinSplashOverlay { 14 | @Inject(method = "init", at = @At("HEAD")) 15 | private static void initClient(MinecraftClient client, CallbackInfo ci) { 16 | JexClient.INSTANCE.initializeClient(); 17 | } 18 | 19 | @Inject(method = "render", at = @At(value = "INVOKE", target = "Lnet/minecraft/client/gui/screen/Screen;init(Lnet/minecraft/client/MinecraftClient;II)V")) 20 | public void resourcesFinishedLoading(CallbackInfo ci) { 21 | new EventGameFinishedLoading().run(); 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/load/mixin/minecraft/MixinWorldChunk.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.load.mixin.minecraft; 2 | 3 | import me.dustin.jex.helper.world.WorldHelper; 4 | import net.minecraft.block.entity.BlockEntity; 5 | import net.minecraft.util.math.BlockPos; 6 | import net.minecraft.world.chunk.WorldChunk; 7 | import org.spongepowered.asm.mixin.Mixin; 8 | import org.spongepowered.asm.mixin.injection.At; 9 | import org.spongepowered.asm.mixin.injection.Inject; 10 | import org.spongepowered.asm.mixin.injection.callback.CallbackInfo; 11 | 12 | @Mixin(WorldChunk.class) 13 | public class MixinWorldChunk { 14 | 15 | @Inject(method = "addBlockEntity", at = @At("HEAD")) 16 | public void addBlockEntity(BlockEntity blockEntity, CallbackInfo ci) { 17 | BlockPos blockPos = blockEntity.getPos(); 18 | if (WorldHelper.INSTANCE.getBlockEntityList().containsKey(blockPos)) { 19 | WorldHelper.INSTANCE.getBlockEntityList().replace(blockPos, blockEntity); 20 | } else { 21 | WorldHelper.INSTANCE.getBlockEntityList().put(blockPos, blockEntity); 22 | } 23 | } 24 | 25 | @Inject(method = "removeBlockEntity", at = @At("HEAD")) 26 | public void removeBlockEntity(BlockPos blockPos, CallbackInfo ci) { 27 | WorldHelper.INSTANCE.getBlockEntityList().remove(blockPos); 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/load/mixin/sodium/MixinBlockOcclusionCache.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.load.mixin.sodium; 2 | 3 | import me.dustin.jex.event.render.EventShouldDrawSide; 4 | import me.jellysquid.mods.sodium.client.render.occlusion.BlockOcclusionCache; 5 | import net.minecraft.block.BlockState; 6 | import net.minecraft.util.math.BlockPos; 7 | import net.minecraft.util.math.Direction; 8 | import net.minecraft.world.BlockView; 9 | import org.spongepowered.asm.mixin.Mixin; 10 | import org.spongepowered.asm.mixin.Pseudo; 11 | import org.spongepowered.asm.mixin.injection.At; 12 | import org.spongepowered.asm.mixin.injection.Inject; 13 | import org.spongepowered.asm.mixin.injection.callback.CallbackInfoReturnable; 14 | 15 | @Pseudo 16 | @Mixin(BlockOcclusionCache.class) 17 | public class MixinBlockOcclusionCache { 18 | 19 | @Inject(method = "shouldDrawSide", at = @At("HEAD"), cancellable = true, remap = false) 20 | public void shouldDrawSide1(BlockState selfState, BlockView view, BlockPos pos, Direction facing, CallbackInfoReturnable cir) { 21 | EventShouldDrawSide eventShouldDrawSide = new EventShouldDrawSide(selfState.getBlock(), facing, pos).run(); 22 | if (eventShouldDrawSide.isCancelled()) { 23 | cir.setReturnValue(eventShouldDrawSide.isShouldDrawSide()); 24 | } 25 | } 26 | 27 | } 28 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/load/mixin/sodium/MixinGlProgram.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.load.mixin.sodium; 2 | 3 | import me.jellysquid.mods.sodium.client.gl.shader.GlProgram; 4 | import me.jellysquid.mods.sodium.client.gl.shader.uniform.GlUniform; 5 | import org.spongepowered.asm.mixin.Mixin; 6 | import org.spongepowered.asm.mixin.injection.At; 7 | import org.spongepowered.asm.mixin.injection.Inject; 8 | import org.spongepowered.asm.mixin.injection.callback.CallbackInfoReturnable; 9 | import org.spongepowered.asm.mixin.injection.callback.LocalCapture; 10 | 11 | import java.util.function.IntFunction; 12 | 13 | @Mixin(GlProgram.class) 14 | public class MixinGlProgram { 15 | 16 | @Inject(method = "bindUniform", at = @At(value = "NEW", target = "java/lang/NullPointerException"), cancellable = true, locals = LocalCapture.CAPTURE_FAILHARD) 17 | public void bindUniform(String name, IntFunction> factory, CallbackInfoReturnable> cir, int index) { 18 | cir.setReturnValue(factory.apply(index)); 19 | } 20 | 21 | } 22 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/load/mixin/sodium/MixinShaderChunkRenderer.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.load.mixin.sodium; 2 | 3 | import me.jellysquid.mods.sodium.client.render.chunk.ShaderChunkRenderer; 4 | import org.spongepowered.asm.mixin.Mixin; 5 | import org.spongepowered.asm.mixin.injection.At; 6 | import org.spongepowered.asm.mixin.injection.ModifyArg; 7 | 8 | @Mixin(value = ShaderChunkRenderer.class, remap = false) 9 | public class MixinShaderChunkRenderer { 10 | @ModifyArg(method = "compileProgram", at = @At(value = "INVOKE", target = "me/jellysquid/mods/sodium/client/render/chunk/ShaderChunkRenderer.createShader(Ljava/lang/String;Lme/jellysquid/mods/sodium/client/render/chunk/shader/ChunkShaderOptions;)Lme/jellysquid/mods/sodium/client/gl/shader/GlProgram;"), index = 0) 11 | public String getPath(String path) { 12 | return "opacity_xray"; 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /src/main/java/me/dustin/jex/load/mixin/sodium/MixinShaderLoader.java: -------------------------------------------------------------------------------- 1 | package me.dustin.jex.load.mixin.sodium; 2 | 3 | import me.dustin.jex.JexClient; 4 | import me.jellysquid.mods.sodium.client.gl.shader.ShaderLoader; 5 | import net.minecraft.util.Identifier; 6 | import org.spongepowered.asm.mixin.Mixin; 7 | import org.spongepowered.asm.mixin.injection.At; 8 | import org.spongepowered.asm.mixin.injection.Inject; 9 | import org.spongepowered.asm.mixin.injection.callback.CallbackInfoReturnable; 10 | 11 | @Mixin(value = ShaderLoader.class, remap = false) 12 | public class MixinShaderLoader { 13 | 14 | @Inject(method = "getShaderSource", at = @At("RETURN"), cancellable = true) 15 | private static void getShaderSource(Identifier name, CallbackInfoReturnable cir) { 16 | /*if (name.getPath().contains(".vsh")) { 17 | JexClient.INSTANCE.getLogger().info(name.getPath()); 18 | JexClient.INSTANCE.getLogger().info(cir.getReturnValue()); 19 | }*/ 20 | } 21 | 22 | } 23 | -------------------------------------------------------------------------------- /src/main/resources/assets/jex/comic/boom.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DustinRepo/JexClient/017ce1229fc446f66eee5c564ce28af142368f3d/src/main/resources/assets/jex/comic/boom.png -------------------------------------------------------------------------------- /src/main/resources/assets/jex/comic/kapow.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DustinRepo/JexClient/017ce1229fc446f66eee5c564ce28af142368f3d/src/main/resources/assets/jex/comic/kapow.png -------------------------------------------------------------------------------- /src/main/resources/assets/jex/comic/pow.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DustinRepo/JexClient/017ce1229fc446f66eee5c564ce28af142368f3d/src/main/resources/assets/jex/comic/pow.png -------------------------------------------------------------------------------- /src/main/resources/assets/jex/comic/wham.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DustinRepo/JexClient/017ce1229fc446f66eee5c564ce28af142368f3d/src/main/resources/assets/jex/comic/wham.png -------------------------------------------------------------------------------- /src/main/resources/assets/jex/gui/click/cog.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DustinRepo/JexClient/017ce1229fc446f66eee5c564ce28af142368f3d/src/main/resources/assets/jex/gui/click/cog.png -------------------------------------------------------------------------------- /src/main/resources/assets/jex/gui/click/colorslider.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DustinRepo/JexClient/017ce1229fc446f66eee5c564ce28af142368f3d/src/main/resources/assets/jex/gui/click/colorslider.png -------------------------------------------------------------------------------- /src/main/resources/assets/jex/gui/click/pin.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DustinRepo/JexClient/017ce1229fc446f66eee5c564ce28af142368f3d/src/main/resources/assets/jex/gui/click/pin.png -------------------------------------------------------------------------------- /src/main/resources/assets/jex/gui/click/visible.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DustinRepo/JexClient/017ce1229fc446f66eee5c564ce28af142368f3d/src/main/resources/assets/jex/gui/click/visible.png -------------------------------------------------------------------------------- /src/main/resources/assets/jex/gui/jex/folder.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DustinRepo/JexClient/017ce1229fc446f66eee5c564ce28af142368f3d/src/main/resources/assets/jex/gui/jex/folder.png -------------------------------------------------------------------------------- /src/main/resources/assets/jex/gui/jex/hats.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DustinRepo/JexClient/017ce1229fc446f66eee5c564ce28af142368f3d/src/main/resources/assets/jex/gui/jex/hats.png -------------------------------------------------------------------------------- /src/main/resources/assets/jex/gui/jex/jex-logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DustinRepo/JexClient/017ce1229fc446f66eee5c564ce28af142368f3d/src/main/resources/assets/jex/gui/jex/jex-logo.png -------------------------------------------------------------------------------- /src/main/resources/assets/jex/gui/mc/shulker_background.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DustinRepo/JexClient/017ce1229fc446f66eee5c564ce28af142368f3d/src/main/resources/assets/jex/gui/mc/shulker_background.png -------------------------------------------------------------------------------- /src/main/resources/assets/jex/hats/halo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DustinRepo/JexClient/017ce1229fc446f66eee5c564ce28af142368f3d/src/main/resources/assets/jex/hats/halo.png -------------------------------------------------------------------------------- /src/main/resources/assets/jex/hats/mohawk.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DustinRepo/JexClient/017ce1229fc446f66eee5c564ce28af142368f3d/src/main/resources/assets/jex/hats/mohawk.png -------------------------------------------------------------------------------- /src/main/resources/assets/jex/hats/santa.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DustinRepo/JexClient/017ce1229fc446f66eee5c564ce28af142368f3d/src/main/resources/assets/jex/hats/santa.png -------------------------------------------------------------------------------- /src/main/resources/assets/jex/hats/techno.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DustinRepo/JexClient/017ce1229fc446f66eee5c564ce28af142368f3d/src/main/resources/assets/jex/hats/techno.png -------------------------------------------------------------------------------- /src/main/resources/assets/jex/hats/top_hat.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DustinRepo/JexClient/017ce1229fc446f66eee5c564ce28af142368f3d/src/main/resources/assets/jex/hats/top_hat.png -------------------------------------------------------------------------------- /src/main/resources/assets/jex/icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DustinRepo/JexClient/017ce1229fc446f66eee5c564ce28af142368f3d/src/main/resources/assets/jex/icon.png -------------------------------------------------------------------------------- /src/main/resources/assets/jex/legs/lightning_rod.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DustinRepo/JexClient/017ce1229fc446f66eee5c564ce28af142368f3d/src/main/resources/assets/jex/legs/lightning_rod.png -------------------------------------------------------------------------------- /src/main/resources/assets/jex/legs/robot.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DustinRepo/JexClient/017ce1229fc446f66eee5c564ce28af142368f3d/src/main/resources/assets/jex/legs/robot.png -------------------------------------------------------------------------------- /src/main/resources/assets/jex/legs/stick.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DustinRepo/JexClient/017ce1229fc446f66eee5c564ce28af142368f3d/src/main/resources/assets/jex/legs/stick.png -------------------------------------------------------------------------------- /src/main/resources/assets/jex/shaders/blur.fsh: -------------------------------------------------------------------------------- 1 | #version 330 core 2 | 3 | uniform sampler2D Sampler; 4 | 5 | in vec2 TexCoord; 6 | in vec2 Texel; 7 | 8 | uniform vec2 Size; 9 | 10 | uniform vec2 BlurDir; 11 | uniform float Radius; 12 | 13 | out vec4 fragColor; 14 | 15 | void main() { 16 | vec4 blurred = vec4(0.0); 17 | float totalStrength = 0.0; 18 | float totalAlpha = 0.0; 19 | float totalSamples = 0.0; 20 | for(float r = -Radius; r <= Radius; r += 1.0) { 21 | vec4 sampleValue = texture(Sampler, TexCoord + Texel * r * BlurDir); 22 | 23 | // Accumulate average alpha 24 | float a = max(0.1F, sampleValue.a); 25 | totalAlpha = totalAlpha + a; 26 | totalSamples = totalSamples + 1.0; 27 | 28 | // Accumulate smoothed blur 29 | float strength = 1.0 - abs(r / Radius); 30 | totalStrength = totalStrength + strength; 31 | blurred = blurred + sampleValue; 32 | } 33 | fragColor = vec4(blurred.rgb / (Radius * 2.0 + 1.0), totalAlpha); 34 | } 35 | -------------------------------------------------------------------------------- /src/main/resources/assets/jex/shaders/blur.vsh: -------------------------------------------------------------------------------- 1 | #version 330 core 2 | 3 | layout (location = 0) in vec3 Position; 4 | 5 | uniform mat4 Projection; 6 | uniform vec2 Size; 7 | 8 | out vec2 TexCoord; 9 | out vec2 Texel; 10 | 11 | void main() { 12 | vec4 outPos = Projection * vec4(Position.xy, 0.0, 1.0); 13 | gl_Position = vec4(outPos.xy, 0.2, 1.0); 14 | Texel = 1.0 / Size; 15 | TexCoord = Position.xy / Size; 16 | } -------------------------------------------------------------------------------- /src/main/resources/assets/jex/shaders/opacity_xray.fsh: -------------------------------------------------------------------------------- 1 | #version 330 core 2 | 3 | uniform sampler2D Sampler; 4 | 5 | uniform vec4 ColorModulator; 6 | uniform float FogStart; 7 | uniform float FogEnd; 8 | uniform vec4 FogColor; 9 | uniform float Alpha; 10 | 11 | in float vertexDistance; 12 | in vec4 vertexColor; 13 | in vec2 TexCoord; 14 | in vec4 normal; 15 | 16 | out vec4 fragColor; 17 | 18 | vec4 linear_fog(vec4 inColor, float vertexDistance, float fogStart, float fogEnd, vec4 fogColor) { 19 | if (vertexDistance <= fogStart) { 20 | return inColor; 21 | } 22 | 23 | float fogValue = vertexDistance < fogEnd ? smoothstep(fogStart, fogEnd, vertexDistance) : 1.0; 24 | return vec4(mix(inColor.rgb, fogColor.rgb, fogValue * fogColor.a), inColor.a); 25 | } 26 | 27 | void main() { 28 | vec4 color = texture(Sampler, TexCoord) * vertexColor * ColorModulator; 29 | if (color.a < 0.1) { 30 | discard; 31 | } 32 | vec4 final = linear_fog(color, vertexDistance, FogStart, FogEnd, FogColor); 33 | if (Alpha > 1.0 || Alpha > final.a) { 34 | fragColor = final; 35 | } else { 36 | fragColor = vec4(final.rgb, Alpha); 37 | } 38 | } 39 | -------------------------------------------------------------------------------- /src/main/resources/assets/jex/shaders/outline.fsh: -------------------------------------------------------------------------------- 1 | #version 330 core 2 | 3 | in vec2 TexCoord; 4 | in vec2 Texel; 5 | 6 | uniform sampler2D Sampler; 7 | uniform int Width; 8 | uniform int Glow; 9 | uniform float GlowIntensity; 10 | 11 | out vec4 fragColor; 12 | 13 | void main(){ 14 | vec4 centerCol = texture(Sampler, TexCoord.st); 15 | 16 | if (centerCol.a != 0.0F) { 17 | fragColor = vec4(0, 0, 0, 0); 18 | return; 19 | } 20 | 21 | vec4 color = vec4(0, 0, 0, 0); 22 | 23 | float dist = Width * Width * 4.0; 24 | for (int x = -Width; x <= Width; x++) { 25 | for (int y = -Width; y <= Width; y++) { 26 | vec4 offset = texture(Sampler, TexCoord + Texel * vec2(x, y)); 27 | 28 | if (offset.a != 0) { 29 | float ndist = x * x + y * y - 1.0; 30 | dist = min(ndist, dist); 31 | color = offset; 32 | } 33 | } 34 | } 35 | 36 | float minDist = Width * Width; 37 | 38 | if (dist > minDist) { 39 | discard; 40 | } else { 41 | if (Glow == 1) color.a = max(0, ((Width*1.0F) - dist) / (Width*(1.0F + (1.0F - GlowIntensity)))); 42 | else color.a = min((1.0 - (dist / minDist)) * 3.5, 1.0); 43 | } 44 | fragColor = color; 45 | } 46 | 47 | -------------------------------------------------------------------------------- /src/main/resources/assets/jex/shaders/outline.vsh: -------------------------------------------------------------------------------- 1 | #version 330 core 2 | 3 | layout (location = 0) in vec3 Position; 4 | 5 | uniform mat4 Projection; 6 | uniform vec2 Size; 7 | 8 | out vec2 TexCoord; 9 | out vec2 Texel; 10 | 11 | void main() { 12 | vec4 outPos = Projection * vec4(Position.xy, 0.0, 1.0); 13 | gl_Position = vec4(outPos.xy, 0.2, 1.0); 14 | Texel = 1.0 / Size; 15 | TexCoord = Position.xy / Size; 16 | } -------------------------------------------------------------------------------- /src/main/resources/assets/jex/shaders/pos_color.fsh: -------------------------------------------------------------------------------- 1 | #version 330 core 2 | 3 | in vec4 frag_color; 4 | 5 | out vec4 fragColor; 6 | 7 | void main() { 8 | fragColor = frag_color; 9 | } 10 | -------------------------------------------------------------------------------- /src/main/resources/assets/jex/shaders/pos_color.vsh: -------------------------------------------------------------------------------- 1 | #version 330 core 2 | 3 | layout (location = 0) in vec3 Position; 4 | layout (location = 1) in vec4 Color; 5 | 6 | uniform mat4 Projection; 7 | uniform mat4 ModelView; 8 | 9 | out vec4 frag_color; 10 | 11 | void main(){ 12 | gl_Position = Projection * ModelView * vec4(Position, 1.0); 13 | frag_color = Color; 14 | } 15 | -------------------------------------------------------------------------------- /src/main/resources/assets/jex/shaders/rainbow_enchant.vsh: -------------------------------------------------------------------------------- 1 | #version 330 core 2 | 3 | layout (location = 0) in vec3 Position; 4 | layout (location = 1) in vec2 Tex; 5 | 6 | uniform mat4 ModelView; 7 | uniform mat4 Projection; 8 | uniform mat4 TextureMatrix; 9 | 10 | out float VertexDistance; 11 | out vec2 TexCoord; 12 | out vec3 Pos; 13 | 14 | void main() { 15 | gl_Position = Projection * ModelView * vec4(Position, 1.0); 16 | 17 | VertexDistance = length((ModelView * vec4(Position, 1.0)).xyz); 18 | TexCoord = (TextureMatrix * vec4(Tex, 0.0, 1.0)).xy; 19 | Pos = Position; 20 | } 21 | -------------------------------------------------------------------------------- /src/main/resources/assets/jex/skin/speedo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DustinRepo/JexClient/017ce1229fc446f66eee5c564ce28af142368f3d/src/main/resources/assets/jex/skin/speedo.png -------------------------------------------------------------------------------- /src/main/resources/assets/sodium/shaders/opacity_xray.fsh: -------------------------------------------------------------------------------- 1 | #version 150 core 2 | 3 | #import 4 | 5 | in vec4 v_Color; // The interpolated vertex color 6 | in vec2 v_TexCoord; // The interpolated block texture coordinates 7 | in vec2 v_LightCoord; // The interpolated light map texture coordinates 8 | in float v_FragDistance; // The fragment's distance from the camera 9 | 10 | uniform sampler2D u_BlockTex; // The block texture sampler 11 | uniform sampler2D u_LightTex; // The light map texture sampler 12 | 13 | uniform vec4 u_FogColor; // The color of the shader fog 14 | uniform float u_FogStart; // The starting position of the shader fog 15 | uniform float u_FogEnd; // The ending position of the shader fog 16 | 17 | uniform float Alpha; // Custom from Jex 18 | 19 | out vec4 fragColor; // The output fragment for the color framebuffer 20 | 21 | void main() { 22 | vec4 sampleBlockTex = texture(u_BlockTex, v_TexCoord); 23 | 24 | #ifdef ALPHA_CUTOFF 25 | if (sampleBlockTex.a < ALPHA_CUTOFF) { 26 | discard; 27 | } 28 | #else 29 | if (sampleBlockTex.a == 0) { 30 | discard; 31 | } 32 | #endif 33 | 34 | vec4 sampleLightTex = texture(u_LightTex, v_LightCoord); 35 | 36 | vec4 diffuseColor = (sampleBlockTex * sampleLightTex); 37 | diffuseColor *= v_Color; 38 | 39 | fragColor = _linearFog(diffuseColor, v_FragDistance, u_FogColor, u_FogStart, u_FogEnd); 40 | } 41 | -------------------------------------------------------------------------------- /src/main/resources/assets/sodium/shaders/opacity_xray.vsh: -------------------------------------------------------------------------------- 1 | #version 150 core 2 | 3 | #import 4 | #import 5 | #import 6 | #import 7 | 8 | out vec4 v_Color; 9 | out vec2 v_TexCoord; 10 | out vec2 v_LightCoord; 11 | 12 | #ifdef USE_FOG 13 | out float v_FragDistance; 14 | #endif 15 | 16 | uniform int u_FogShape; 17 | uniform vec3 u_RegionOffset; 18 | 19 | void main() { 20 | _vert_init(); 21 | 22 | // Transform the chunk-local vertex position into world model space 23 | vec3 position = u_RegionOffset + _draw_translation + _vert_position; 24 | 25 | #ifdef USE_FOG 26 | v_FragDistance = getFragDistance(u_FogShape, position); 27 | #endif 28 | 29 | // Transform the vertex position into model-view-projection space 30 | gl_Position = u_ProjectionMatrix * u_ModelViewMatrix * vec4(position, 1.0); 31 | 32 | // Pass the color and texture coordinates to the fragment shader 33 | v_Color = _vert_color; 34 | v_LightCoord = _vert_tex_light_coord; 35 | v_TexCoord = _vert_tex_diffuse_coord; 36 | } -------------------------------------------------------------------------------- /src/main/resources/fabric.mod.json: -------------------------------------------------------------------------------- 1 | { 2 | "schemaVersion": 1, 3 | "id": "jex", 4 | "version": "${version}", 5 | "name": "Jex Client", 6 | "description": "A Utility Client mod to be used on Anarchy servers.", 7 | "authors": [ 8 | "Untrusted/Dustin - Main Dev", 9 | "sl - Code Contributor", 10 | "c10udburst - Code Contributor", 11 | "Vonr/Qther - Code Contributor", 12 | "BobIsMyManager - Contributor" 13 | ], 14 | "contact": { 15 | "homepage": "https://discord.gg/BUcUGu6gfA", 16 | "sources": "https://github.com/DustinRepo/JexClient-main/tree/main" 17 | }, 18 | "license": "GNU General Public", 19 | "icon": "assets/jex/icon.png", 20 | "environment": "client", 21 | "entrypoints": { 22 | "main": [ 23 | "me.dustin.jex.load.JexLoad" 24 | ], 25 | "preLaunch": [ 26 | "me.dustin.jex.load.PreLaunch" 27 | ] 28 | }, 29 | "mixins": [ 30 | "jex.mixins.json" 31 | ], 32 | "depends": { 33 | "fabricloader": ">=0.14.0", 34 | "fabric": "*", 35 | "minecraft": "1.19.x", 36 | "java": ">=17" 37 | }, 38 | "suggests": { 39 | "flamingo": "*" 40 | } 41 | } 42 | --------------------------------------------------------------------------------