Skip to content

Add Dragon Survival compatibility - #233

Closed
rsdadada wants to merge 2 commits into
xTracr:26.1/devfrom
rsdadada:codex/dragonsurvival-compat
Closed

Add Dragon Survival compatibility#233
rsdadada wants to merge 2 commits into
xTracr:26.1/devfrom
rsdadada:codex/dragonsurvival-compat

Conversation

@rsdadada

@rsdadada rsdadada commented Jul 16, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Let Dragon Survival own the first-person body only while the local player is a dragon and Dragon Survival's renderInFirstPerson option is enabled.
  • Keep the dragon head and neck visible while RealCamera is active in both classic and binding modes.
  • Support RealCamera's disable editor across Dragon Survival's base, glow, and armor passes.
  • Apply UV/depth disabling to Dragon Survival's owned world geometry in binding mode only.

Root cause

RealCamera and Dragon Survival could both submit a first-person body, producing two incomplete models and a view-dependent floating model. Handing body ownership to Dragon Survival removes that duplicate, but also means RealCamera's normal captured-model filtering no longer sees Dragon Survival's GeckoLib geometry.

The disable editor and the world render may receive the same dragon geometry under different texture owners. The simplified world filter also submitted a quad after the first depth-eligible, non-matching vertex, so a disabled UV on any later vertex was missed. Together these caused layer-specific disable records to be discarded and made a face sometimes remain visible in the world.

Implementation

  • Detect Dragon Survival through optional reflection; no Dragon Survival compile dependency or metadata/API change is added.
  • Gate ownership arbitration with both DragonStateProvider.isDragon and the live ClientDragonRenderer.renderInFirstPerson value. Reflection failures warn once and fail open to RealCamera's original behavior.
  • Use Dragon Survival's own player-aware UI render-state factory and apply disable regions consistently across its texture passes.
  • Add an identity-by-default custom-geometry decorator to RoutingSubmitCollector, including ordered submissions.
  • Decorate only the active binding-mode, main-camera, local-player avatar submission that Dragon Survival owns. Classic-mode world geometry is intentionally left unchanged.
  • Select disable configs for each actual Dragon Survival render texture: layer-specific armor/glow records stay on their layer, while a base target record can cover the related Dragon passes.
  • Buffer each GeckoLib quad, evaluate all four vertices for UV disabling, and submit all four only when the quad is not disabled and at least one vertex passes the existing depth boundary.
  • Use an optional @Pseudo mixin to preserve dragon head/neck rendering while RealCamera or its model view is active.

Validation

  • ./gradlew.bat clean build --no-daemon --console=plain (Common, Fabric, and NeoForge all passed).
  • GitHub Actions passed for the same commit on the fork retry. The upstream PR run stopped before compilation because Terraformers Maven prematurely ended the Mod Menu download; contributors cannot rerun that upstream job.
  • Temporary local regression tests reproduced the late-vertex and armor-layer failures before the fix and passed afterward. Test sources and JUnit configuration were removed; this PR contains production code only.
  • Earlier development-client checks covered classic/binding single-body rendering, human-form restoration, head/neck visibility, and UI/world disabling on Minecraft 26.1.2 with GeckoLib 5.5.2 and a local source build of Dragon Survival from upstream commit 6217368. There is no official published Dragon Survival file for Minecraft 26.1.x.
  • The historical Dragon Survival commit 268e5f0, which targets Minecraft 26.1, was compile-checked for the older instance but was not runtime-validated.

This remains a draft pending one final in-game regression pass of the updated per-layer world filter.

@H31M5

H31M5 commented Jul 16, 2026

Copy link
Copy Markdown
Collaborator

没有任何必要这么做,你为什么要这么做
首先,放弃你的所有更改,这一切没有任何必要
第一个重复渲染身体:在CompatibilityHelper里,添加你的DragonStateProvider.isDragonClientDragonRenderer.renderInFirstPerson的反射链接,按照其他的格式!按照之前的格式!
然后直接向DisableHelper添加
第二个模型捕获失效:既然龙生存是基于GeckoLib的渲染,那么你就应该去对GeckoLib的渲染做修复,而不是针对这个模组去进行修复,这没有必要!
至于第三个,我不太能理解为什么这么做,既然他的纹理材质不同,那么理应用多次来全部禁用

@H31M5

H31M5 commented Jul 16, 2026

Copy link
Copy Markdown
Collaborator

没有任何必要这么做,你为什么要这么做 首先,放弃你的所有更改,这一切没有任何必要 第一个重复渲染身体:在里,添加你的和的反射链接,按照其他的格式!按照之前的格式! 然后直接向添加 第二个模型捕获失效:既然龙生存是基于GeckoLib的渲染,那么你就应该去对GeckoLib的渲染做修复,而不是针对这个模组去进行修复,这没有必要! 至于第三个,我不太能理解为什么这么做,既然他的纹理材质不同,那么理应用多次来全部禁用CompatibilityHelper``DragonStateProvider.isDragon``ClientDragonRenderer.renderInFirstPerson``DisableHelper

额,复制markdown查看吧,我也不知道为什么代码会到最后

@rsdadada rsdadada closed this Jul 16, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants