mario.h (2922B)
1 #ifndef MARIO_H 2 #define MARIO_H 3 4 #include <PR/ultratypes.h> 5 6 #include "macros.h" 7 #include "types.h" 8 9 s32 is_anim_at_end(struct MarioState *m); 10 s32 is_anim_past_end(struct MarioState *m); 11 s16 set_mario_animation(struct MarioState *m, s32 targetAnimID); 12 s16 set_mario_anim_with_accel(struct MarioState *m, s32 targetAnimID, s32 accel); 13 void set_anim_to_frame(struct MarioState *m, s16 animFrame); 14 s32 is_anim_past_frame(struct MarioState *m, s16 animFrame); 15 s16 find_mario_anim_flags_and_translation(struct Object *o, s32 yaw, Vec3s translation); 16 void update_mario_pos_for_anim(struct MarioState *m); 17 s16 return_mario_anim_y_translation(struct MarioState *m); 18 void play_sound_if_no_flag(struct MarioState *m, u32 soundBits, u32 flags); 19 void play_mario_jump_sound(struct MarioState *m); 20 void adjust_sound_for_speed(struct MarioState *m); 21 void play_sound_and_spawn_particles(struct MarioState *m, u32 soundBits, u32 waveParticleType); 22 void play_mario_action_sound(struct MarioState *m, u32 soundBits, u32 waveParticleType); 23 void play_mario_landing_sound(struct MarioState *m, u32 soundBits); 24 void play_mario_landing_sound_once(struct MarioState *m, u32 soundBits); 25 void play_mario_heavy_landing_sound(struct MarioState *m, u32 soundBits); 26 void play_mario_heavy_landing_sound_once(struct MarioState *m, u32 soundBits); 27 void play_mario_sound(struct MarioState *m, s32 primarySoundBits, s32 scondarySoundBits); 28 void mario_set_forward_vel(struct MarioState *m, f32 speed); 29 s32 mario_get_floor_class(struct MarioState *m); 30 u32 mario_get_terrain_sound_addend(struct MarioState *m); 31 struct Surface *resolve_and_return_wall_collisions(Vec3f pos, f32 offset, f32 radius); 32 f32 vec3f_find_ceil(Vec3f pos, f32 height, struct Surface **ceil); 33 s32 mario_facing_downhill(struct MarioState *m, s32 turnYaw); 34 u32 mario_floor_is_slippery(struct MarioState *m); 35 s32 mario_floor_is_slope(struct MarioState *m); 36 s32 mario_floor_is_steep(struct MarioState *m); 37 f32 find_floor_height_relative_polar(struct MarioState *m, s16 angleFromMario, f32 distFromMario); 38 s16 find_floor_slope(struct MarioState *m, s16 yawOffset); 39 void update_mario_sound_and_camera(struct MarioState *m); 40 void set_steep_jump_action(struct MarioState *m); 41 u32 set_mario_action(struct MarioState *, u32 action, u32 actionArg); 42 s32 set_jump_from_landing(struct MarioState *m); 43 s32 set_jumping_action(struct MarioState *m, u32 action, u32 actionArg); 44 s32 drop_and_set_mario_action(struct MarioState *m, u32 action, u32 actionArg); 45 s32 hurt_and_set_mario_action(struct MarioState *m, u32 action, u32 actionArg, s16 hurtCounter); 46 s32 check_common_action_exits(struct MarioState *m); 47 s32 check_common_hold_action_exits(struct MarioState *m); 48 s32 transition_submerged_to_walking(struct MarioState *m); 49 s32 set_water_plunge_action(struct MarioState *m); 50 s32 execute_mario_action(UNUSED struct Object *o); 51 void init_mario(void); 52 void init_mario_from_save_file(void); 53 54 #endif // MARIO_H