Skip to content

Conversation

@danielchristiancazares
Copy link
Contributor

guard: Add a defensive guard when object_get_eye has a model without a model instance. Then, log once with object details, assert in debug, and fall back to origin/identity to avoid a hard crash.

Some object types are allowed to programmatically have a model without an instance (e.g. weapons, debris, asteroids, jump nodes). object_get_eye now handles non‑ship objects as to prevent a null deref in aberrant edge cases.

@wookieejedi wookieejedi added the fix A fix for bugs, not-a-bugs, and/or regressions. label Jan 3, 2026
Log once and fall back when object_get_eye lacks a model instance.
@wookieejedi wookieejedi merged commit 2af0aef into scp-fs2open:master Jan 16, 2026
20 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

fix A fix for bugs, not-a-bugs, and/or regressions.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants