Fix obj_init_animation (#936)
Some checks failed
Build coop / build-linux (push) Has been cancelled
Build coop / build-steamos (push) Has been cancelled
Build coop / build-windows-opengl (push) Has been cancelled
Build coop / build-windows-directx (push) Has been cancelled
Build coop / build-macos-arm (push) Has been cancelled
Build coop / build-macos-intel (push) Has been cancelled

* Fix obj_init_animation

* Update object_helpers.c
This commit is contained in:
Baconator2558 2025-08-30 14:49:02 -05:00 committed by GitHub
parent cee5957e11
commit da13adf72c
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -810,8 +810,8 @@ void obj_set_gfx_pos_from_pos(struct Object *obj) {
}
void obj_init_animation(struct Object *obj, s32 animIndex) {
if (!o || !obj) { return; }
struct AnimationTable *animations = o->oAnimations;
if (!obj) { return; }
struct AnimationTable *animations = obj->oAnimations;
if (animations && (u32)animIndex < animations->count) {
geo_obj_init_animation(&obj->header.gfx, animations->anims[animIndex]);
}