├── .gitattributes
├── .github
├── FUNDING.yml
└── workflows
│ ├── build-and-test.yml
│ └── release-tags.yml
├── .gitignore
├── .idea
├── codeStyles
│ ├── Project.xml
│ └── codeStyleConfig.xml
└── copyright
│ ├── LGPLv3.xml
│ └── profiles_settings.xml
├── COPYING
├── COPYING.LESSER
├── LICENSE
├── README.MD
├── build.gradle.kts
├── gradle
└── wrapper
│ ├── gradle-wrapper.jar
│ └── gradle-wrapper.properties
├── gradlew
├── gradlew.bat
├── settings.gradle.kts
└── src
└── main
├── java
├── com
│ └── falsepattern
│ │ ├── falsetweaks
│ │ ├── Compat.java
│ │ ├── FalseTweaks.java
│ │ ├── MultiLineLoadingException.java
│ │ ├── Share.java
│ │ ├── api
│ │ │ ├── Constants.java
│ │ │ ├── Modules.java
│ │ │ ├── ThreadedChunkUpdates.java
│ │ │ ├── animfix
│ │ │ │ ├── BatcherRegistry.java
│ │ │ │ ├── IAnimationUpdateBatcher.java
│ │ │ │ └── IAnimationUpdateBatcherFactory.java
│ │ │ ├── dynlights
│ │ │ │ ├── DynamicLightsDriver.java
│ │ │ │ └── FTDynamicLights.java
│ │ │ ├── threading
│ │ │ │ └── ThreadSafeBlockRenderer.java
│ │ │ └── triangulator
│ │ │ │ ├── ToggleableTessellator.java
│ │ │ │ └── VertexAPI.java
│ │ ├── asm
│ │ │ ├── ASMFixerUtility.java
│ │ │ ├── CoreLoadingPlugin.java
│ │ │ ├── FalseTweaksFieldHackTransformer.java
│ │ │ ├── FalseTweaksTransformer.java
│ │ │ ├── MixinCompatHackTweaker.java
│ │ │ ├── RFBFixerUtility.java
│ │ │ └── modules
│ │ │ │ ├── occlusion
│ │ │ │ └── optifine
│ │ │ │ │ ├── LazyOptiFineCheck.java
│ │ │ │ │ └── RenderGlobalDeOptimizer.java
│ │ │ │ └── threadedupdates
│ │ │ │ ├── Threading_RenderBlocksASM.java
│ │ │ │ ├── Threading_TessellatorUseReplacement.java
│ │ │ │ ├── Threading_ThreadSafeBlockRendererInjector.java
│ │ │ │ ├── block
│ │ │ │ ├── Threading_BlockMinMax.java
│ │ │ │ └── Threading_BlockMinMaxRedirector.java
│ │ │ │ ├── compat
│ │ │ │ ├── AngelicaRemappingAdapter.java
│ │ │ │ ├── Threading_AngelicaCompatFixer.java
│ │ │ │ └── Threading_AngelicaRemapper.java
│ │ │ │ └── settings
│ │ │ │ ├── Threading_GameSettings.java
│ │ │ │ └── Threading_GameSettingsRedirector.java
│ │ ├── config
│ │ │ ├── DynamicLightsConfig.java
│ │ │ ├── FalseTweaksGuiConfig.java
│ │ │ ├── FalseTweaksGuiFactory.java
│ │ │ ├── ModuleConfig.java
│ │ │ ├── OcclusionConfig.java
│ │ │ ├── OptiSpamConfig.java
│ │ │ ├── ProfilerConfig.java
│ │ │ ├── RenderListConfig.java
│ │ │ ├── RenderingSafetyConfig.java
│ │ │ ├── ThreadingConfig.java
│ │ │ ├── TranslucentBlockLayersConfig.java
│ │ │ ├── TriState.java
│ │ │ ├── TriangulatorConfig.java
│ │ │ └── VoxelizerConfig.java
│ │ ├── mixin
│ │ │ ├── bridge
│ │ │ │ └── occlison
│ │ │ │ │ └── WorldRendererMixinBridge.java
│ │ │ ├── mixins
│ │ │ │ ├── client
│ │ │ │ │ ├── animfix
│ │ │ │ │ │ ├── StitcherMixin.java
│ │ │ │ │ │ ├── StitcherSlotMixin.java
│ │ │ │ │ │ ├── TextureMap_CommonMixin.java
│ │ │ │ │ │ ├── TextureMap_ProfiledMixin.java
│ │ │ │ │ │ ├── TextureMap_UnprofiledMixin.java
│ │ │ │ │ │ ├── TextureUtil_ProfiledMixin.java
│ │ │ │ │ │ ├── TextureUtil_UnprofiledMixin.java
│ │ │ │ │ │ └── fastcraft
│ │ │ │ │ │ │ ├── AbstractTextureMixin.java
│ │ │ │ │ │ │ ├── DynamicTextureMixin.java
│ │ │ │ │ │ │ ├── TextureMapMixin.java
│ │ │ │ │ │ │ └── TextureUtilMixin.java
│ │ │ │ │ ├── bsp
│ │ │ │ │ │ ├── TessellatorBSPSortingMixin.java
│ │ │ │ │ │ ├── TessellatorMixin.java
│ │ │ │ │ │ └── foamfix
│ │ │ │ │ │ │ └── TessellatorBSPSortingMixin.java
│ │ │ │ │ ├── cc
│ │ │ │ │ │ ├── WorldRendererMixin.java
│ │ │ │ │ │ └── of
│ │ │ │ │ │ │ ├── ChunkCacheOF_NonShader_DevMixin.java
│ │ │ │ │ │ │ ├── ChunkCacheOF_NonShader_ObfMixin.java
│ │ │ │ │ │ │ ├── ChunkCacheOF_ShaderMixin.java
│ │ │ │ │ │ │ ├── ChunkCacheOF_Shader_DevMixin.java
│ │ │ │ │ │ │ └── ChunkCacheOF_Shader_ObfMixin.java
│ │ │ │ │ ├── cubicparticles
│ │ │ │ │ │ └── EntityDiggingFXMixin.java
│ │ │ │ │ ├── debug
│ │ │ │ │ │ ├── TileEntityRendererDispatcherMixin.java
│ │ │ │ │ │ ├── WorldRendererMixin.java
│ │ │ │ │ │ └── occlusion
│ │ │ │ │ │ │ └── neodymium
│ │ │ │ │ │ │ ├── GPUMemoryManagerMixin.java
│ │ │ │ │ │ │ └── NeoRendererMixin.java
│ │ │ │ │ ├── dynlights
│ │ │ │ │ │ ├── ItemRendererMixin.java
│ │ │ │ │ │ ├── RenderGlobalMixin.java
│ │ │ │ │ │ ├── WorldClientMixin.java
│ │ │ │ │ │ ├── nonthread
│ │ │ │ │ │ │ └── WorldClientMixin.java
│ │ │ │ │ │ ├── of
│ │ │ │ │ │ │ └── DynamicLightsMixin.java
│ │ │ │ │ │ └── thread
│ │ │ │ │ │ │ └── WorldClientMixin.java
│ │ │ │ │ ├── mipmapfix
│ │ │ │ │ │ ├── TextureAtlasSpriteMixin.java
│ │ │ │ │ │ ├── TextureMapMixin.java
│ │ │ │ │ │ └── TextureUtilMixin.java
│ │ │ │ │ ├── misc
│ │ │ │ │ │ ├── BeaconFix_TileEntityBeaconMixin.java
│ │ │ │ │ │ ├── BeaconFix_TileEntityBeaconRendererMixin.java
│ │ │ │ │ │ ├── ItemRenderList_ItemRendererMixin.java
│ │ │ │ │ │ ├── MinecartEarBlast_WorldClientMixin.java
│ │ │ │ │ │ ├── OverlayCrashFix_ItemRendererMixin.java
│ │ │ │ │ │ ├── ParticleTransparency_EffectRendererMixin.java
│ │ │ │ │ │ ├── RealmShutUp_GuiMainMenuMixin.java
│ │ │ │ │ │ ├── RealmShutUp_RealmsBridgeMixin.java
│ │ │ │ │ │ ├── SkyFix_RenderGlobalMixin.java
│ │ │ │ │ │ ├── TileEntitySorting_RenderGlobalMixin.java
│ │ │ │ │ │ └── TranslucentBlockLayers_RenderGlobalMixin.java
│ │ │ │ │ ├── occlusion
│ │ │ │ │ │ ├── ClippingHelperImplMixin.java
│ │ │ │ │ │ ├── ClippingHelperMixin.java
│ │ │ │ │ │ ├── EntityRendererMixin.java
│ │ │ │ │ │ ├── GameSettingsMixin.java
│ │ │ │ │ │ ├── GameSettingsOptionsMixin.java
│ │ │ │ │ │ ├── GuiVideoSettingsMixin.java
│ │ │ │ │ │ ├── MinecraftMixin.java
│ │ │ │ │ │ ├── RenderGlobalMixin.java
│ │ │ │ │ │ ├── WorldRendererMixin.java
│ │ │ │ │ │ ├── fastcraft
│ │ │ │ │ │ │ ├── EntityRendererMixin.java
│ │ │ │ │ │ │ └── GLAllocationMixin.java
│ │ │ │ │ │ ├── neodymium
│ │ │ │ │ │ │ └── NeoRendererMixin.java
│ │ │ │ │ │ ├── optifastcraft
│ │ │ │ │ │ │ ├── RenderGlobal_DevMixin.java
│ │ │ │ │ │ │ └── RenderGlobal_ObfMixin.java
│ │ │ │ │ │ └── optifine
│ │ │ │ │ │ │ ├── GameSettingsOptifineMixin.java
│ │ │ │ │ │ │ ├── GuiVideoSettingsOptifineMixin.java
│ │ │ │ │ │ │ ├── RenderGlobalMixin.java
│ │ │ │ │ │ │ ├── WorldRenderer_OFMixin.java
│ │ │ │ │ │ │ ├── WorldRenderer_VanillaMixin.java
│ │ │ │ │ │ │ └── shaders
│ │ │ │ │ │ │ ├── FrustrumMixin.java
│ │ │ │ │ │ │ ├── ShadersMixin.java
│ │ │ │ │ │ │ └── ShadersRendererMixin.java
│ │ │ │ │ ├── optispam
│ │ │ │ │ │ ├── BlockAliasesMixin.java
│ │ │ │ │ │ ├── ConnectedParserMixin.java
│ │ │ │ │ │ ├── ShaderExpressionResolverMixin.java
│ │ │ │ │ │ └── ShaderPackParserMixin.java
│ │ │ │ │ ├── profiler
│ │ │ │ │ │ ├── MinecraftMixin.java
│ │ │ │ │ │ └── ProfilerMixin.java
│ │ │ │ │ ├── rendersafety
│ │ │ │ │ │ ├── ForgeHooksClientMixin.java
│ │ │ │ │ │ ├── ItemRendererMixin.java
│ │ │ │ │ │ ├── RenderHelperMixin.java
│ │ │ │ │ │ ├── RenderingRegistryMixin.java
│ │ │ │ │ │ ├── TileEntityRendererDispatcherMixin.java
│ │ │ │ │ │ └── dragonapi
│ │ │ │ │ │ │ └── TileEntityRenderEventMixin.java
│ │ │ │ │ ├── threadedupdates
│ │ │ │ │ │ ├── ChunkProviderClientMixin.java
│ │ │ │ │ │ ├── ForgeHooksClientMixin.java
│ │ │ │ │ │ ├── GameSettingsMixin.java
│ │ │ │ │ │ ├── OpenGLHelperMixin.java
│ │ │ │ │ │ ├── RenderBlocksMixin.java
│ │ │ │ │ │ ├── RenderGlobalMixin.java
│ │ │ │ │ │ ├── RenderingRegistryMixin.java
│ │ │ │ │ │ ├── TessellatorMixin.java
│ │ │ │ │ │ ├── TessellatorMixin_Debug.java
│ │ │ │ │ │ ├── TessellatorMixin_DebugFast.java
│ │ │ │ │ │ ├── WorldRendererMixin.java
│ │ │ │ │ │ ├── WorldRenderer_NonOptiFineMixin.java
│ │ │ │ │ │ ├── automagy
│ │ │ │ │ │ │ └── RenderBlockGlowOverlayMixin.java
│ │ │ │ │ │ ├── blockbounds
│ │ │ │ │ │ │ ├── BlockMixin_FastImpl.java
│ │ │ │ │ │ │ ├── BlockMixin_Impl.java
│ │ │ │ │ │ │ └── BlockMixin_Root.java
│ │ │ │ │ │ ├── computronics
│ │ │ │ │ │ │ └── LampRenderMixin.java
│ │ │ │ │ │ ├── dragonapi
│ │ │ │ │ │ │ ├── WorldRenderer_DAPIMixin.java
│ │ │ │ │ │ │ └── WorldRenderer_VanillaMixin.java
│ │ │ │ │ │ ├── extracells
│ │ │ │ │ │ │ └── RendererHardMEDriveMixin.java
│ │ │ │ │ │ ├── malisis
│ │ │ │ │ │ │ ├── MalisisRendererMixin.java
│ │ │ │ │ │ │ ├── ParameterMixin.java
│ │ │ │ │ │ │ └── nh
│ │ │ │ │ │ │ │ └── ParameterMixin.java
│ │ │ │ │ │ ├── neodymium
│ │ │ │ │ │ │ └── WorldRendererMixin.java
│ │ │ │ │ │ ├── notfine
│ │ │ │ │ │ │ └── CTMUtilsMixin.java
│ │ │ │ │ │ ├── nuclearcontrol
│ │ │ │ │ │ │ ├── MainBlockRendererMixin.java
│ │ │ │ │ │ │ ├── TileEntityAdvancedInfoPanelMixin.java
│ │ │ │ │ │ │ └── TileEntityInfoPanelRendererMixin.java
│ │ │ │ │ │ ├── opencomputers
│ │ │ │ │ │ │ └── RenderStateMixin.java
│ │ │ │ │ │ ├── optifine
│ │ │ │ │ │ │ ├── GameSettingsMixin.java
│ │ │ │ │ │ │ ├── GuiPerformanceSettingsOFMixin.java
│ │ │ │ │ │ │ ├── MinecraftMixin.java
│ │ │ │ │ │ │ ├── ShadersMixin.java
│ │ │ │ │ │ │ ├── TessellatorMixin.java
│ │ │ │ │ │ │ ├── WorldClientMixin.java
│ │ │ │ │ │ │ └── WorldRendererMixin.java
│ │ │ │ │ │ ├── storagedrawers
│ │ │ │ │ │ │ ├── CommonDrawerRendererMixin.java
│ │ │ │ │ │ │ ├── CommonFramingRendererMixin.java
│ │ │ │ │ │ │ ├── CommonTrimRendererMixin.java
│ │ │ │ │ │ │ ├── ControllerRendererMixin.java
│ │ │ │ │ │ │ ├── DrawersItemRendererMixin.java
│ │ │ │ │ │ │ ├── DrawersRendererMixin.java
│ │ │ │ │ │ │ ├── FramingTableRendererMixin.java
│ │ │ │ │ │ │ ├── ModularBoxRendererMixin.java
│ │ │ │ │ │ │ ├── PanelBoxRendererMixin.java
│ │ │ │ │ │ │ └── RenderHelperMixin.java
│ │ │ │ │ │ ├── techguns
│ │ │ │ │ │ │ └── RenderLadderMixin.java
│ │ │ │ │ │ └── thermalexpansion
│ │ │ │ │ │ │ ├── BlockCacheMixin.java
│ │ │ │ │ │ │ ├── BlockCellMixin.java
│ │ │ │ │ │ │ ├── BlockDeviceMixin.java
│ │ │ │ │ │ │ ├── BlockEnderMixin.java
│ │ │ │ │ │ │ ├── BlockFrameMixin.java
│ │ │ │ │ │ │ ├── BlockLightMixin.java
│ │ │ │ │ │ │ ├── BlockMachineMixin.java
│ │ │ │ │ │ │ ├── BlockSpongeMixin.java
│ │ │ │ │ │ │ ├── BlockTankMixin.java
│ │ │ │ │ │ │ ├── RenderCellMixin.java
│ │ │ │ │ │ │ ├── RenderFrameMixin.java
│ │ │ │ │ │ │ ├── RenderLightMixin.java
│ │ │ │ │ │ │ ├── RenderTankMixin.java
│ │ │ │ │ │ │ └── RenderTesseractMixin.java
│ │ │ │ │ ├── triangulator
│ │ │ │ │ │ ├── RenderBlocksCompatMixin.java
│ │ │ │ │ │ ├── RenderBlocksPerformanceMixin.java
│ │ │ │ │ │ ├── RenderBlocksUltraMixin.java
│ │ │ │ │ │ ├── RenderGlobalMixin.java
│ │ │ │ │ │ ├── RenderingRegistryMixin.java
│ │ │ │ │ │ ├── TessellatorMixin.java
│ │ │ │ │ │ ├── WorldRendererMixin.java
│ │ │ │ │ │ ├── optifine
│ │ │ │ │ │ │ ├── TessellatorOptiFineMixin.java
│ │ │ │ │ │ │ ├── TessellatorVanillaMixin.java
│ │ │ │ │ │ │ └── TessellatorVanillaOrOldOptifineMixin.java
│ │ │ │ │ │ └── redstonepaste
│ │ │ │ │ │ │ └── RedstonePasteHighlighterMixin.java
│ │ │ │ │ └── voxelizer
│ │ │ │ │ │ ├── ItemRendererMixin.java
│ │ │ │ │ │ ├── OFItemRendererMixin.java
│ │ │ │ │ │ ├── RenderBlocksMixin.java
│ │ │ │ │ │ ├── RenderItemMixin.java
│ │ │ │ │ │ ├── TextureAtlasSpriteMixin.java
│ │ │ │ │ │ ├── TextureManagerMixin.java
│ │ │ │ │ │ ├── TextureMapMixin.java
│ │ │ │ │ │ └── railcraft
│ │ │ │ │ │ └── RenderTrackMixin.java
│ │ │ │ └── common
│ │ │ │ │ ├── compat
│ │ │ │ │ └── sc
│ │ │ │ │ │ ├── BlockReinforcedFenceGateMixin.java
│ │ │ │ │ │ ├── BlockReinforcedGlassPaneMixin.java
│ │ │ │ │ │ ├── BlockReinforcedIronBarsMixin.java
│ │ │ │ │ │ └── BlockReinforcedStainedGlassPanesMixin.java
│ │ │ │ │ ├── misc
│ │ │ │ │ └── GetBiomeCrashFix_BiomeGenBaseMixin.java
│ │ │ │ │ ├── occlusion
│ │ │ │ │ └── PlayerManagerMixin.java
│ │ │ │ │ └── startup
│ │ │ │ │ ├── ASMDataTableMixin.java
│ │ │ │ │ ├── DirectoryDiscovererMixin.java
│ │ │ │ │ ├── JarDiscovererMixin.java
│ │ │ │ │ ├── ModContainerFactoryMixin.java
│ │ │ │ │ └── ModDiscovererMixin.java
│ │ │ └── plugin
│ │ │ │ ├── init
│ │ │ │ ├── Mixin.java
│ │ │ │ └── MixinPlugin.java
│ │ │ │ └── standard
│ │ │ │ ├── Extras.java
│ │ │ │ ├── Mixin.java
│ │ │ │ ├── MixinPlugin.java
│ │ │ │ └── TargetedMod.java
│ │ ├── modules
│ │ │ ├── animfix
│ │ │ │ ├── AnimFixCompat.java
│ │ │ │ ├── AnimationUpdateBatcherRegistry.java
│ │ │ │ ├── DefaultAnimationUpdateBatcher.java
│ │ │ │ ├── interfaces
│ │ │ │ │ ├── IStitcherSlotMixin.java
│ │ │ │ │ └── ITextureMapMixin.java
│ │ │ │ └── stitching
│ │ │ │ │ ├── HolderSlot.java
│ │ │ │ │ ├── Rect2D.java
│ │ │ │ │ ├── SpriteSlot.java
│ │ │ │ │ ├── StitcherState.java
│ │ │ │ │ ├── TooBigException.java
│ │ │ │ │ ├── TurboStitcher.java
│ │ │ │ │ └── packing2d
│ │ │ │ │ ├── Algorithm.java
│ │ │ │ │ ├── Packer.java
│ │ │ │ │ ├── PackerBFDH.java
│ │ │ │ │ ├── PackerFFDH.java
│ │ │ │ │ └── StripLevel.java
│ │ │ ├── bsp
│ │ │ │ └── IBSPTessellator.java
│ │ │ ├── cc
│ │ │ │ └── ChunkCacheFT.java
│ │ │ ├── cubicparticles
│ │ │ │ └── ParticleUtil.java
│ │ │ ├── debug
│ │ │ │ ├── Debug.java
│ │ │ │ ├── DebugLogging.java
│ │ │ │ └── Toggler.java
│ │ │ ├── dynlights
│ │ │ │ ├── ArrayCache.java
│ │ │ │ ├── DynamicLightsDrivers.java
│ │ │ │ ├── DynamicLightsNoOp.java
│ │ │ │ ├── DynamicLightsWorldClient.java
│ │ │ │ └── base
│ │ │ │ │ ├── DynamicLight.java
│ │ │ │ │ └── DynamicLights.java
│ │ │ ├── mipmapfix
│ │ │ │ ├── Mipmaps.java
│ │ │ │ └── MulticoreMipMapEngine.java
│ │ │ ├── misc
│ │ │ │ └── TranslucentBlockLayers.java
│ │ │ ├── occlusion
│ │ │ │ ├── BasicDistanceSorter.java
│ │ │ │ ├── CameraInfo.java
│ │ │ │ ├── IRenderGlobalListener.java
│ │ │ │ ├── IRendererUpdateOrderProvider.java
│ │ │ │ ├── InterruptableSorter.java
│ │ │ │ ├── LICENSE
│ │ │ │ ├── OcclusionCompat.java
│ │ │ │ ├── OcclusionHelpers.java
│ │ │ │ ├── OcclusionQueryManager.java
│ │ │ │ ├── OcclusionRenderer.java
│ │ │ │ ├── OcclusionWorker.java
│ │ │ │ ├── PreviousActiveRenderInfo.java
│ │ │ │ ├── SetVisibility.java
│ │ │ │ ├── SpatialRenderStore.java
│ │ │ │ ├── TickTimeTracker.java
│ │ │ │ ├── WRComparator.java
│ │ │ │ ├── WorldRendererOcclusion.java
│ │ │ │ ├── interfaces
│ │ │ │ │ └── IRenderGlobalMixin.java
│ │ │ │ ├── leakfix
│ │ │ │ │ └── LeakFix.java
│ │ │ │ ├── shader
│ │ │ │ │ └── ShadowPassOcclusionHelper.java
│ │ │ │ └── util
│ │ │ │ │ ├── IntStack.java
│ │ │ │ │ └── IntVector.java
│ │ │ ├── profiler
│ │ │ │ └── ProfilingNode.java
│ │ │ ├── renderlists
│ │ │ │ ├── ItemProp.java
│ │ │ │ ├── ItemRenderListManager.java
│ │ │ │ └── VoxelRenderListManager.java
│ │ │ ├── rendersafety
│ │ │ │ └── SafetyUtil.java
│ │ │ ├── startup
│ │ │ │ ├── RegexHelper.java
│ │ │ │ └── ThreadSafeASMDataTable.java
│ │ │ ├── threadedupdates
│ │ │ │ ├── CircularTaskQueue.java
│ │ │ │ ├── DoubleBuffered.java
│ │ │ │ ├── FastThreadLocal.java
│ │ │ │ ├── ICapturableTessellator.java
│ │ │ │ ├── IRendererUpdateResultHolder.java
│ │ │ │ ├── IRenderingRegistryExt.java
│ │ │ │ ├── ITessellatorOptiFineCompat.java
│ │ │ │ ├── IllegalThreadingDrawing.java
│ │ │ │ ├── MainThreadContainer.java
│ │ │ │ ├── NeodymiumCompat.java
│ │ │ │ ├── NeodymiumWorldRendererThreadingBridge.java
│ │ │ │ ├── OptiFineCompat.java
│ │ │ │ ├── RenderBlocksStack.java
│ │ │ │ ├── ThreadSafeBlockBounds.java
│ │ │ │ ├── ThreadSafeBlockRendererMap.java
│ │ │ │ ├── ThreadSafeSettings.java
│ │ │ │ ├── ThreadedBlockSafetyRegistry.java
│ │ │ │ ├── ThreadedChunkUpdateHelper.java
│ │ │ │ ├── ThreadedClientHooks.java
│ │ │ │ └── interop
│ │ │ │ │ ├── StorageDrawersCompat.java
│ │ │ │ │ ├── ThermalExpansionCompat.java
│ │ │ │ │ ├── ThreadSafeISBRH.java
│ │ │ │ │ └── ThreadSafeISBRHFactory.java
│ │ │ ├── threadexec
│ │ │ │ ├── FTWorker.java
│ │ │ │ ├── ThreadedTask.java
│ │ │ │ └── TurboTransferQueue.java
│ │ │ ├── triangulator
│ │ │ │ ├── ToggleableTessellatorManager.java
│ │ │ │ ├── VertexInfo.java
│ │ │ │ ├── calibration
│ │ │ │ │ ├── Calibration.java
│ │ │ │ │ └── CalibrationGUI.java
│ │ │ │ ├── interfaces
│ │ │ │ │ ├── IRenderBlocksMixin.java
│ │ │ │ │ └── ITriangulatorTessellator.java
│ │ │ │ ├── renderblocks
│ │ │ │ │ ├── Facing.java
│ │ │ │ │ └── RenderState.java
│ │ │ │ └── sorting
│ │ │ │ │ ├── BSPTessellatorVertexState.java
│ │ │ │ │ ├── ChunkBSPTree.java
│ │ │ │ │ ├── PolygonHolder.java
│ │ │ │ │ ├── SharedMath.java
│ │ │ │ │ ├── TreeNode.java
│ │ │ │ │ ├── area
│ │ │ │ │ ├── NormalAreaComputer.java
│ │ │ │ │ ├── QuadAreaComputer.java
│ │ │ │ │ └── TriangleAreaComputer.java
│ │ │ │ │ └── midpoint
│ │ │ │ │ ├── MidpointComputer.java
│ │ │ │ │ ├── QuadMidpointComputer.java
│ │ │ │ │ └── TriangleMidpointComputer.java
│ │ │ └── voxelizer
│ │ │ │ ├── Data.java
│ │ │ │ ├── Dir.java
│ │ │ │ ├── Face.java
│ │ │ │ ├── Layer.java
│ │ │ │ ├── Voxel.java
│ │ │ │ ├── VoxelCompiler.java
│ │ │ │ ├── VoxelGrid.java
│ │ │ │ ├── VoxelMesh.java
│ │ │ │ ├── VoxelRenderHelper.java
│ │ │ │ ├── VoxelType.java
│ │ │ │ ├── interfaces
│ │ │ │ └── ITextureAtlasSpriteMixin.java
│ │ │ │ ├── loading
│ │ │ │ ├── LayerMetadataSection.java
│ │ │ │ └── LayerMetadataSerializer.java
│ │ │ │ └── strategy
│ │ │ │ ├── BestMergingStrategy.java
│ │ │ │ ├── ExpandingRectMergingStrategy.java
│ │ │ │ ├── MergingStrategy.java
│ │ │ │ ├── NullMergingStrategy.java
│ │ │ │ ├── RowColumnMergingStrategy.java
│ │ │ │ └── StrategyPreset.java
│ │ ├── proxy
│ │ │ ├── ClientProxy.java
│ │ │ ├── CommonProxy.java
│ │ │ └── ServerProxy.java
│ │ └── util
│ │ │ └── ConfigFixUtil.java
│ │ └── triangulator
│ │ └── api
│ │ └── ToggleableTessellator.java
└── stubpackage
│ ├── ChunkCacheOF.java
│ ├── Config.java
│ ├── DynamicLights.java
│ ├── WrDisplayListAllocator.java
│ └── net
│ └── minecraft
│ └── client
│ └── renderer
│ ├── EntityRenderer.java
│ └── WorldRenderer.java
└── resources
├── LICENSE
├── META-INF
├── deps.json
└── falsetweaks_at.cfg
├── assets
├── falsetweaks
│ ├── lang
│ │ ├── en_US.lang
│ │ └── zh_CN.lang
│ ├── reference.png
│ └── white.png
└── minecraft
│ └── textures
│ └── blocks
│ ├── double_plant_grass_bottom.png
│ ├── double_plant_grass_top.png
│ └── tallgrass.png
├── mcmod.info
├── mixins.falsetweaks.init.json
├── mixins.falsetweaks.json
└── pack.mcmeta
/.gitattributes:
--------------------------------------------------------------------------------
1 | * text eol=lf
2 |
3 | *.[jJ][aA][rR] binary
4 |
5 | *.[pP][nN][gG] binary
6 | *.[jJ][pP][gG] binary
7 | *.[jJ][pP][eE][gG] binary
8 | *.[gG][iI][fF] binary
9 | *.[tT][iI][fF] binary
10 | *.[tT][iI][fF][fF] binary
11 | *.[iI][cC][oO] binary
12 | *.[sS][vV][gG] text
13 | *.[eE][pP][sS] binary
14 | *.[xX][cC][fF] binary
15 |
16 | *.[kK][aA][rR] binary
17 | *.[mM]4[aA] binary
18 | *.[mM][iI][dD] binary
19 | *.[mM][iI][dD][iI] binary
20 | *.[mM][pP]3 binary
21 | *.[oO][gG][gG] binary
22 | *.[rR][aA] binary
23 |
24 | *.7[zZ] binary
25 | *.[gG][zZ] binary
26 | *.[tT][aA][rR] binary
27 | *.[tT][gG][zZ] binary
28 | *.[zZ][iI][pP] binary
29 |
30 | *.[tT][cC][nN] binary
31 | *.[sS][oO] binary
32 | *.[dD][lL][lL] binary
33 | *.[dD][yY][lL][iI][bB] binary
34 | *.[pP][sS][dD] binary
35 | *.[tT][tT][fF] binary
36 | *.[oO][tT][fF] binary
37 |
38 | *.[pP][aA][tT][cC][hH] -text
39 |
40 | *.[bB][aA][tT] text eol=crlf
41 | *.[cC][mM][dD] text eol=crlf
42 | *.[pP][sS]1 text eol=crlf
43 |
44 | *[aA][uU][tT][oO][gG][eE][nN][eE][rR][aA][tT][eE][dD]* binary
45 |
--------------------------------------------------------------------------------
/.github/FUNDING.yml:
--------------------------------------------------------------------------------
1 | patreon: falsepattern
2 | ko_fi: falsepattern
--------------------------------------------------------------------------------
/.github/workflows/build-and-test.yml:
--------------------------------------------------------------------------------
1 | name: Build and test
2 |
3 | on:
4 | pull_request:
5 | branches:
6 | - master
7 | push:
8 | branches:
9 | - master
10 |
11 | jobs:
12 | build-and-test:
13 | uses: FalsePattern/fpgradle-workflows/.github/workflows/build-and-test.yml@master
14 | with:
15 | timeout: 90
16 | workspace: setupCIWorkspace
17 | client-only: false
18 |
--------------------------------------------------------------------------------
/.github/workflows/release-tags.yml:
--------------------------------------------------------------------------------
1 | name: Release Tags
2 |
3 | on:
4 | push:
5 | tags:
6 | - '*'
7 |
8 | permissions:
9 | contents: write
10 |
11 | jobs:
12 | release-tags:
13 | uses: FalsePattern/fpgradle-workflows/.github/workflows/release-tags.yml@master
14 | with:
15 | workspace: "setupCIWorkspace"
16 | secrets:
17 | MAVEN_DEPLOY_USER: ${{ secrets.MAVEN_DEPLOY_USER }}
18 | MAVEN_DEPLOY_PASSWORD: ${{ secrets.MAVEN_DEPLOY_PASSWORD }}
19 | MODRINTH_TOKEN: ${{ secrets.MODRINTH_TOKEN }}
20 | CURSEFORGE_TOKEN: ${{ secrets.CURSEFORGE_TOKEN }}
21 |
22 |
--------------------------------------------------------------------------------
/.idea/codeStyles/codeStyleConfig.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
--------------------------------------------------------------------------------
/.idea/copyright/LGPLv3.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
--------------------------------------------------------------------------------
/.idea/copyright/profiles_settings.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
--------------------------------------------------------------------------------
/gradle/wrapper/gradle-wrapper.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/FalsePattern/FalseTweaks/47343096a224c1b28a7eb0ba882b2cb44774c4d0/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-8.14-bin.zip
4 | networkTimeout=10000
5 | validateDistributionUrl=true
6 | zipStoreBase=GRADLE_USER_HOME
7 | zipStorePath=wrapper/dists
8 |
--------------------------------------------------------------------------------
/settings.gradle.kts:
--------------------------------------------------------------------------------
1 | plugins {
2 | id("org.gradle.toolchains.foojay-resolver-convention") version("0.9.0")
3 | }
4 |
5 | rootProject.name = "FalseTweaks"
6 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/Share.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks;
24 |
25 | import org.apache.logging.log4j.LogManager;
26 | import org.apache.logging.log4j.Logger;
27 |
28 | public class Share {
29 | public static final Logger log = LogManager.getLogger(Tags.MOD_NAME);
30 |
31 | public static boolean LEAKFIX_CLASS_INITIALIZED = false;
32 | }
33 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/api/Constants.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 | package com.falsepattern.falsetweaks.api;
23 |
24 | public class Constants {
25 | public static final int MaximumRenderDistance = 64;
26 | }
27 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/api/ThreadedChunkUpdates.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.api;
24 |
25 | import com.falsepattern.falsetweaks.modules.threadedupdates.ThreadedChunkUpdateHelper;
26 |
27 | import net.minecraft.client.renderer.Tessellator;
28 |
29 | public class ThreadedChunkUpdates {
30 |
31 | public static boolean isEnabled() {
32 | return ThreadedChunkUpdateHelper.instance != null;
33 | }
34 |
35 | /**
36 | * Returns the thread-local tessellator instance. Can only be called after init phase.
37 | */
38 | public static Tessellator getThreadTessellator() {
39 | if (ThreadedChunkUpdateHelper.instance != null) {
40 | return ThreadedChunkUpdateHelper.instance.getThreadTessellator();
41 | }
42 | return ThreadedChunkUpdateHelper.mainThreadTessellator();
43 | }
44 | }
45 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/api/animfix/BatcherRegistry.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.api.animfix;
24 |
25 | import com.falsepattern.falsetweaks.modules.animfix.AnimationUpdateBatcherRegistry;
26 | import com.falsepattern.lib.StableAPI;
27 |
28 | @StableAPI(since = "2.1.0")
29 | public class BatcherRegistry {
30 | @StableAPI.Expose
31 | public static void registerBatcherFactory(IAnimationUpdateBatcherFactory factory, int priority) {
32 | AnimationUpdateBatcherRegistry.registerBatcherFactory(factory, priority);
33 | }
34 | }
35 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/api/animfix/IAnimationUpdateBatcher.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.api.animfix;
24 |
25 | import com.falsepattern.lib.StableAPI;
26 |
27 | @StableAPI(since = "2.1.0")
28 | public interface IAnimationUpdateBatcher {
29 | @StableAPI.Expose
30 | boolean scheduleUpload(int[][] texture, int width, int height, int xOffset, int yOffset);
31 |
32 | @StableAPI.Expose
33 | void terminate();
34 |
35 | @StableAPI.Expose
36 | void upload();
37 | }
38 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/api/animfix/IAnimationUpdateBatcherFactory.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.api.animfix;
24 |
25 | import com.falsepattern.lib.StableAPI;
26 |
27 | @StableAPI(since = "2.1.0")
28 | public interface IAnimationUpdateBatcherFactory {
29 | @StableAPI.Expose
30 | IAnimationUpdateBatcher createBatcher(int xOffset, int yOffset, int width, int height, int mipLevel);
31 | }
32 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/api/threading/ThreadSafeBlockRenderer.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 | package com.falsepattern.falsetweaks.api.threading;
23 |
24 | import com.falsepattern.lib.StableAPI;
25 |
26 | import cpw.mods.fml.client.registry.ISimpleBlockRenderingHandler;
27 |
28 | /**
29 | * This gets injected into classes by the THREAD_SAFE_ISBRHS config option, along with a static final threadlocal, with the initial instance generated via the default constructor
30 | * of said renderer.
31 | *
32 | * This class is this tiny to make ASM work and stubbing it easier (reducing coupling between projects).
33 | */
34 | @StableAPI(since = "3.0.0")
35 | public interface ThreadSafeBlockRenderer {
36 | @StableAPI.Expose
37 | ISimpleBlockRenderingHandler forCurrentThread();
38 | }
39 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/asm/ASMFixerUtility.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.asm;
24 |
25 | import lombok.val;
26 |
27 | import net.minecraft.launchwrapper.IClassTransformer;
28 |
29 | import java.util.List;
30 |
31 | public class ASMFixerUtility {
32 | public static void removeGTNHLibHook(List transformers) {
33 | val iter = transformers.iterator();
34 | while (iter.hasNext()) {
35 | val transformer = (IClassTransformer) iter.next();
36 | if (transformer.getClass().getName().equals("com.gtnewhorizon.gtnhlib.core.transformer.TessellatorRedirectorTransformer")) {
37 | iter.remove();
38 | }
39 | }
40 | }
41 | }
42 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/asm/RFBFixerUtility.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.asm;
24 |
25 | import com.gtnewhorizons.retrofuturabootstrap.SharedConfig;
26 | import com.gtnewhorizons.retrofuturabootstrap.api.RfbClassTransformerHandle;
27 | import lombok.SneakyThrows;
28 | import lombok.val;
29 |
30 | import java.util.ArrayList;
31 | import java.util.Arrays;
32 | import java.util.concurrent.atomic.AtomicReference;
33 |
34 | public class RFBFixerUtility {
35 | @SneakyThrows
36 | public static void removeGTNHLibHook() {
37 | val theField = SharedConfig.class.getDeclaredField("rfbTransformers");
38 | theField.setAccessible(true);
39 | val ref = (AtomicReference) theField.get(null);
40 | val arr = new ArrayList<>(Arrays.asList(ref.get()));
41 | val iter = arr.iterator();
42 | while (iter.hasNext()) {
43 | val elem = iter.next();
44 | if (elem.id().equals("gtnhlib:redirector")) {
45 | iter.remove();
46 | }
47 | }
48 | ref.set(arr.toArray(new RfbClassTransformerHandle[0]));
49 | }
50 | }
51 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/asm/modules/threadedupdates/compat/Threading_AngelicaRemapper.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.asm.modules.threadedupdates.compat;
24 |
25 | import lombok.val;
26 | import org.objectweb.asm.ClassReader;
27 | import org.objectweb.asm.ClassWriter;
28 |
29 | import net.minecraft.launchwrapper.IClassTransformer;
30 |
31 | public class Threading_AngelicaRemapper implements IClassTransformer {
32 | @Override
33 | public byte[] transform(String name, String transformedName, byte[] bytes) {
34 | if (bytes == null)
35 | return null;
36 |
37 | val reader = new ClassReader(bytes);
38 | val writer = new ClassWriter(0);
39 | val remapAdapter = new AngelicaRemappingAdapter(writer);
40 | reader.accept(remapAdapter, ClassReader.EXPAND_FRAMES);
41 | return writer.toByteArray();
42 | }
43 | }
44 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/config/FalseTweaksGuiFactory.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.config;
24 |
25 | import com.falsepattern.lib.config.SimpleGuiFactory;
26 |
27 | import net.minecraft.client.gui.GuiScreen;
28 |
29 | public class FalseTweaksGuiFactory implements SimpleGuiFactory {
30 | @Override
31 | public Class extends GuiScreen> mainConfigGuiClass() {
32 | return FalseTweaksGuiConfig.class;
33 | }
34 | }
35 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/config/ProfilerConfig.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.config;
24 |
25 | import com.falsepattern.falsetweaks.Tags;
26 | import com.falsepattern.lib.config.Config;
27 | import com.falsepattern.lib.config.ConfigurationManager;
28 |
29 | @Config.Comment("Improved Shift+F3 profiler")
30 | @Config(modid = Tags.MOD_ID,
31 | category = "profiler")
32 | @Config.LangKey
33 | public class ProfilerConfig {
34 | @Config.Comment("Enable this to dump the profiler data to a file when the F3 profiler is closed.")
35 | @Config.LangKey
36 | @Config.Name(value = "dumpOnClose", migrations = "")
37 | @Config.DefaultBoolean(false)
38 | public static boolean DUMP_ON_CLOSE;
39 |
40 | static {
41 | ConfigurationManager.selfInit();
42 | }
43 |
44 | //This is here to make the static initializer run
45 | public static void init() {
46 |
47 | }
48 | }
49 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/config/TriState.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 | package com.falsepattern.falsetweaks.config;
23 |
24 | public enum TriState {
25 | Disable,
26 | Auto,
27 | Enable
28 | }
29 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/mixin/bridge/occlison/WorldRendererMixinBridge.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 | package com.falsepattern.falsetweaks.mixin.bridge.occlison;
23 |
24 | public interface WorldRendererMixinBridge {
25 | int ft$insertNextPass(int pass);
26 | }
27 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/mixin/mixins/client/animfix/StitcherSlotMixin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.mixin.mixins.client.animfix;
24 |
25 | import com.falsepattern.falsetweaks.modules.animfix.interfaces.IStitcherSlotMixin;
26 | import org.spongepowered.asm.mixin.Mixin;
27 | import org.spongepowered.asm.mixin.Shadow;
28 |
29 | import net.minecraft.client.renderer.texture.Stitcher;
30 |
31 | @Mixin(Stitcher.Slot.class)
32 | public abstract class StitcherSlotMixin implements IStitcherSlotMixin {
33 | @Shadow
34 | private Stitcher.Holder holder;
35 |
36 | @Override
37 | public void insertHolder(Stitcher.Holder holder) {
38 | this.holder = holder;
39 | }
40 | }
41 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/mixin/mixins/client/animfix/fastcraft/AbstractTextureMixin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.mixin.mixins.client.animfix.fastcraft;
24 |
25 | import org.spongepowered.asm.mixin.Mixin;
26 | import org.spongepowered.asm.mixin.injection.At;
27 | import org.spongepowered.asm.mixin.injection.Redirect;
28 |
29 | import net.minecraft.client.renderer.texture.AbstractTexture;
30 |
31 |
32 | //Evil black magic class #1
33 | //Revert fastcraft ASM changes
34 | @SuppressWarnings({"UnresolvedMixinReference", "InvalidInjectorMethodSignature", "MixinAnnotationTarget"})
35 | @Mixin(AbstractTexture.class)
36 | public abstract class AbstractTextureMixin {
37 | @Redirect(method = "deleteGlTexture",
38 | at = @At(value = "INVOKE",
39 | target = "Lfastcraft/HC;k(Lnet/minecraft/client/renderer/texture/AbstractTexture;)V",
40 | remap = false),
41 | require = 0,
42 | expect = 0)
43 | private void disableDeleteGlTextureTweak(AbstractTexture dt) {
44 |
45 | }
46 | }
47 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/mixin/mixins/client/animfix/fastcraft/DynamicTextureMixin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.mixin.mixins.client.animfix.fastcraft;
24 |
25 | import org.spongepowered.asm.mixin.Mixin;
26 | import org.spongepowered.asm.mixin.injection.At;
27 | import org.spongepowered.asm.mixin.injection.Redirect;
28 |
29 | import net.minecraft.client.renderer.texture.DynamicTexture;
30 |
31 | //Evil black magic class #2
32 | //Revert fastcraft ASM changes
33 | @SuppressWarnings({"UnresolvedMixinReference", "InvalidInjectorMethodSignature", "MixinAnnotationTarget"})
34 | @Mixin(DynamicTexture.class)
35 | public abstract class DynamicTextureMixin {
36 | @Redirect(method = "updateDynamicTexture",
37 | at = @At(value = "INVOKE",
38 | target = "Lfastcraft/HC;j(Lnet/minecraft/client/renderer/texture/DynamicTexture;)V",
39 | remap = false),
40 | require = 0,
41 | expect = 0)
42 | private void disableUpdateDynamicTextureTweak(DynamicTexture dt) {
43 |
44 | }
45 | }
46 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/mixin/mixins/client/debug/TileEntityRendererDispatcherMixin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.mixin.mixins.client.debug;
24 |
25 | import com.falsepattern.falsetweaks.modules.debug.Debug;
26 | import net.minecraft.client.renderer.tileentity.TileEntityRendererDispatcher;
27 | import net.minecraft.tileentity.TileEntity;
28 | import org.spongepowered.asm.mixin.Mixin;
29 | import org.spongepowered.asm.mixin.injection.At;
30 | import org.spongepowered.asm.mixin.injection.Inject;
31 | import org.spongepowered.asm.mixin.injection.callback.CallbackInfo;
32 |
33 | @Mixin(TileEntityRendererDispatcher.class)
34 | public abstract class TileEntityRendererDispatcherMixin {
35 | @Inject(method = "renderTileEntity",
36 | at = @At("HEAD"),
37 | cancellable = true,
38 | require = 1)
39 | public void renderTileEntity(TileEntity tileEntity, float partialTick, CallbackInfo ci) {
40 | if (Debug.ENABLED && !Debug.tesrRendering)
41 | ci.cancel();
42 | }
43 | }
44 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/mixin/mixins/client/debug/WorldRendererMixin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.mixin.mixins.client.debug;
24 |
25 | import org.spongepowered.asm.mixin.Mixin;
26 | import org.spongepowered.asm.mixin.Shadow;
27 |
28 | import net.minecraft.client.renderer.WorldRenderer;
29 |
30 | @Mixin(WorldRenderer.class)
31 | public abstract class WorldRendererMixin {
32 | @Shadow
33 | public int posX;
34 | @Shadow
35 | public int posY;
36 | @Shadow
37 | public int posZ;
38 |
39 | @Override
40 | public String toString() {
41 | return "WR[X:" + this.posX + "|Y:" + this.posY + "|Z:" + this.posZ + "]";
42 | }
43 | }
44 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/mixin/mixins/client/debug/occlusion/neodymium/GPUMemoryManagerMixin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 | package com.falsepattern.falsetweaks.mixin.mixins.client.debug.occlusion.neodymium;
23 |
24 | import com.falsepattern.falsetweaks.modules.debug.Debug;
25 | import makamys.neodymium.renderer.GPUMemoryManager;
26 | import org.spongepowered.asm.mixin.Mixin;
27 | import org.spongepowered.asm.mixin.injection.At;
28 | import org.spongepowered.asm.mixin.injection.Inject;
29 | import org.spongepowered.asm.mixin.injection.callback.CallbackInfo;
30 |
31 | @Mixin(value = GPUMemoryManager.class,
32 | remap = false)
33 | public abstract class GPUMemoryManagerMixin {
34 | @Inject(method = "runGC",
35 | at = @At("HEAD"),
36 | cancellable = true,
37 | require = 1)
38 | private void noGC(boolean full, CallbackInfo ci) {
39 | if (Debug.ENABLED && !Debug.neodymiumGC)
40 | ci.cancel();
41 | }
42 | }
43 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/mixin/mixins/client/dynlights/nonthread/WorldClientMixin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.mixin.mixins.client.dynlights.nonthread;
24 |
25 | import com.falsepattern.falsetweaks.modules.dynlights.DynamicLightsWorldClient;
26 | import org.spongepowered.asm.mixin.Dynamic;
27 | import org.spongepowered.asm.mixin.Mixin;
28 |
29 | import net.minecraft.client.multiplayer.WorldClient;
30 |
31 | @Mixin(WorldClient.class)
32 | public abstract class WorldClientMixin implements DynamicLightsWorldClient {
33 | @Dynamic
34 | private boolean ft$renderItemInFirstPerson;
35 |
36 | @Override
37 | public boolean ft$renderItemInFirstPerson() {
38 | return ft$renderItemInFirstPerson;
39 | }
40 | }
41 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/mixin/mixins/client/dynlights/thread/WorldClientMixin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.mixin.mixins.client.dynlights.thread;
24 |
25 | import com.falsepattern.falsetweaks.modules.dynlights.DynamicLightsWorldClient;
26 | import com.falsepattern.falsetweaks.modules.threadedupdates.ThreadedChunkUpdateHelper;
27 | import org.spongepowered.asm.mixin.Dynamic;
28 | import org.spongepowered.asm.mixin.Mixin;
29 |
30 | import net.minecraft.client.multiplayer.WorldClient;
31 | import net.minecraft.world.World;
32 |
33 | @Mixin(WorldClient.class)
34 | public abstract class WorldClientMixin implements DynamicLightsWorldClient {
35 | @Dynamic
36 | private boolean ft$renderItemInFirstPerson;
37 |
38 | @Override
39 | public boolean ft$renderItemInFirstPerson() {
40 | return ft$renderItemInFirstPerson && ThreadedChunkUpdateHelper.isMainThread();
41 | }
42 | }
43 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/mixin/mixins/client/misc/BeaconFix_TileEntityBeaconMixin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.mixin.mixins.client.misc;
24 |
25 | import org.spongepowered.asm.mixin.Mixin;
26 |
27 | import net.minecraft.inventory.IInventory;
28 | import net.minecraft.tileentity.TileEntity;
29 | import net.minecraft.tileentity.TileEntityBeacon;
30 |
31 | @Mixin(TileEntityBeacon.class)
32 | public abstract class BeaconFix_TileEntityBeaconMixin extends TileEntity implements IInventory {
33 | @Override
34 | public boolean shouldRenderInPass(int pass) {
35 | return pass == 1;
36 | }
37 | }
38 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/mixin/mixins/client/misc/MinecartEarBlast_WorldClientMixin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 | package com.falsepattern.falsetweaks.mixin.mixins.client.misc;
23 |
24 | import org.spongepowered.asm.mixin.Mixin;
25 | import org.spongepowered.asm.mixin.injection.At;
26 | import org.spongepowered.asm.mixin.injection.Redirect;
27 |
28 | import net.minecraft.client.audio.ISound;
29 | import net.minecraft.client.audio.SoundHandler;
30 | import net.minecraft.client.multiplayer.WorldClient;
31 |
32 | @Mixin(WorldClient.class)
33 | public abstract class MinecartEarBlast_WorldClientMixin {
34 | @Redirect(method = "spawnEntityInWorld",
35 | at = @At(value = "INVOKE",
36 | target = "Lnet/minecraft/client/audio/SoundHandler;playSound(Lnet/minecraft/client/audio/ISound;)V"))
37 | private void shutUp(SoundHandler instance, ISound p_147682_1_) {
38 |
39 | }
40 | }
41 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/mixin/mixins/client/misc/ParticleTransparency_EffectRendererMixin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.mixin.mixins.client.misc;
24 |
25 | import org.spongepowered.asm.mixin.Mixin;
26 | import org.spongepowered.asm.mixin.injection.At;
27 | import org.spongepowered.asm.mixin.injection.Redirect;
28 |
29 | import net.minecraft.client.particle.EffectRenderer;
30 |
31 | @Mixin(EffectRenderer.class)
32 | public abstract class ParticleTransparency_EffectRendererMixin {
33 | @Redirect(method = "renderParticles",
34 | at = @At(value = "INVOKE",
35 | target = "Lorg/lwjgl/opengl/GL11;glDepthMask(Z)V",
36 | ordinal = 0,
37 | remap = false))
38 | private void alwaysDepthMaskParticles(boolean flag) {
39 |
40 | }
41 | }
42 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/mixin/mixins/client/misc/RealmShutUp_RealmsBridgeMixin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 | package com.falsepattern.falsetweaks.mixin.mixins.client.misc;
23 |
24 | import org.spongepowered.asm.mixin.Mixin;
25 | import org.spongepowered.asm.mixin.Overwrite;
26 |
27 | import net.minecraft.client.gui.GuiScreen;
28 | import net.minecraft.realms.RealmsBridge;
29 |
30 | @Mixin(RealmsBridge.class)
31 | public abstract class RealmShutUp_RealmsBridgeMixin {
32 | /**
33 | * @author FalsePattern
34 | * @reason No realms
35 | */
36 | @Overwrite
37 | public void switchToRealms(GuiScreen p_switchToRealms_1_) {
38 |
39 | }
40 | }
41 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/mixin/mixins/client/occlusion/GameSettingsOptionsMixin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.mixin.mixins.client.occlusion;
24 |
25 | import com.falsepattern.falsetweaks.config.OcclusionConfig;
26 | import org.spongepowered.asm.mixin.Mixin;
27 | import org.spongepowered.asm.mixin.injection.At;
28 | import org.spongepowered.asm.mixin.injection.Constant;
29 | import org.spongepowered.asm.mixin.injection.ModifyConstant;
30 | import org.spongepowered.asm.mixin.injection.Slice;
31 |
32 | import net.minecraft.client.settings.GameSettings;
33 |
34 | @Mixin(GameSettings.Options.class)
35 | public abstract class GameSettingsOptionsMixin {
36 | @ModifyConstant(method = "",
37 | slice = @Slice(from = @At(value = "CONSTANT",
38 | args = "stringValue=options.renderDistance")),
39 | constant = @Constant(floatValue = 16.0F,
40 | ordinal = 0),
41 | require = 1)
42 | private static float expandRenderDistance(float constant) {
43 | return OcclusionConfig.RENDER_DISTANCE;
44 | }
45 | }
46 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/mixin/mixins/client/occlusion/GuiVideoSettingsMixin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.mixin.mixins.client.occlusion;
24 |
25 | import org.spongepowered.asm.mixin.Mixin;
26 | import org.spongepowered.asm.mixin.injection.At;
27 | import org.spongepowered.asm.mixin.injection.Redirect;
28 |
29 | import net.minecraft.client.gui.GuiVideoSettings;
30 |
31 | @Mixin(GuiVideoSettings.class)
32 | public class GuiVideoSettingsMixin {
33 | @Redirect(method = "initGui",
34 | at = @At(value = "FIELD",
35 | target = "Lnet/minecraft/client/renderer/OpenGlHelper;field_153197_d:Z"),
36 | require = 0)
37 | private boolean neverUseAdvancedGl() {
38 | return false;
39 | }
40 | }
41 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/mixin/mixins/client/occlusion/MinecraftMixin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 | package com.falsepattern.falsetweaks.mixin.mixins.client.occlusion;
23 |
24 | import com.falsepattern.falsetweaks.modules.occlusion.OcclusionHelpers;
25 | import com.falsepattern.falsetweaks.modules.occlusion.TickTimeTracker;
26 | import org.spongepowered.asm.mixin.Mixin;
27 | import org.spongepowered.asm.mixin.injection.At;
28 | import org.spongepowered.asm.mixin.injection.Inject;
29 | import org.spongepowered.asm.mixin.injection.callback.CallbackInfo;
30 |
31 | import net.minecraft.client.Minecraft;
32 |
33 | @Mixin(Minecraft.class)
34 | public abstract class MinecraftMixin {
35 | @Inject(method = "runGameLoop",
36 | at = @At("HEAD"),
37 | require = 1)
38 | private void recordTickTime(CallbackInfo ci) {
39 | if (OcclusionHelpers.renderer != null) {
40 | OcclusionHelpers.renderer.occlusionRecheckMain = OcclusionHelpers.renderer.occlusionRecheckShadow = true;
41 | }
42 | TickTimeTracker.tick();
43 | }
44 | }
45 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/mixin/mixins/client/occlusion/fastcraft/EntityRendererMixin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.mixin.mixins.client.occlusion.fastcraft;
24 |
25 | import org.spongepowered.asm.mixin.Dynamic;
26 | import org.spongepowered.asm.mixin.Mixin;
27 | import org.spongepowered.asm.mixin.injection.At;
28 | import org.spongepowered.asm.mixin.injection.Redirect;
29 |
30 | import net.minecraft.client.renderer.EntityRenderer;
31 | import net.minecraft.client.renderer.RenderGlobal;
32 | import net.minecraft.entity.EntityLivingBase;
33 |
34 | @Mixin(EntityRenderer.class)
35 | public abstract class EntityRendererMixin {
36 | @Dynamic
37 | @Redirect(method = "renderWorld",
38 | at = @At(value = "INVOKE",
39 | target = "Lfastcraft/HC;t(Lnet/minecraft/client/renderer/RenderGlobal;Lnet/minecraft/entity/EntityLivingBase;Z)Z",
40 | remap = false),
41 | require = 1)
42 | private boolean unhookUpdateRenderers(RenderGlobal instance, EntityLivingBase entity, boolean bool) {
43 | return instance.updateRenderers(entity, bool);
44 | }
45 | }
46 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/mixin/mixins/client/occlusion/optifine/shaders/FrustrumMixin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 | package com.falsepattern.falsetweaks.mixin.mixins.client.occlusion.optifine.shaders;
23 |
24 | import org.spongepowered.asm.mixin.Dynamic;
25 | import org.spongepowered.asm.mixin.Mixin;
26 | import org.spongepowered.asm.mixin.injection.At;
27 | import org.spongepowered.asm.mixin.injection.Redirect;
28 |
29 | import net.minecraft.client.renderer.culling.ClippingHelper;
30 | import net.minecraft.client.renderer.culling.Frustrum;
31 |
32 | @Mixin(Frustrum.class)
33 | public abstract class FrustrumMixin {
34 | @Dynamic
35 | @Redirect(method = "(Lnet/minecraft/client/renderer/culling/ClippingHelper;)V",
36 | at = @At(value = "INVOKE",
37 | target = "Lnet/minecraft/client/renderer/culling/ClippingHelperImpl;getInstance()Lnet/minecraft/client/renderer/culling/ClippingHelper;"),
38 | require = 1)
39 | private ClippingHelper noClippingHelperForShadow() {
40 | return null;
41 | }
42 | }
43 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/mixin/mixins/client/occlusion/optifine/shaders/ShadersMixin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.mixin.mixins.client.occlusion.optifine.shaders;
24 |
25 | import com.falsepattern.falsetweaks.modules.occlusion.shader.ShadowPassOcclusionHelper;
26 | import org.spongepowered.asm.mixin.Final;
27 | import org.spongepowered.asm.mixin.Mixin;
28 | import org.spongepowered.asm.mixin.Shadow;
29 | import org.spongepowered.asm.mixin.injection.At;
30 | import org.spongepowered.asm.mixin.injection.Inject;
31 | import org.spongepowered.asm.mixin.injection.callback.CallbackInfo;
32 | import shadersmod.client.Shaders;
33 |
34 | import java.nio.FloatBuffer;
35 |
36 | @Mixin(value = Shaders.class,
37 | remap = false)
38 | public abstract class ShadersMixin {
39 | @Shadow @Final static FloatBuffer shadowModelView;
40 |
41 | @Inject(method = "setCameraShadow",
42 | at = @At("RETURN"),
43 | require = 1)
44 | private static void onSetCameraShadow(CallbackInfo ci) {
45 | shadowModelView.position(0);
46 | ShadowPassOcclusionHelper.shadowModelViewMatrix.set(shadowModelView);
47 | }
48 | }
49 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/mixin/mixins/client/occlusion/optifine/shaders/ShadersRendererMixin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.mixin.mixins.client.occlusion.optifine.shaders;
24 |
25 | import org.spongepowered.asm.mixin.Mixin;
26 | import org.spongepowered.asm.mixin.injection.At;
27 | import org.spongepowered.asm.mixin.injection.Redirect;
28 | import shadersmod.client.ShadersRender;
29 |
30 | import net.minecraft.client.renderer.RenderGlobal;
31 | import net.minecraft.client.renderer.WorldRenderer;
32 |
33 | @Mixin(ShadersRender.class)
34 | public abstract class ShadersRendererMixin {
35 | private static WorldRenderer[] ft$nullArray;
36 |
37 | @Redirect(method = "renderShadowMap",
38 | at = @At(value = "FIELD",
39 | target = "Lnet/minecraft/client/renderer/RenderGlobal;worldRenderers:[Lnet/minecraft/client/renderer/WorldRenderer;"),
40 | require = 1)
41 | private static WorldRenderer[] disableShadowMapFrustrumToggling(RenderGlobal instance) {
42 | if (ft$nullArray == null) {
43 | return (ft$nullArray = new WorldRenderer[0]);
44 | }
45 | return ft$nullArray;
46 | }
47 | }
48 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/mixin/mixins/client/optispam/ConnectedParserMixin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.mixin.mixins.client.optispam;
24 |
25 | import com.falsepattern.falsetweaks.config.OptiSpamConfig;
26 | import org.spongepowered.asm.mixin.Mixin;
27 | import org.spongepowered.asm.mixin.injection.At;
28 | import org.spongepowered.asm.mixin.injection.Redirect;
29 | import stubpackage.Config;
30 |
31 | @Mixin(targets = "ConnectedParser",
32 | remap = false)
33 | public abstract class ConnectedParserMixin {
34 | @Redirect(method = "warn",
35 | at = @At(value = "INVOKE",
36 | target = "LConfig;warn(Ljava/lang/String;)V"))
37 | private void suppressWarn(String s) {
38 | if (!OptiSpamConfig.BLOCK_NOT_FOUND) {
39 | Config.warn(s);
40 | }
41 | }
42 | }
43 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/mixin/mixins/client/optispam/ShaderExpressionResolverMixin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.mixin.mixins.client.optispam;
24 |
25 | import com.falsepattern.falsetweaks.config.OptiSpamConfig;
26 | import org.spongepowered.asm.mixin.Mixin;
27 | import org.spongepowered.asm.mixin.injection.At;
28 | import org.spongepowered.asm.mixin.injection.Redirect;
29 | import shadersmod.common.SMCLog;
30 | import shadersmod.uniform.ShaderExpressionResolver;
31 |
32 | @Mixin(value = ShaderExpressionResolver.class,
33 | remap = false)
34 | public abstract class ShaderExpressionResolverMixin {
35 | @Redirect(method = "registerExpression",
36 | at = @At(value = "INVOKE",
37 | target = "Lshadersmod/common/SMCLog;warning(Ljava/lang/String;)V"))
38 | private void suppressWarn(String message) {
39 | if (!OptiSpamConfig.CUSTOM_UNIFORMS) {
40 | SMCLog.warning(message);
41 | }
42 | }
43 | }
44 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/mixin/mixins/client/rendersafety/RenderHelperMixin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.mixin.mixins.client.rendersafety;
24 |
25 | import org.spongepowered.asm.mixin.Mixin;
26 | import org.spongepowered.asm.mixin.injection.At;
27 | import org.spongepowered.asm.mixin.injection.Inject;
28 | import org.spongepowered.asm.mixin.injection.callback.CallbackInfo;
29 |
30 | import net.minecraft.client.renderer.OpenGlHelper;
31 | import net.minecraft.client.renderer.RenderHelper;
32 |
33 | @Mixin(RenderHelper.class)
34 | public abstract class RenderHelperMixin {
35 | @Inject(method = "enableStandardItemLighting",
36 | at = @At("RETURN"),
37 | require = 1)
38 | private static void clearLight(CallbackInfo ci) {
39 | OpenGlHelper.setLightmapTextureCoords(OpenGlHelper.lightmapTexUnit, 240, 240);
40 | }
41 | }
42 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/mixin/mixins/client/threadedupdates/ForgeHooksClientMixin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 | package com.falsepattern.falsetweaks.mixin.mixins.client.threadedupdates;
23 |
24 | import com.falsepattern.falsetweaks.modules.threadedupdates.ThreadedChunkUpdateHelper;
25 | import com.falsepattern.falsetweaks.modules.threadedupdates.ThreadedClientHooks;
26 | import net.minecraftforge.client.ForgeHooksClient;
27 | import org.spongepowered.asm.mixin.Mixin;
28 | import org.spongepowered.asm.mixin.Overwrite;
29 | import org.spongepowered.asm.mixin.Shadow;
30 |
31 | @Mixin(value = ForgeHooksClient.class,
32 | remap = false)
33 | public abstract class ForgeHooksClientMixin {
34 | @Shadow
35 | private static int worldRenderPass;
36 |
37 | /**
38 | * @author FalsePattern
39 | * @reason Thread-safe
40 | */
41 | @Overwrite
42 | public static int getWorldRenderPass() {
43 | return ThreadedChunkUpdateHelper.isMainThread() ? worldRenderPass : ThreadedClientHooks.threadRenderPass.get();
44 | }
45 | }
46 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/mixin/mixins/client/threadedupdates/OpenGLHelperMixin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.mixin.mixins.client.threadedupdates;
24 |
25 | import com.falsepattern.falsetweaks.modules.threadedupdates.ThreadedChunkUpdateHelper;
26 | import org.spongepowered.asm.mixin.Mixin;
27 | import org.spongepowered.asm.mixin.injection.At;
28 | import org.spongepowered.asm.mixin.injection.Inject;
29 | import org.spongepowered.asm.mixin.injection.callback.CallbackInfo;
30 |
31 | import net.minecraft.client.renderer.OpenGlHelper;
32 |
33 | @Mixin(value = OpenGlHelper.class,
34 | priority = 900)
35 | public abstract class OpenGLHelperMixin {
36 | @Inject(method = "setLightmapTextureCoords",
37 | at = @At("HEAD"),
38 | cancellable = true,
39 | require = 1)
40 | private static void onlyIfMainThread(int target, float x, float y, CallbackInfo ci) {
41 | if (!ThreadedChunkUpdateHelper.isMainThread()) {
42 | ci.cancel();
43 | }
44 | }
45 | }
46 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/mixin/mixins/client/threadedupdates/RenderingRegistryMixin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.mixin.mixins.client.threadedupdates;
24 |
25 | import com.falsepattern.falsetweaks.modules.threadedupdates.IRenderingRegistryExt;
26 | import org.spongepowered.asm.mixin.Mixin;
27 | import org.spongepowered.asm.mixin.Shadow;
28 |
29 | import net.minecraft.block.Block;
30 | import cpw.mods.fml.client.registry.ISimpleBlockRenderingHandler;
31 | import cpw.mods.fml.client.registry.RenderingRegistry;
32 |
33 | import java.util.Map;
34 |
35 | @Mixin(value = RenderingRegistry.class,
36 | remap = false)
37 | public abstract class RenderingRegistryMixin implements IRenderingRegistryExt {
38 | @Shadow private Map blockRenderers;
39 |
40 | @Override
41 | public ISimpleBlockRenderingHandler getISBRH(Block block) {
42 | return blockRenderers.get(block.getRenderType());
43 | }
44 | }
45 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/mixin/mixins/client/threadedupdates/computronics/LampRenderMixin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 | package com.falsepattern.falsetweaks.mixin.mixins.client.threadedupdates.computronics;
23 |
24 | import org.spongepowered.asm.mixin.Mixin;
25 | import org.spongepowered.asm.mixin.injection.At;
26 | import org.spongepowered.asm.mixin.injection.Redirect;
27 | import pl.asie.computronics.client.LampRender;
28 |
29 | import cpw.mods.fml.client.registry.ISimpleBlockRenderingHandler;
30 |
31 | @Mixin(value = LampRender.class,
32 | remap = false)
33 | public abstract class LampRenderMixin implements ISimpleBlockRenderingHandler {
34 | @Redirect(method = "renderWorldBlock",
35 | at = @At(value = "INVOKE",
36 | target = "Lorg/lwjgl/opengl/GL11;glPushMatrix()V"),
37 | require = 1)
38 | private void skipGLPushMatrix() {
39 | }
40 |
41 | @Redirect(method = "renderWorldBlock",
42 | at = @At(value = "INVOKE",
43 | target = "Lorg/lwjgl/opengl/GL11;glPopMatrix()V"),
44 | require = 1)
45 | private void skipGLPopMatrix() {
46 | }
47 | }
48 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/mixin/mixins/client/threadedupdates/dragonapi/WorldRenderer_VanillaMixin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.mixin.mixins.client.threadedupdates.dragonapi;
24 |
25 | import com.falsepattern.falsetweaks.modules.threadedupdates.ThreadedChunkUpdateHelper;
26 | import org.spongepowered.asm.mixin.Mixin;
27 | import org.spongepowered.asm.mixin.injection.At;
28 | import org.spongepowered.asm.mixin.injection.Inject;
29 | import org.spongepowered.asm.mixin.injection.callback.CallbackInfo;
30 |
31 | import net.minecraft.client.renderer.WorldRenderer;
32 |
33 | @Mixin(WorldRenderer.class)
34 | public abstract class WorldRenderer_VanillaMixin {
35 |
36 | @Inject(method = "updateRenderer",
37 | at = @At(value = "INVOKE",
38 | target = "Lnet/minecraft/client/renderer/RenderBlocks;renderBlockByRenderType(Lnet/minecraft/block/Block;III)Z"),
39 | require = 2)
40 | private void resetStack(CallbackInfo ci) {
41 | // Make sure the stack doesn't leak
42 | ThreadedChunkUpdateHelper.renderBlocksStack.reset();
43 | }
44 |
45 | }
46 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/mixin/mixins/client/threadedupdates/nuclearcontrol/TileEntityAdvancedInfoPanelMixin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 | package com.falsepattern.falsetweaks.mixin.mixins.client.threadedupdates.nuclearcontrol;
23 |
24 | import org.spongepowered.asm.mixin.Mixin;
25 | import org.spongepowered.asm.mixin.Pseudo;
26 | import shedar.mods.ic2.nuclearcontrol.tileentities.TileEntityAdvancedInfoPanel;
27 |
28 | import net.minecraft.util.AxisAlignedBB;
29 |
30 | import static net.minecraft.tileentity.TileEntity.INFINITE_EXTENT_AABB;
31 |
32 | @Pseudo // This is like this just to avoid pulling in IC2 dep unless we need it elsewhere
33 | @Mixin(TileEntityAdvancedInfoPanel.class)
34 | public abstract class TileEntityAdvancedInfoPanelMixin /*extends TileEntityInfoPanel*/ {
35 | // TODO: Fix properly
36 | /*@Override*/
37 | public AxisAlignedBB getRenderBoundingBox() {
38 | return INFINITE_EXTENT_AABB;
39 | }
40 | }
41 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/mixin/mixins/client/threadedupdates/opencomputers/RenderStateMixin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 | package com.falsepattern.falsetweaks.mixin.mixins.client.threadedupdates.opencomputers;
23 |
24 | import com.falsepattern.falsetweaks.modules.threadedupdates.ThreadedChunkUpdateHelper;
25 | import li.cil.oc.util.RenderState$;
26 | import org.lwjgl.opengl.GL11;
27 | import org.spongepowered.asm.mixin.Mixin;
28 | import org.spongepowered.asm.mixin.injection.At;
29 | import org.spongepowered.asm.mixin.injection.Redirect;
30 |
31 | @Mixin(value = RenderState$.class,
32 | remap = false)
33 | public abstract class RenderStateMixin {
34 | @Redirect(method = "checkError",
35 | at = @At(value = "INVOKE",
36 | target = "Lorg/lwjgl/opengl/GL11;glGetError()I"),
37 | require = 1)
38 | private int noErrorOffMainThread() {
39 | if (ThreadedChunkUpdateHelper.isMainThread()) {
40 | return GL11.glGetError();
41 | }
42 | return GL11.GL_NO_ERROR;
43 | }
44 | }
45 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/mixin/mixins/client/threadedupdates/storagedrawers/CommonDrawerRendererMixin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.mixin.mixins.client.threadedupdates.storagedrawers;
24 |
25 | import com.falsepattern.falsetweaks.modules.threadedupdates.interop.StorageDrawersCompat;
26 | import com.jaquadro.minecraft.storagedrawers.client.renderer.common.CommonDrawerRenderer;
27 | import com.jaquadro.minecraft.storagedrawers.util.RenderHelper;
28 | import org.spongepowered.asm.mixin.Mixin;
29 | import org.spongepowered.asm.mixin.injection.At;
30 | import org.spongepowered.asm.mixin.injection.Redirect;
31 |
32 | @Mixin(value = CommonDrawerRenderer.class, remap = false)
33 | public abstract class CommonDrawerRendererMixin {
34 | @Redirect(method = {"start", "end", "renderOverlayPass"},
35 | at = @At(value = "FIELD",
36 | target = "Lcom/jaquadro/minecraft/storagedrawers/util/RenderHelper;instance:Lcom/jaquadro/minecraft/storagedrawers/util/RenderHelper;"),
37 | require = 3)
38 | private RenderHelper threadSafeGet() {
39 | return StorageDrawersCompat.instances.get();
40 | }
41 | }
42 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/mixin/mixins/client/threadedupdates/storagedrawers/CommonTrimRendererMixin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.mixin.mixins.client.threadedupdates.storagedrawers;
24 |
25 | import com.falsepattern.falsetweaks.modules.threadedupdates.interop.StorageDrawersCompat;
26 | import com.jaquadro.minecraft.storagedrawers.client.renderer.common.CommonTrimRenderer;
27 | import com.jaquadro.minecraft.storagedrawers.util.RenderHelper;
28 | import org.spongepowered.asm.mixin.Mixin;
29 | import org.spongepowered.asm.mixin.injection.At;
30 | import org.spongepowered.asm.mixin.injection.Redirect;
31 |
32 | @Mixin(value = CommonTrimRenderer.class, remap = false)
33 | public abstract class CommonTrimRendererMixin {
34 | @Redirect(method = "start",
35 | at = @At(value = "FIELD",
36 | target = "Lcom/jaquadro/minecraft/storagedrawers/util/RenderHelper;instance:Lcom/jaquadro/minecraft/storagedrawers/util/RenderHelper;"),
37 | require = 1)
38 | private RenderHelper threadSafeGet() {
39 | return StorageDrawersCompat.instances.get();
40 | }
41 | }
42 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/mixin/mixins/client/threadedupdates/storagedrawers/DrawersItemRendererMixin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.mixin.mixins.client.threadedupdates.storagedrawers;
24 |
25 | import com.falsepattern.falsetweaks.modules.threadedupdates.interop.StorageDrawersCompat;
26 | import com.jaquadro.minecraft.storagedrawers.client.renderer.DrawersItemRenderer;
27 | import com.jaquadro.minecraft.storagedrawers.util.RenderHelper;
28 | import org.spongepowered.asm.mixin.Mixin;
29 | import org.spongepowered.asm.mixin.injection.At;
30 | import org.spongepowered.asm.mixin.injection.Redirect;
31 |
32 | @Mixin(value = DrawersItemRenderer.class, remap = false)
33 | public abstract class DrawersItemRendererMixin {
34 | @Redirect(method = {"renderDrawer", "renderBaseBlock"},
35 | at = @At(value = "FIELD",
36 | target = "Lcom/jaquadro/minecraft/storagedrawers/util/RenderHelper;instance:Lcom/jaquadro/minecraft/storagedrawers/util/RenderHelper;"),
37 | require = 4)
38 | private RenderHelper threadSafeGet() {
39 | return StorageDrawersCompat.instances.get();
40 | }
41 | }
42 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/mixin/mixins/client/threadedupdates/storagedrawers/FramingTableRendererMixin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.mixin.mixins.client.threadedupdates.storagedrawers;
24 |
25 | import com.falsepattern.falsetweaks.modules.threadedupdates.interop.StorageDrawersCompat;
26 | import com.jaquadro.minecraft.storagedrawers.client.renderer.FramingTableRenderer;
27 | import com.jaquadro.minecraft.storagedrawers.util.RenderHelper;
28 | import org.spongepowered.asm.mixin.Mixin;
29 | import org.spongepowered.asm.mixin.injection.At;
30 | import org.spongepowered.asm.mixin.injection.Redirect;
31 |
32 | @Mixin(value = FramingTableRenderer.class, remap = false)
33 | public abstract class FramingTableRendererMixin {
34 | @Redirect(method = {"renderInventoryBlock", "renderWorldBlock", "renderWorldBlock"},
35 | at = @At(value = "FIELD",
36 | target = "Lcom/jaquadro/minecraft/storagedrawers/util/RenderHelper;instance:Lcom/jaquadro/minecraft/storagedrawers/util/RenderHelper;"),
37 | require = 8)
38 | private RenderHelper threadSafeGet() {
39 | return StorageDrawersCompat.instances.get();
40 | }
41 | }
42 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/mixin/mixins/client/threadedupdates/storagedrawers/ModularBoxRendererMixin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.mixin.mixins.client.threadedupdates.storagedrawers;
24 |
25 | import com.falsepattern.falsetweaks.modules.threadedupdates.interop.StorageDrawersCompat;
26 | import com.jaquadro.minecraft.storagedrawers.client.renderer.ModularBoxRenderer;
27 | import com.jaquadro.minecraft.storagedrawers.util.RenderHelper;
28 | import org.spongepowered.asm.mixin.Mixin;
29 | import org.spongepowered.asm.mixin.injection.At;
30 | import org.spongepowered.asm.mixin.injection.Redirect;
31 |
32 | @Mixin(value = ModularBoxRenderer.class, remap = false)
33 | public abstract class ModularBoxRendererMixin {
34 | @Redirect(method = {"renderExterior", "renderInterior", "renderFace"},
35 | at = @At(value = "FIELD",
36 | target = "Lcom/jaquadro/minecraft/storagedrawers/util/RenderHelper;instance:Lcom/jaquadro/minecraft/storagedrawers/util/RenderHelper;"),
37 | require = 3)
38 | private RenderHelper threadSafeGet() {
39 | return StorageDrawersCompat.instances.get();
40 | }
41 | }
42 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/mixin/mixins/client/threadedupdates/storagedrawers/RenderHelperMixin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.mixin.mixins.client.threadedupdates.storagedrawers;
24 |
25 | import com.jaquadro.minecraft.storagedrawers.util.RenderHelper;
26 | import org.spongepowered.asm.mixin.Mixin;
27 | import org.spongepowered.asm.mixin.injection.At;
28 | import org.spongepowered.asm.mixin.injection.Inject;
29 | import org.spongepowered.asm.mixin.injection.callback.CallbackInfo;
30 |
31 | @Mixin(value = RenderHelper.class, remap = false)
32 | public abstract class RenderHelperMixin {
33 | @Inject(method = "",
34 | at = @At("RETURN"),
35 | require = 1)
36 | private static void postStaticInit(CallbackInfo ci) {
37 | RenderHelper.instance = null; // Nulled out, so anything that would try to use it will NPE instantly
38 | }
39 | }
40 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/mixin/mixins/client/threadedupdates/techguns/RenderLadderMixin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.mixin.mixins.client.threadedupdates.techguns;
24 |
25 | import org.spongepowered.asm.mixin.Mixin;
26 | import org.spongepowered.asm.mixin.Overwrite;
27 | import techguns.client.renderer.block.RenderLadder;
28 |
29 | import net.minecraft.block.Block;
30 | import net.minecraft.world.IBlockAccess;
31 |
32 | @Mixin(value = RenderLadder.class,
33 | remap = false)
34 | public abstract class RenderLadderMixin {
35 | /**
36 | * @author FalsePattern
37 | * @reason This method is stupid
38 | */
39 | @Overwrite
40 | private void adjustLightFixture(IBlockAccess world, int i, int j, int k, Block block) {
41 | }
42 | }
43 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/mixin/mixins/client/threadedupdates/thermalexpansion/BlockCellMixin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.mixin.mixins.client.threadedupdates.thermalexpansion;
24 |
25 | import cofh.thermalexpansion.block.cell.BlockCell;
26 | import com.falsepattern.falsetweaks.modules.threadedupdates.interop.ThermalExpansionCompat;
27 | import org.objectweb.asm.Opcodes;
28 | import org.spongepowered.asm.mixin.Mixin;
29 | import org.spongepowered.asm.mixin.injection.At;
30 | import org.spongepowered.asm.mixin.injection.Redirect;
31 |
32 | @Mixin(value = BlockCell.class,
33 | remap = false)
34 | public abstract class BlockCellMixin {
35 | @Redirect(method = "canRenderInPass",
36 | at = @At(value = "FIELD",
37 | opcode = Opcodes.PUTSTATIC,
38 | target = "Lcofh/core/block/BlockCoFHBase;renderPass:I"),
39 | require = 1)
40 | private void redirectSetRenderPass(int pass) {
41 | ThermalExpansionCompat.setCofhBlockRenderPass(pass);
42 | }
43 | }
44 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/mixin/mixins/client/threadedupdates/thermalexpansion/BlockEnderMixin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.mixin.mixins.client.threadedupdates.thermalexpansion;
24 |
25 | import cofh.thermalexpansion.block.ender.BlockEnder;
26 | import com.falsepattern.falsetweaks.modules.threadedupdates.interop.ThermalExpansionCompat;
27 | import org.objectweb.asm.Opcodes;
28 | import org.spongepowered.asm.mixin.Mixin;
29 | import org.spongepowered.asm.mixin.injection.At;
30 | import org.spongepowered.asm.mixin.injection.Redirect;
31 |
32 | @Mixin(BlockEnder.class)
33 | public abstract class BlockEnderMixin {
34 | @Redirect(method = "canRenderInPass",
35 | at = @At(value = "FIELD",
36 | opcode = Opcodes.PUTSTATIC,
37 | target = "Lcofh/core/block/BlockCoFHBase;renderPass:I",
38 | remap = false),
39 | remap = false,
40 | require = 1)
41 | private void redirectSetRenderPass(int pass) {
42 | ThermalExpansionCompat.setCofhBlockRenderPass(pass);
43 | }
44 | }
45 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/mixin/mixins/client/threadedupdates/thermalexpansion/BlockFrameMixin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.mixin.mixins.client.threadedupdates.thermalexpansion;
24 |
25 | import cofh.thermalexpansion.block.simple.BlockFrame;
26 | import com.falsepattern.falsetweaks.modules.threadedupdates.interop.ThermalExpansionCompat;
27 | import org.objectweb.asm.Opcodes;
28 | import org.spongepowered.asm.mixin.Mixin;
29 | import org.spongepowered.asm.mixin.injection.At;
30 | import org.spongepowered.asm.mixin.injection.Redirect;
31 |
32 | @Mixin(BlockFrame.class)
33 | public abstract class BlockFrameMixin {
34 | @Redirect(method = "canRenderInPass",
35 | at = @At(value = "FIELD",
36 | opcode = Opcodes.PUTSTATIC,
37 | target = "Lcofh/thermalexpansion/block/simple/BlockFrame;renderPass:I",
38 | remap = false),
39 | remap = false,
40 | require = 1)
41 | private void redirectSetRenderPass(int pass) {
42 | ThermalExpansionCompat.setFrameBlockRenderPass(pass);
43 | }
44 | }
45 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/mixin/mixins/client/threadedupdates/thermalexpansion/BlockLightMixin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.mixin.mixins.client.threadedupdates.thermalexpansion;
24 |
25 | import cofh.thermalexpansion.block.light.BlockLight;
26 | import com.falsepattern.falsetweaks.modules.threadedupdates.interop.ThermalExpansionCompat;
27 | import org.objectweb.asm.Opcodes;
28 | import org.spongepowered.asm.mixin.Mixin;
29 | import org.spongepowered.asm.mixin.injection.At;
30 | import org.spongepowered.asm.mixin.injection.Redirect;
31 |
32 | @Mixin(BlockLight.class)
33 | public abstract class BlockLightMixin {
34 | @Redirect(method = "canRenderInPass",
35 | at = @At(value = "FIELD",
36 | opcode = Opcodes.PUTSTATIC,
37 | target = "Lcofh/core/block/BlockCoFHBase;renderPass:I",
38 | remap = false),
39 | remap = false,
40 | require = 1)
41 | private void redirectSetRenderPass(int pass) {
42 | ThermalExpansionCompat.setCofhBlockRenderPass(pass);
43 | }
44 | }
45 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/mixin/mixins/client/threadedupdates/thermalexpansion/BlockSpongeMixin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.mixin.mixins.client.threadedupdates.thermalexpansion;
24 |
25 | import cofh.thermalexpansion.block.sponge.BlockSponge;
26 | import com.falsepattern.falsetweaks.modules.threadedupdates.interop.ThermalExpansionCompat;
27 | import org.objectweb.asm.Opcodes;
28 | import org.spongepowered.asm.mixin.Mixin;
29 | import org.spongepowered.asm.mixin.injection.At;
30 | import org.spongepowered.asm.mixin.injection.Redirect;
31 |
32 | @Mixin(BlockSponge.class)
33 | public abstract class BlockSpongeMixin {
34 | @Redirect(method = "getIcon(Lnet/minecraft/world/IBlockAccess;IIII)Lnet/minecraft/util/IIcon;",
35 | at = @At(value = "FIELD",
36 | opcode = Opcodes.GETSTATIC,
37 | target = "Lcofh/core/block/BlockCoFHBase;renderPass:I",
38 | remap = false),
39 | require = 1)
40 | private int redirectGetRenderPass() {
41 | return ThermalExpansionCompat.getCofhBlockRenderPass();
42 | }
43 | }
44 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/mixin/mixins/client/threadedupdates/thermalexpansion/BlockTankMixin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.mixin.mixins.client.threadedupdates.thermalexpansion;
24 |
25 | import cofh.thermalexpansion.block.tank.BlockTank;
26 | import com.falsepattern.falsetweaks.modules.threadedupdates.interop.ThermalExpansionCompat;
27 | import org.objectweb.asm.Opcodes;
28 | import org.spongepowered.asm.mixin.Mixin;
29 | import org.spongepowered.asm.mixin.injection.At;
30 | import org.spongepowered.asm.mixin.injection.Redirect;
31 |
32 | @Mixin(BlockTank.class)
33 | public abstract class BlockTankMixin {
34 | @Redirect(method = "canRenderInPass",
35 | at = @At(value = "FIELD",
36 | opcode = Opcodes.PUTSTATIC,
37 | target = "Lcofh/core/block/BlockCoFHBase;renderPass:I",
38 | remap = false),
39 | remap = false,
40 | require = 1)
41 | private void redirectSetRenderPass(int pass) {
42 | ThermalExpansionCompat.setCofhBlockRenderPass(pass);
43 | }
44 | }
45 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/mixin/mixins/client/threadedupdates/thermalexpansion/RenderCellMixin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.mixin.mixins.client.threadedupdates.thermalexpansion;
24 |
25 | import cofh.thermalexpansion.render.RenderCell;
26 | import com.falsepattern.falsetweaks.modules.threadedupdates.interop.ThermalExpansionCompat;
27 | import org.objectweb.asm.Opcodes;
28 | import org.spongepowered.asm.mixin.Mixin;
29 | import org.spongepowered.asm.mixin.injection.At;
30 | import org.spongepowered.asm.mixin.injection.Redirect;
31 |
32 | @Mixin(value = RenderCell.class,
33 | remap = false)
34 | public abstract class RenderCellMixin {
35 | @Redirect(method = "renderWorldBlock",
36 | at = @At(value = "FIELD",
37 | opcode = Opcodes.GETSTATIC,
38 | target = "Lcofh/core/block/BlockCoFHBase;renderPass:I"),
39 | require = 1)
40 | private int redirectGetRenderPass() {
41 | return ThermalExpansionCompat.getCofhBlockRenderPass();
42 | }
43 | }
44 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/mixin/mixins/client/threadedupdates/thermalexpansion/RenderFrameMixin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.mixin.mixins.client.threadedupdates.thermalexpansion;
24 |
25 | import cofh.thermalexpansion.render.RenderFrame;
26 | import com.falsepattern.falsetweaks.modules.threadedupdates.interop.ThermalExpansionCompat;
27 | import org.objectweb.asm.Opcodes;
28 | import org.spongepowered.asm.mixin.Mixin;
29 | import org.spongepowered.asm.mixin.injection.At;
30 | import org.spongepowered.asm.mixin.injection.Redirect;
31 |
32 | @Mixin(value = RenderFrame.class,
33 | remap = false)
34 | public abstract class RenderFrameMixin {
35 | @Redirect(method = "renderWorldBlock",
36 | at = @At(value = "FIELD",
37 | opcode = Opcodes.GETSTATIC,
38 | target = "Lcofh/thermalexpansion/block/simple/BlockFrame;renderPass:I"),
39 | require = 1)
40 | private int redirectGetRenderPass() {
41 | return ThermalExpansionCompat.getFrameBlockRenderPass();
42 | }
43 | }
44 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/mixin/mixins/client/threadedupdates/thermalexpansion/RenderLightMixin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.mixin.mixins.client.threadedupdates.thermalexpansion;
24 |
25 | import cofh.thermalexpansion.render.RenderLight;
26 | import com.falsepattern.falsetweaks.modules.threadedupdates.interop.ThermalExpansionCompat;
27 | import org.objectweb.asm.Opcodes;
28 | import org.spongepowered.asm.mixin.Mixin;
29 | import org.spongepowered.asm.mixin.injection.At;
30 | import org.spongepowered.asm.mixin.injection.Redirect;
31 |
32 | @Mixin(value = RenderLight.class,
33 | remap = false)
34 | public abstract class RenderLightMixin {
35 | @Redirect(method = "renderWorldBlock",
36 | at = @At(value = "FIELD",
37 | opcode = Opcodes.GETSTATIC,
38 | target = "Lcofh/core/block/BlockCoFHBase;renderPass:I"),
39 | require = 1)
40 | private int redirectGetRenderPass() {
41 | return ThermalExpansionCompat.getCofhBlockRenderPass();
42 | }
43 | }
44 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/mixin/mixins/client/threadedupdates/thermalexpansion/RenderTankMixin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.mixin.mixins.client.threadedupdates.thermalexpansion;
24 |
25 | import cofh.thermalexpansion.render.RenderTank;
26 | import com.falsepattern.falsetweaks.modules.threadedupdates.interop.ThermalExpansionCompat;
27 | import org.objectweb.asm.Opcodes;
28 | import org.spongepowered.asm.mixin.Mixin;
29 | import org.spongepowered.asm.mixin.injection.At;
30 | import org.spongepowered.asm.mixin.injection.Redirect;
31 |
32 | @Mixin(value = RenderTank.class,
33 | remap = false)
34 | public abstract class RenderTankMixin {
35 | @Redirect(method = "renderWorldBlock",
36 | at = @At(value = "FIELD",
37 | opcode = Opcodes.GETSTATIC,
38 | target = "Lcofh/core/block/BlockCoFHBase;renderPass:I"),
39 | require = 1)
40 | private int redirectGetRenderPass() {
41 | org.lwjgl.opengl.GL11.glPushMatrix();
42 | // Their code here
43 | org.lwjgl.opengl.GL11.glPopMatrix();
44 |
45 | return ThermalExpansionCompat.getCofhBlockRenderPass();
46 | }
47 | }
48 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/mixin/mixins/client/threadedupdates/thermalexpansion/RenderTesseractMixin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.mixin.mixins.client.threadedupdates.thermalexpansion;
24 |
25 | import cofh.thermalexpansion.render.RenderTesseract;
26 | import com.falsepattern.falsetweaks.modules.threadedupdates.interop.ThermalExpansionCompat;
27 | import org.objectweb.asm.Opcodes;
28 | import org.spongepowered.asm.mixin.Mixin;
29 | import org.spongepowered.asm.mixin.injection.At;
30 | import org.spongepowered.asm.mixin.injection.Redirect;
31 |
32 | @Mixin(value = RenderTesseract.class,
33 | remap = false)
34 | public abstract class RenderTesseractMixin {
35 | @Redirect(method = "renderWorldBlock",
36 | at = @At(value = "FIELD",
37 | opcode = Opcodes.GETSTATIC,
38 | target = "Lcofh/core/block/BlockCoFHBase;renderPass:I"),
39 | require = 1)
40 | private int redirectGetRenderPass() {
41 | return ThermalExpansionCompat.getCofhBlockRenderPass();
42 | }
43 | }
44 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/mixin/mixins/client/triangulator/RenderBlocksCompatMixin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.mixin.mixins.client.triangulator;
24 |
25 | import com.falsepattern.falsetweaks.modules.triangulator.interfaces.IRenderBlocksMixin;
26 | import org.spongepowered.asm.mixin.Mixin;
27 | import org.spongepowered.asm.mixin.injection.At;
28 | import org.spongepowered.asm.mixin.injection.Inject;
29 | import org.spongepowered.asm.mixin.injection.callback.CallbackInfoReturnable;
30 |
31 | import net.minecraft.block.Block;
32 | import net.minecraft.client.renderer.RenderBlocks;
33 |
34 | @Mixin(RenderBlocks.class)
35 | public abstract class RenderBlocksCompatMixin implements IRenderBlocksMixin {
36 | @Inject(method = {"renderStandardBlockWithAmbientOcclusion", "renderStandardBlockWithAmbientOcclusionPartial"},
37 | at = @At("HEAD"),
38 | cancellable = true,
39 | require = 2)
40 | public void renderWithAOHook(Block block, int x, int y, int z, float r, float g, float b, CallbackInfoReturnable cir) {
41 | cir.setReturnValue(renderWithAO(block, x, y, z, r, g, b));
42 | }
43 | }
44 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/mixin/mixins/client/triangulator/RenderGlobalMixin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.mixin.mixins.client.triangulator;
24 |
25 | import org.spongepowered.asm.mixin.Mixin;
26 | import org.spongepowered.asm.mixin.injection.Constant;
27 | import org.spongepowered.asm.mixin.injection.ModifyConstant;
28 |
29 | import net.minecraft.client.renderer.RenderGlobal;
30 |
31 | @Mixin(RenderGlobal.class)
32 | public abstract class RenderGlobalMixin {
33 | @ModifyConstant(method = "sortAndRender",
34 | constant = @Constant(doubleValue = 1.0D,
35 | ordinal = 0),
36 | require = 0,
37 | expect = 0)
38 | private double fasterSorting(double constant) {
39 | return 0.1D;
40 | }
41 | }
42 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/mixin/mixins/client/triangulator/optifine/TessellatorVanillaMixin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.mixin.mixins.client.triangulator.optifine;
24 |
25 | import com.falsepattern.falsetweaks.modules.triangulator.interfaces.ITriangulatorTessellator;
26 | import lombok.val;
27 | import org.spongepowered.asm.mixin.Mixin;
28 | import org.spongepowered.asm.mixin.injection.At;
29 | import org.spongepowered.asm.mixin.injection.Redirect;
30 |
31 | import net.minecraft.client.renderer.Tessellator;
32 |
33 | @Mixin(Tessellator.class)
34 | public abstract class TessellatorVanillaMixin implements ITriangulatorTessellator {
35 | @Redirect(method = "draw",
36 | at = @At(value = "INVOKE",
37 | target = "Ljava/lang/Math;min(II)I",
38 | ordinal = 0),
39 | require = 1)
40 | private int snapTo3(int a, int b) {
41 | val v = Math.min(a, b);
42 | if (drawingTris()) {
43 | return v - (v % 3);
44 | } else {
45 | return v;
46 | }
47 | }
48 | }
49 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/mixin/mixins/client/triangulator/optifine/TessellatorVanillaOrOldOptifineMixin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.mixin.mixins.client.triangulator.optifine;
24 |
25 | import com.falsepattern.falsetweaks.modules.triangulator.interfaces.ITriangulatorTessellator;
26 | import org.spongepowered.asm.mixin.Mixin;
27 | import org.spongepowered.asm.mixin.injection.At;
28 | import org.spongepowered.asm.mixin.injection.Inject;
29 | import org.spongepowered.asm.mixin.injection.callback.CallbackInfo;
30 |
31 | import net.minecraft.client.renderer.Tessellator;
32 |
33 | @Mixin(Tessellator.class)
34 | public abstract class TessellatorVanillaOrOldOptifineMixin implements ITriangulatorTessellator {
35 | @Inject(method = "addVertex",
36 | at = @At(value = "RETURN"),
37 | require = 1)
38 | private void hackVertex(CallbackInfo ci) {
39 | triangulate();
40 | }
41 | }
42 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/mixin/mixins/client/voxelizer/TextureManagerMixin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.mixin.mixins.client.voxelizer;
24 |
25 | import com.falsepattern.falsetweaks.modules.voxelizer.Data;
26 | import lombok.val;
27 | import org.spongepowered.asm.mixin.Mixin;
28 | import org.spongepowered.asm.mixin.injection.At;
29 | import org.spongepowered.asm.mixin.injection.Inject;
30 | import org.spongepowered.asm.mixin.injection.callback.CallbackInfo;
31 |
32 | import net.minecraft.client.renderer.texture.TextureManager;
33 | import net.minecraft.util.ResourceLocation;
34 |
35 | @Mixin(TextureManager.class)
36 | public abstract class TextureManagerMixin {
37 | @Inject(method = "bindTexture",
38 | at = @At("HEAD"),
39 | require = 1)
40 | private void detectEnchantmentGlint(ResourceLocation p_110577_1_, CallbackInfo ci) {
41 | boolean bound = false;
42 | if (p_110577_1_ != null) {
43 | val resPath = p_110577_1_.getResourcePath();
44 | bound = "textures/misc/enchanted_item_glint.png".equals(resPath);
45 | }
46 | Data.enchantmentGlintTextureBound = bound;
47 | }
48 | }
49 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/mixin/mixins/common/occlusion/PlayerManagerMixin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.mixin.mixins.common.occlusion;
24 |
25 | import com.falsepattern.falsetweaks.config.OcclusionConfig;
26 | import org.spongepowered.asm.mixin.Dynamic;
27 | import org.spongepowered.asm.mixin.Mixin;
28 | import org.spongepowered.asm.mixin.injection.Constant;
29 | import org.spongepowered.asm.mixin.injection.ModifyConstant;
30 |
31 | import net.minecraft.server.management.PlayerManager;
32 |
33 | @Mixin(PlayerManager.class)
34 | public abstract class PlayerManagerMixin {
35 | @Dynamic
36 | @ModifyConstant(method = "func_152622_a",
37 | constant = {@Constant(intValue = 20,
38 | ordinal = 0),
39 | @Constant(intValue = 32,
40 | ordinal = 0)},
41 | require = 0,
42 | expect = 0)
43 | private int expandViewDistance(int constant) {
44 | return OcclusionConfig.RENDER_DISTANCE;
45 | }
46 | }
47 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/mixin/plugin/init/MixinPlugin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.mixin.plugin.init;
24 |
25 | import com.falsepattern.falsetweaks.Tags;
26 | import com.falsepattern.lib.mixin.IMixin;
27 | import com.falsepattern.lib.mixin.IMixinPlugin;
28 | import com.falsepattern.lib.mixin.ITargetedMod;
29 | import lombok.Getter;
30 | import org.apache.logging.log4j.Logger;
31 |
32 | public class MixinPlugin implements IMixinPlugin {
33 | @Getter
34 | private final Logger logger = IMixinPlugin.createLogger(Tags.MOD_NAME + " Init");
35 |
36 | @Override
37 | public ITargetedMod[] getTargetedModEnumValues() {
38 | return new ITargetedMod[0];
39 | }
40 |
41 | @Override
42 | public IMixin[] getMixinEnumValues() {
43 | return Mixin.values();
44 | }
45 | }
46 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/mixin/plugin/standard/Extras.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.mixin.plugin.standard;
24 |
25 | import java.util.function.Predicate;
26 |
27 | import static com.falsepattern.lib.mixin.ITargetedMod.PredicateHelpers.contains;
28 |
29 | class Extras {
30 | static final Predicate OPTIFINE_SHADERSMOD_VERSIONS = contains("d7").or(contains("d8")).or(contains("e3")).or(contains("e7"));
31 | static final Predicate OPTIFINE_DYNAMIC_LIGHTS_VERSIONS = contains("d6");
32 | }
33 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/mixin/plugin/standard/MixinPlugin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.mixin.plugin.standard;
24 |
25 | import com.falsepattern.falsetweaks.Tags;
26 | import com.falsepattern.lib.mixin.IMixin;
27 | import com.falsepattern.lib.mixin.IMixinPlugin;
28 | import com.falsepattern.lib.mixin.ITargetedMod;
29 | import lombok.Getter;
30 | import org.apache.logging.log4j.Logger;
31 |
32 | public class MixinPlugin implements IMixinPlugin {
33 | @Getter
34 | private final Logger logger = IMixinPlugin.createLogger(Tags.MOD_NAME);
35 |
36 | @Override
37 | public ITargetedMod[] getTargetedModEnumValues() {
38 | return TargetedMod.values();
39 | }
40 |
41 | @Override
42 | public IMixin[] getMixinEnumValues() {
43 | return Mixin.values();
44 | }
45 |
46 | @Override
47 | public boolean useNewFindJar() {
48 | return true;
49 | }
50 | }
51 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/modules/animfix/interfaces/IStitcherSlotMixin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.modules.animfix.interfaces;
24 |
25 | import net.minecraft.client.renderer.texture.Stitcher;
26 |
27 | public interface IStitcherSlotMixin {
28 | void insertHolder(Stitcher.Holder holder);
29 | }
30 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/modules/animfix/interfaces/ITextureMapMixin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.modules.animfix.interfaces;
24 |
25 | import com.falsepattern.falsetweaks.api.animfix.IAnimationUpdateBatcher;
26 |
27 | public interface ITextureMapMixin {
28 | void initializeBatcher(int offsetX, int offsetY, int width, int height);
29 |
30 | IAnimationUpdateBatcher getBatcher();
31 | }
32 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/modules/animfix/stitching/HolderSlot.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.modules.animfix.stitching;
24 |
25 | import com.falsepattern.falsetweaks.modules.animfix.interfaces.IStitcherSlotMixin;
26 | import lombok.val;
27 |
28 | import net.minecraft.client.renderer.texture.Stitcher;
29 |
30 | import java.util.Collections;
31 | import java.util.List;
32 |
33 | public class HolderSlot extends SpriteSlot {
34 | private final Stitcher.Holder holder;
35 |
36 | public HolderSlot(Stitcher.Holder holder) {
37 | this.holder = holder;
38 | width = holder.getWidth();
39 | height = holder.getHeight();
40 | }
41 |
42 | @Override
43 | public List getSlots(Rect2D parent) {
44 | val slot = new Stitcher.Slot(x + parent.x, y + parent.y, width, height);
45 | ((IStitcherSlotMixin) slot).insertHolder(holder);
46 | return Collections.singletonList(slot);
47 | }
48 | }
49 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/modules/animfix/stitching/Rect2D.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.modules.animfix.stitching;
24 |
25 | import lombok.AllArgsConstructor;
26 | import lombok.Data;
27 | import lombok.NoArgsConstructor;
28 |
29 | @Data
30 | @AllArgsConstructor
31 | @NoArgsConstructor
32 | public class Rect2D {
33 | public int x;
34 | public int y;
35 | public int width;
36 | public int height;
37 | }
38 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/modules/animfix/stitching/SpriteSlot.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.modules.animfix.stitching;
24 |
25 | import net.minecraft.client.renderer.texture.Stitcher;
26 |
27 | import java.util.List;
28 |
29 | public abstract class SpriteSlot extends Rect2D {
30 | public abstract List getSlots(Rect2D parent);
31 | }
32 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/modules/animfix/stitching/StitcherState.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.modules.animfix.stitching;
24 |
25 | public enum StitcherState {
26 | SETUP,
27 | STITCHED,
28 | }
29 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/modules/animfix/stitching/TooBigException.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.modules.animfix.stitching;
24 |
25 | public class TooBigException extends Exception {
26 | }
27 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/modules/animfix/stitching/packing2d/Algorithm.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.modules.animfix.stitching.packing2d;
24 |
25 | public enum Algorithm {
26 | FIRST_FIT_DECREASING_HEIGHT,
27 | BEST_FIT_DECREASING_HEIGHT
28 | }
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/modules/bsp/IBSPTessellator.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 | package com.falsepattern.falsetweaks.modules.bsp;
23 |
24 | import net.minecraft.client.shader.TesselatorVertexState;
25 |
26 | public interface IBSPTessellator {
27 | TesselatorVertexState ft$getVertexStateBSP(float viewX, float viewY, float viewZ);
28 |
29 | void ft$setVertexStateBSP(TesselatorVertexState tvs);
30 | }
31 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/modules/debug/Debug.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 | package com.falsepattern.falsetweaks.modules.debug;
23 |
24 | import javax.swing.*;
25 |
26 | public class Debug {
27 | public static final boolean ENABLED = Boolean.parseBoolean(System.getProperty("falsetweaks.debug", "false"));
28 |
29 | public static boolean occlusionChecks = true;
30 | public static boolean occlusionMask = true;
31 | public static boolean frustumChecks = true;
32 | public static boolean shadowPass = true;
33 | public static boolean neodymiumGC = true;
34 | public static boolean chunkRebaking = true;
35 | public static boolean shadowOcclusionChecks = true;
36 | public static boolean shadowOcclusionMask = true;
37 | public static boolean translucencySorting = true;
38 | public static boolean tesrRendering = true;
39 | public static boolean fineLogJava = false;
40 | public static boolean fineLogJavaTrace = false;
41 | public static boolean fineLogMegaTrace = false;
42 |
43 | public static void init() {
44 | SwingUtilities.invokeLater(Toggler::new);
45 | }
46 | }
47 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/modules/debug/DebugLogging.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.modules.debug;
24 |
25 | import com.falsepattern.falsetweaks.Share;
26 | import com.falsepattern.falsetweaks.modules.threadedupdates.ThreadedChunkUpdateHelper;
27 | import lombok.val;
28 | import mega.trace.service.MEGATraceService;
29 |
30 | import java.util.function.Supplier;
31 |
32 | public class DebugLogging {
33 | public static void debugLog(Supplier msg) {
34 | if (!(Debug.ENABLED && (Debug.fineLogJava || Debug.fineLogJavaTrace || Debug.fineLogMegaTrace))) {
35 | return;
36 | }
37 | val msgVal = msg.get();
38 |
39 | if (Debug.fineLogJava || Debug.fineLogJavaTrace) {
40 | if (Debug.fineLogJavaTrace && ThreadedChunkUpdateHelper.isMainThread()) {
41 | Share.log.info(msgVal, new Throwable());
42 | } else {
43 | Share.log.info(msgVal);
44 | }
45 | }
46 |
47 | if (Debug.fineLogMegaTrace) {
48 | MEGATraceService.INSTANCE.message(msgVal);
49 | }
50 | }
51 | }
52 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/modules/dynlights/DynamicLightsWorldClient.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.modules.dynlights;
24 |
25 | public interface DynamicLightsWorldClient {
26 | void ft$renderItemInFirstPerson(boolean value);
27 | boolean ft$renderItemInFirstPerson();
28 | }
29 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/modules/mipmapfix/Mipmaps.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.modules.mipmapfix;
24 |
25 | public class Mipmaps {
26 |
27 | private static final float[] VALS = new float[256];
28 |
29 | public static float get(int i) {
30 | return VALS[i & 0xFF];
31 | }
32 |
33 | public static int getColorComponent(int one, int two, int three, int four, int bits) {
34 | float f = Mipmaps.get(one >> bits);
35 | float g = Mipmaps.get(two >> bits);
36 | float h = Mipmaps.get(three >> bits);
37 | float i = Mipmaps.get(four >> bits);
38 | float j = (float) Math.pow((f + g + h + i) * 0.25, 0.45454545454545453);
39 | return (int) (j * 255.0);
40 | }
41 |
42 | static {
43 | for (int i = 0; i < VALS.length; ++i) {
44 | VALS[i] = (float) Math.pow((float) i / 255.0F, 2.2);
45 | }
46 | }
47 | }
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/modules/occlusion/BasicDistanceSorter.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 | package com.falsepattern.falsetweaks.modules.occlusion;
23 |
24 | import net.minecraft.client.renderer.WorldRenderer;
25 | import net.minecraft.entity.EntityLivingBase;
26 |
27 | import java.util.Comparator;
28 |
29 | public class BasicDistanceSorter implements Comparator {
30 | private final EntityLivingBase renderViewEntity;
31 |
32 | public BasicDistanceSorter(EntityLivingBase renderViewEntity) {
33 | this.renderViewEntity = renderViewEntity;
34 | }
35 |
36 | @Override
37 | public int compare(WorldRenderer wr1, WorldRenderer wr2) {
38 | return (int) ((wr1.distanceToEntitySquared(renderViewEntity) - wr2.distanceToEntitySquared(renderViewEntity)) * 1024D);
39 | }
40 | }
41 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/modules/occlusion/IRenderGlobalListener.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 | package com.falsepattern.falsetweaks.modules.occlusion;
23 |
24 | import net.minecraft.client.renderer.WorldRenderer;
25 |
26 | public interface IRenderGlobalListener {
27 |
28 | /**
29 | * Called when a world renderer changes while it's already dirty.
30 | */
31 | void onDirtyRendererChanged(WorldRenderer wr);
32 |
33 | }
34 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/modules/occlusion/IRendererUpdateOrderProvider.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 | package com.falsepattern.falsetweaks.modules.occlusion;
23 |
24 | import net.minecraft.client.renderer.WorldRenderer;
25 |
26 | import java.util.List;
27 | import java.util.concurrent.Future;
28 |
29 | /**
30 | * Provides a traversal order of the elements of RenderGlobal#worldRenderersToUpdate. Ideally, the order should be from
31 | * the closest renderer to the farthest.
32 | */
33 | public interface IRendererUpdateOrderProvider {
34 |
35 | /**
36 | * Prepare providing a batch of renderers.
37 | */
38 | void prepare(List worldRenderersToUpdateList, int updateLimit);
39 |
40 | boolean hasNext();
41 |
42 | WorldRenderer next();
43 |
44 | /**
45 | * End the batch. Remove the renderers that were provided during the batch from worldRenderersToUpdate
46 | */
47 | Future> cleanup();
48 |
49 | }
50 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/modules/occlusion/interfaces/IRenderGlobalMixin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.modules.occlusion.interfaces;
24 |
25 | public interface IRenderGlobalMixin {
26 | int ft$doSortAndRender(int pass, double tick);
27 |
28 | /**
29 | * OptiFine Compat
30 | */
31 | default void ft$setSortedRendererCount(int value) {
32 |
33 | }
34 | }
35 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/modules/renderlists/ItemProp.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.modules.renderlists;
24 |
25 | import lombok.Data;
26 | import lombok.NoArgsConstructor;
27 |
28 | @NoArgsConstructor
29 | @Data
30 | public class ItemProp {
31 | private float a;
32 | private float b;
33 | private float c;
34 | private float d;
35 | private int e;
36 | private int f;
37 | private float g;
38 |
39 | public ItemProp(ItemProp old) {
40 | set(old.a, old.b, old.c, old.d, old.e, old.f, old.g);
41 | }
42 |
43 | public void set(float a, float b, float c, float d, int e, int f, float g) {
44 | this.a = a;
45 | this.b = b;
46 | this.c = c;
47 | this.d = d;
48 | this.e = e;
49 | this.f = f;
50 | this.g = g;
51 | }
52 | }
53 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/modules/rendersafety/SafetyUtil.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.modules.rendersafety;
24 |
25 | import org.lwjgl.opengl.GL11;
26 |
27 | import net.minecraft.client.renderer.OpenGlHelper;
28 |
29 | public class SafetyUtil {
30 | public static void pre(boolean enable) {
31 | if (enable) {
32 | GL11.glPushAttrib(GL11.GL_ALL_ATTRIB_BITS);
33 | }
34 | }
35 |
36 | public static void post(boolean enable) {
37 | if (enable) {
38 | OpenGlHelper.setLightmapTextureCoords(OpenGlHelper.lightmapTexUnit, 240, 240);
39 | GL11.glPopAttrib();
40 | }
41 | }
42 | }
43 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/modules/startup/RegexHelper.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.modules.startup;
24 |
25 | public class RegexHelper {
26 | public static boolean zipJarRegex(String toMatch) {
27 | return toMatch.endsWith(".jar") || toMatch.endsWith(".zip");
28 | }
29 |
30 | public static boolean classFileRegex(String toMatch) {
31 | return toMatch.endsWith(".class") && !toMatch.startsWith("$") && !toMatch.endsWith("$.class") && !toMatch.equals("module-info.class");
32 | }
33 |
34 | public static boolean modClassRegex(String toMatch) {
35 | String shortName = toMatch.substring(toMatch.lastIndexOf('.') + 1);
36 | return shortName.startsWith("mod_") && !shortName.contains("$");
37 | }
38 | }
39 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/modules/startup/ThreadSafeASMDataTable.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 | package com.falsepattern.falsetweaks.modules.startup;
23 |
24 | public interface ThreadSafeASMDataTable {
25 | void enableMutex(boolean enable);
26 | }
27 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/modules/threadedupdates/DoubleBuffered.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.modules.threadedupdates;
24 |
25 | import lombok.val;
26 |
27 | import java.util.concurrent.atomic.AtomicBoolean;
28 | import java.util.function.Supplier;
29 |
30 | public class DoubleBuffered {
31 | private T front;
32 | private T back;
33 | public DoubleBuffered(Supplier constructor) {
34 | front = constructor.get();
35 | back = constructor.get();
36 | }
37 |
38 | public T front() {
39 | return front;
40 | }
41 |
42 | public T back() {
43 | return back;
44 | }
45 |
46 | public void flip() {
47 | val tmp = front;
48 | front = back;
49 | back = tmp;
50 | }
51 | }
52 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/modules/threadedupdates/ICapturableTessellator.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.modules.threadedupdates;
24 |
25 | import net.minecraft.client.shader.TesselatorVertexState;
26 |
27 | public interface ICapturableTessellator {
28 |
29 | /**
30 | * Like getVertexState, but doesn't sort the quads.
31 | */
32 | TesselatorVertexState arch$getUnsortedVertexState();
33 |
34 | /**
35 | * Adds the quads inside a TessellatorVertexState to this tessellator.
36 | */
37 | void arch$addTessellatorVertexState(TesselatorVertexState state);
38 |
39 | /**
40 | * Flushes the tessellator's state similarly to draw(), but without drawing anything.
41 | */
42 | void discard();
43 |
44 | }
45 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/modules/threadedupdates/IRendererUpdateResultHolder.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.modules.threadedupdates;
24 |
25 | public interface IRendererUpdateResultHolder {
26 |
27 | ThreadedChunkUpdateHelper.UpdateTask ft$getRendererUpdateTask();
28 |
29 | }
30 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/modules/threadedupdates/IRenderingRegistryExt.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.modules.threadedupdates;
24 |
25 | import net.minecraft.block.Block;
26 | import cpw.mods.fml.client.registry.ISimpleBlockRenderingHandler;
27 |
28 | // Ported from Angelica
29 | public interface IRenderingRegistryExt {
30 | ISimpleBlockRenderingHandler getISBRH(Block block);
31 | }
32 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/modules/threadedupdates/ITessellatorOptiFineCompat.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 | package com.falsepattern.falsetweaks.modules.threadedupdates;
23 |
24 | public interface ITessellatorOptiFineCompat {
25 | void ft$resizeNativeBuffers();
26 | }
27 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/modules/threadedupdates/MainThreadContainer.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 | package com.falsepattern.falsetweaks.modules.threadedupdates;
23 |
24 | import com.falsepattern.falsetweaks.asm.CoreLoadingPlugin;
25 |
26 | /**
27 | * Separated here to prevent cascading class loading.
28 | *
29 | * @see CoreLoadingPlugin
30 | */
31 | public class MainThreadContainer {
32 | static Thread MAIN_THREAD;
33 |
34 | public static void setMainThread() {
35 | MAIN_THREAD = Thread.currentThread();
36 | }
37 | }
38 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/modules/threadedupdates/NeodymiumWorldRendererThreadingBridge.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 | package com.falsepattern.falsetweaks.modules.threadedupdates;
23 |
24 | public interface NeodymiumWorldRendererThreadingBridge {
25 | void ft$ensureNeodymiumChunkMeshesArraylistPresent();
26 | }
27 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/modules/threadedupdates/ThreadSafeSettings.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.modules.threadedupdates;
24 |
25 | import com.falsepattern.falsetweaks.asm.modules.threadedupdates.settings.Threading_GameSettingsRedirector;
26 |
27 | /**
28 | * These methods are injected as redirects using ASM.
29 | *
30 | * @implNote I REALLY hate that people tamper with this mid-renders. -Ven
31 | * @see Threading_GameSettingsRedirector
32 | */
33 | @SuppressWarnings("unused")
34 | public interface ThreadSafeSettings {
35 | void ft$update();
36 |
37 | void ft$fancyGraphics(boolean fancyGraphics);
38 |
39 | boolean ft$fancyGraphics();
40 | }
41 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/modules/threadedupdates/ThreadedClientHooks.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 | package com.falsepattern.falsetweaks.modules.threadedupdates;
23 |
24 | public class ThreadedClientHooks {
25 | public static final ThreadLocal threadRenderPass = ThreadLocal.withInitial(() -> -1);
26 | }
27 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/modules/threadedupdates/interop/StorageDrawersCompat.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.modules.threadedupdates.interop;
24 |
25 | import com.jaquadro.minecraft.storagedrawers.util.RenderHelper;
26 | import lombok.experimental.UtilityClass;
27 |
28 | @UtilityClass
29 | public final class StorageDrawersCompat {
30 | public static final ThreadLocal instances = ThreadLocal.withInitial(RenderHelper::new);
31 | }
32 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/modules/threadedupdates/interop/ThreadSafeISBRH.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.modules.threadedupdates.interop;
24 |
25 | // Angelica interop
26 | public @interface ThreadSafeISBRH {
27 | boolean perThread();
28 | }
29 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/modules/threadedupdates/interop/ThreadSafeISBRHFactory.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.modules.threadedupdates.interop;
24 |
25 | import cpw.mods.fml.client.registry.ISimpleBlockRenderingHandler;
26 |
27 | // Angelica interop
28 | public interface ThreadSafeISBRHFactory extends ISimpleBlockRenderingHandler {
29 | ThreadSafeISBRHFactory newInstance();
30 | }
31 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/modules/threadexec/ThreadedTask.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 | package com.falsepattern.falsetweaks.modules.threadexec;
23 |
24 | import net.minecraft.profiler.Profiler;
25 |
26 | public interface ThreadedTask {
27 | boolean alive();
28 | boolean lazy();
29 | boolean doWork(Profiler profiler);
30 | }
31 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/modules/triangulator/interfaces/IRenderBlocksMixin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.modules.triangulator.interfaces;
24 |
25 | import net.minecraft.block.Block;
26 |
27 | public interface IRenderBlocksMixin {
28 | void reusePreviousStates(boolean state);
29 |
30 | void enableMultiRenderReuse(boolean state);
31 |
32 | boolean renderWithAO(Block block, int x, int y, int z, float r, float g, float b);
33 | }
34 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/modules/triangulator/interfaces/ITriangulatorTessellator.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.modules.triangulator.interfaces;
24 |
25 | public interface ITriangulatorTessellator {
26 | void alternativeTriangulation(boolean state);
27 |
28 | boolean alternativeTriangulation();
29 |
30 | boolean drawingTris();
31 |
32 | boolean hackedQuadRendering();
33 |
34 | boolean quadTriangulationActive();
35 |
36 | boolean shaderOn();
37 |
38 | void shaderOn(boolean state);
39 |
40 | void triangulate();
41 | }
42 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/modules/triangulator/renderblocks/RenderState.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.modules.triangulator.renderblocks;
24 |
25 | import net.minecraft.block.Block;
26 |
27 | public class RenderState {
28 | public Block block;
29 | public int x;
30 | public int y;
31 | public int z;
32 | public float r;
33 | public float g;
34 | public float b;
35 | public boolean useCustomColor;
36 | public int light;
37 |
38 | public void set(Block block, int x, int y, int z, float r, float g, float b, boolean useColor, int light) {
39 | this.block = block;
40 | this.x = x;
41 | this.y = y;
42 | this.z = z;
43 | this.r = r;
44 | this.g = g;
45 | this.b = b;
46 | this.useCustomColor = useColor;
47 | this.light = light;
48 | }
49 | }
50 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/modules/triangulator/sorting/BSPTessellatorVertexState.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.modules.triangulator.sorting;
24 |
25 | import net.minecraft.client.shader.TesselatorVertexState;
26 |
27 | public class BSPTessellatorVertexState extends TesselatorVertexState {
28 | public final ChunkBSPTree bspTree;
29 |
30 | public BSPTessellatorVertexState(int[] rawBuffer, int rawBufferIndex, int vertexCount, boolean hasTexture, boolean hasBrightness, boolean hasNormals, boolean hasColor, ChunkBSPTree bspTree) {
31 | super(rawBuffer, rawBufferIndex, vertexCount, hasTexture, hasBrightness, hasNormals, hasColor);
32 | this.bspTree = bspTree;
33 | }
34 | }
35 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/modules/triangulator/sorting/area/NormalAreaComputer.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.modules.triangulator.sorting.area;
24 |
25 | import org.joml.Vector3f;
26 |
27 | public interface NormalAreaComputer {
28 | float getArea(int[] vertexData, int i, int vertexSize, Vector3f buf);
29 |
30 | void getNormal(int[] vertexData, int i, int vertexSize, Vector3f output);
31 | }
32 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/modules/triangulator/sorting/midpoint/MidpointComputer.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.modules.triangulator.sorting.midpoint;
24 |
25 | import org.joml.Vector3f;
26 |
27 | public interface MidpointComputer {
28 | void getMidpoint(int[] vertexData, int i, int vertexSize, Vector3f output);
29 | }
30 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/modules/voxelizer/interfaces/ITextureAtlasSpriteMixin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.modules.voxelizer.interfaces;
24 |
25 | import com.falsepattern.falsetweaks.modules.voxelizer.Layer;
26 | import com.falsepattern.falsetweaks.modules.voxelizer.VoxelMesh;
27 |
28 | public interface ITextureAtlasSpriteMixin {
29 | VoxelMesh getVoxelMesh();
30 |
31 | void setVoxelMesh(VoxelMesh mesh);
32 |
33 | void layers(Layer... layers);
34 |
35 | Layer[] layers();
36 |
37 | int frameCounter();
38 |
39 | int getRealWidth();
40 |
41 | int getRealHeight();
42 |
43 | boolean useAnisotropicFiltering();
44 |
45 | int getFrameAlphaData(int id, int x, int y);
46 | }
47 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/modules/voxelizer/loading/LayerMetadataSection.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.modules.voxelizer.loading;
24 |
25 | import net.minecraft.client.resources.data.IMetadataSection;
26 |
27 | import java.util.Arrays;
28 |
29 | public class LayerMetadataSection implements IMetadataSection {
30 | private final float[] thicknesses;
31 |
32 | public LayerMetadataSection(float[] thicknesses) {
33 | this.thicknesses = Arrays.copyOf(thicknesses, thicknesses.length);
34 | }
35 |
36 | public float[] thicknesses() {
37 | return Arrays.copyOf(thicknesses, thicknesses.length);
38 | }
39 | }
40 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/modules/voxelizer/strategy/NullMergingStrategy.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.modules.voxelizer.strategy;
24 |
25 | import com.falsepattern.falsetweaks.modules.voxelizer.Face;
26 | import lombok.AccessLevel;
27 | import lombok.NoArgsConstructor;
28 |
29 | @NoArgsConstructor(access = AccessLevel.PRIVATE)
30 | public class NullMergingStrategy implements MergingStrategy {
31 | public static final NullMergingStrategy NULL = new NullMergingStrategy();
32 |
33 | @Override
34 | public void merge(Face[][] faces) {
35 |
36 | }
37 |
38 | @Override
39 | public void mergeSide(Face[] faces) {
40 |
41 | }
42 | }
43 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/modules/voxelizer/strategy/StrategyPreset.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.modules.voxelizer.strategy;
24 |
25 | import com.falsepattern.lib.StableAPI;
26 | import lombok.RequiredArgsConstructor;
27 |
28 | @RequiredArgsConstructor
29 | @StableAPI(since = "__INTERNAL__")
30 | public enum StrategyPreset {
31 | @StableAPI.Expose Unoptimized_0(NullMergingStrategy.NULL),
32 | @StableAPI.Expose Fast_1(RowColumnMergingStrategy.NoFlip),
33 | @StableAPI.Expose Best_2(ExpandingRectMergingStrategy.NoFlipNoInvRD);
34 | @StableAPI.Expose
35 | public final MergingStrategy strategy;
36 | }
37 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/proxy/CommonProxy.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.proxy;
24 |
25 | import cpw.mods.fml.common.event.FMLConstructionEvent;
26 | import cpw.mods.fml.common.event.FMLInitializationEvent;
27 | import cpw.mods.fml.common.event.FMLLoadCompleteEvent;
28 | import cpw.mods.fml.common.event.FMLPostInitializationEvent;
29 | import cpw.mods.fml.common.event.FMLPreInitializationEvent;
30 |
31 | public class CommonProxy {
32 | public void construct(FMLConstructionEvent e) {
33 |
34 | }
35 |
36 | public void preInit(FMLPreInitializationEvent e) {
37 |
38 | }
39 |
40 | public void init(FMLInitializationEvent e) {
41 |
42 | }
43 |
44 | public void postInit(FMLPostInitializationEvent e) {
45 |
46 | }
47 |
48 | public void loadComplete(FMLLoadCompleteEvent e) {
49 |
50 | }
51 | }
52 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/proxy/ServerProxy.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package com.falsepattern.falsetweaks.proxy;
24 |
25 | public class ServerProxy extends CommonProxy {
26 | }
27 |
--------------------------------------------------------------------------------
/src/main/java/com/falsepattern/falsetweaks/util/ConfigFixUtil.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 | package com.falsepattern.falsetweaks.util;
23 |
24 | import com.falsepattern.lib.util.FileUtil;
25 | import lombok.val;
26 |
27 | import java.io.IOException;
28 | import java.nio.file.Files;
29 | import java.util.function.Consumer;
30 | import java.util.function.Function;
31 | import java.util.stream.Collectors;
32 |
33 | public class ConfigFixUtil {
34 | public static void fixConfig(String configFile, Function lineTransformer, Consumer exceptionHandler) {
35 | val targetPath = FileUtil.getMinecraftHomePath().resolve("config").resolve(configFile);
36 | if (!Files.exists(targetPath)) {
37 | return;
38 | }
39 | try {
40 | val fileText = Files.readAllLines(targetPath);
41 | val result = fileText.stream().map(lineTransformer).collect(Collectors.toList());
42 | Files.write(targetPath, result);
43 | } catch (IOException e) {
44 | exceptionHandler.accept(e);
45 | }
46 | }
47 | }
48 |
--------------------------------------------------------------------------------
/src/main/java/stubpackage/ChunkCacheOF.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 | package stubpackage;
23 |
24 | import net.minecraft.block.Block;
25 | import net.minecraft.world.ChunkCache;
26 | import net.minecraft.world.World;
27 |
28 | import java.util.Arrays;
29 |
30 | public class ChunkCacheOF extends ChunkCache {
31 | public ChunkCacheOF(World p_i1964_1_, int p_i1964_2_, int p_i1964_3_, int p_i1964_4_, int p_i1964_5_, int p_i1964_6_, int p_i1964_7_, int p_i1964_8_) {
32 | super(p_i1964_1_, p_i1964_2_, p_i1964_3_, p_i1964_4_, p_i1964_5_, p_i1964_6_, p_i1964_7_, p_i1964_8_);
33 | }
34 |
35 | public void renderStart() {
36 | }
37 |
38 | public void renderFinish() {
39 | }
40 | }
41 |
--------------------------------------------------------------------------------
/src/main/java/stubpackage/Config.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package stubpackage;
24 |
25 | /**
26 | * OptiFine compat.
27 | */
28 | public class Config {
29 | public static boolean isShaders() {
30 | return false;
31 | }
32 |
33 | public static boolean isFogOff() {
34 | return false;
35 | }
36 |
37 | public static boolean isDynamicLights() {
38 | return false;
39 | }
40 |
41 | public static boolean isDynamicLightsFast() {
42 | return false;
43 | }
44 |
45 | public static boolean isDynamicHandLight() {
46 | return false;
47 | }
48 |
49 | public static boolean equals(Object o1, Object o2) {
50 | return false;
51 | }
52 | public static void warn(String s) {
53 |
54 | }
55 | }
56 |
--------------------------------------------------------------------------------
/src/main/java/stubpackage/WrDisplayListAllocator.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package stubpackage;
24 |
25 | /**
26 | * OptiFine compat.
27 | */
28 | public class WrDisplayListAllocator {
29 | public void resetAllocatedLists() {
30 | }
31 |
32 | public void deleteDisplayLists() {
33 | }
34 | }
35 |
--------------------------------------------------------------------------------
/src/main/java/stubpackage/net/minecraft/client/renderer/EntityRenderer.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package stubpackage.net.minecraft.client.renderer;
24 |
25 | import net.minecraft.client.Minecraft;
26 | import net.minecraft.client.resources.IResourceManager;
27 |
28 | public class EntityRenderer extends net.minecraft.client.renderer.EntityRenderer {
29 | /**
30 | * OptiFine-added field
31 | */
32 | public boolean fogStandard;
33 |
34 | public EntityRenderer(Minecraft p_i45076_1_, IResourceManager p_i45076_2_) {
35 | super(p_i45076_1_, p_i45076_2_);
36 | }
37 | }
38 |
--------------------------------------------------------------------------------
/src/main/java/stubpackage/net/minecraft/client/renderer/WorldRenderer.java:
--------------------------------------------------------------------------------
1 | /*
2 | * This file is part of FalseTweaks.
3 | *
4 | * Copyright (C) 2022-2025 FalsePattern
5 | * All Rights Reserved
6 | *
7 | * The above copyright notice and this permission notice shall be included
8 | * in all copies or substantial portions of the Software.
9 | *
10 | * FalseTweaks is free software: you can redistribute it and/or modify
11 | * it under the terms of the GNU Lesser General Public License as published by
12 | * the Free Software Foundation, only version 3 of the License.
13 | *
14 | * FalseTweaks is distributed in the hope that it will be useful,
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 | * GNU Lesser General Public License for more details.
18 | *
19 | * You should have received a copy of the GNU Lesser General Public License
20 | * along with FalseTweaks. If not, see .
21 | */
22 |
23 | package stubpackage.net.minecraft.client.renderer;
24 |
25 | import net.minecraft.world.World;
26 |
27 | import java.util.List;
28 |
29 | public class WorldRenderer extends net.minecraft.client.renderer.WorldRenderer {
30 | /**
31 | * OptiFine-added field
32 | */
33 | public boolean needsBoxUpdate;
34 |
35 | public WorldRenderer(World p_i1240_1_, List p_i1240_2_, int p_i1240_3_, int p_i1240_4_, int p_i1240_5_, int p_i1240_6_) {
36 | super(p_i1240_1_, p_i1240_2_, p_i1240_3_, p_i1240_4_, p_i1240_5_, p_i1240_6_);
37 | }
38 | }
39 |
--------------------------------------------------------------------------------
/src/main/resources/META-INF/deps.json:
--------------------------------------------------------------------------------
1 | {
2 | "identifier": "falsepatternlib_dependencies",
3 | "repositories": [
4 | "https://repo1.maven.org/maven2/"
5 | ],
6 | "dependencies": {
7 | "always": {
8 | "common": [],
9 | "client": [],
10 | "server": []
11 | },
12 | "obf": {
13 | "common": [
14 | "org.joml:joml:1.10.8",
15 | "it.unimi.dsi:fastutil:8.5.15",
16 | "mega:megatraceservice:1.2.0"
17 | ],
18 | "client": [],
19 | "server": []
20 | },
21 | "dev": {
22 | "common": [],
23 | "client": [],
24 | "server": []
25 | }
26 | }
27 | }
28 |
--------------------------------------------------------------------------------
/src/main/resources/assets/falsetweaks/reference.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/FalsePattern/FalseTweaks/47343096a224c1b28a7eb0ba882b2cb44774c4d0/src/main/resources/assets/falsetweaks/reference.png
--------------------------------------------------------------------------------
/src/main/resources/assets/falsetweaks/white.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/FalsePattern/FalseTweaks/47343096a224c1b28a7eb0ba882b2cb44774c4d0/src/main/resources/assets/falsetweaks/white.png
--------------------------------------------------------------------------------
/src/main/resources/assets/minecraft/textures/blocks/double_plant_grass_bottom.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/FalsePattern/FalseTweaks/47343096a224c1b28a7eb0ba882b2cb44774c4d0/src/main/resources/assets/minecraft/textures/blocks/double_plant_grass_bottom.png
--------------------------------------------------------------------------------
/src/main/resources/assets/minecraft/textures/blocks/double_plant_grass_top.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/FalsePattern/FalseTweaks/47343096a224c1b28a7eb0ba882b2cb44774c4d0/src/main/resources/assets/minecraft/textures/blocks/double_plant_grass_top.png
--------------------------------------------------------------------------------
/src/main/resources/assets/minecraft/textures/blocks/tallgrass.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/FalsePattern/FalseTweaks/47343096a224c1b28a7eb0ba882b2cb44774c4d0/src/main/resources/assets/minecraft/textures/blocks/tallgrass.png
--------------------------------------------------------------------------------
/src/main/resources/mcmod.info:
--------------------------------------------------------------------------------
1 | [
2 | {
3 | "modid": "${modId}",
4 | "name": "${modName}",
5 | "description": "FalsePattern's flagship tweaking, patching, and optimization mod.",
6 | "version": "${modVersion}",
7 | "mcversion": "${minecraftVersion}",
8 | "url": "https://github.com/FalsePattern/FalseTweaks",
9 | "authorList": [
10 | "FalsePattern"
11 | ],
12 | "parent": "",
13 | "dependencies": [
14 | "falsepatternlib"
15 | ],
16 | "credits": "celeron55, CoFH Team, embeddedt, makamys, papuja, Ven"
17 | }
18 | ]
--------------------------------------------------------------------------------
/src/main/resources/mixins.falsetweaks.init.json:
--------------------------------------------------------------------------------
1 | {
2 | "required": true,
3 | "minVersion": "0.7.11",
4 | "package": "com.falsepattern.falsetweaks.mixin.mixins",
5 | "plugin": "com.falsepattern.falsetweaks.mixin.plugin.init.MixinPlugin",
6 | "refmap": "mixins.falsetweaks.refmap.json",
7 | "target": "@env(PREINIT)",
8 | "compatibilityLevel": "JAVA_8"
9 | }
10 |
11 |
--------------------------------------------------------------------------------
/src/main/resources/mixins.falsetweaks.json:
--------------------------------------------------------------------------------
1 | {
2 | "required": true,
3 | "minVersion": "0.7.11",
4 | "package": "com.falsepattern.falsetweaks.mixin.mixins",
5 | "plugin": "com.falsepattern.falsetweaks.mixin.plugin.standard.MixinPlugin",
6 | "refmap": "mixins.falsetweaks.refmap.json",
7 | "target": "@env(DEFAULT)",
8 | "compatibilityLevel": "JAVA_8"
9 | }
10 |
11 |
--------------------------------------------------------------------------------
/src/main/resources/pack.mcmeta:
--------------------------------------------------------------------------------
1 | {}
--------------------------------------------------------------------------------