Repository navigation
Conversation
…they no longer move or turn with their emitter Particles simulated in the emitter's space unless dirFor was WORLD, and flyGravity was applied in that space too. A turned emitter (the grindstone's wheel, a spell in the hand) pulled its particles sideways into a line instead of a falling shower. Like the engine, an emitted particle now lives in the world and gravity points down; dirFor/shpFor still give the frame a particle starts in. Tried live in the editor (G2 Khorinis smithy): the grindstone sparks fall. Co-Authored-By: Claude Opus 5.5 <[email protected]>
…nd instead of smearing into a streak PrepareHeldEffect only set Local simulation for Gothic's own motion; the ring's and the slot's standing glow relied on the builder's old default (Local). The builder now simulates in World, so that glow was left behind in the world when the hand moved. Both modes simulate in the hand's space now. Co-Authored-By: Claude Opus 5.5 <[email protected]>
… on an NPC move with him instead of trailing Since particles live in the world, effects stuck to a moving body were left behind: a mage's hand glow streaked behind his arm, the sleep effect over the head and hit effects on an NPC trailed when he walked, the light spell's glow trailed behind the hero. CreateVobPfx(isFollowingEmitter) builds them in the emitter's space again (also their sub-emitters). The VR hand charge and the ring/slot effects pass it too. A swung torch flame and flying spells stay in the world (they trail like in Gothic). Co-Authored-By: Claude Opus 5.5 <[email protected]>
…tion is taken into the world once, when built With World simulation Unity turns a Local velocity over lifetime with the emitter's current rotation every frame, so a turning emitter (the grindstone) still curved particles that were already flying (dirMode DIR with dirFor OBJECT, and TARGET). The direction is now converted with the emitter's rotation at creation and the velocity module is World; dirFor still says in which frame a particle starts. The root is placed before that, so the rotation is the final one. Limitation (comment): an emitter that turns after it was built keeps its first direction. Effects that follow their emitter keep the Local velocity, turning with it like before. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Contributor
Author
Review (architecture-reviewer + gothic-reviewer)Architecture: fits. Gothic: fix before merge. Fixed:
Follow-up: #576 (remove the call sites that repeat the World default). Check:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Particles now live in the world once they are emitted, like in the engine. Sparks, smoke and spell particles fall and drift instead of moving and turning with their emitter.
flyGravityalways pulls down: in the emitter's frame, a turned emitter pulled its particles sideways. The grindstone's sparks, for example, made a horizontal line instead of a falling shower. The velocity directions (dirFor OBJECT, TARGET) are converted into the world at build time.Effects that must follow their emitter keep simulating in it. A new optional
isFollowingEmitteronMeshService.CreateVobPfxcovers:Wld_PlayEffect, effects while investing a spell;These stay in the world and trail behind their emitter:
Why
Playtest (G2 Khorinis smithy, with the mob animations of #578): the grindstone sparks streaked sideways in a line. The author saw the same with spells. Switching every system to world space live in the editor made them fall correctly.
How to test manually
Save/load
Nothing.
Known gaps / follow-ups
🤖 Generated with Claude Code