6 typedef struct ent_spawn ent_spawn
;
7 typedef struct ent_light ent_light
;
8 typedef struct ent_gate ent_gate
;
9 typedef struct ent_route_node ent_route_node
;
10 typedef struct ent_path_index ent_path_index
;
11 typedef struct ent_checkpoint ent_checkpoint
;
12 typedef struct ent_route ent_route
;
13 typedef struct ent_water ent_water
;
14 typedef struct ent_audio_clip ent_audio_clip
;
15 typedef struct volume_particles volume_particles
;
16 typedef struct volume_trigger volume_trigger
;
17 typedef struct ent_volume ent_volume
;
18 typedef struct ent_audio ent_audio
;
19 typedef struct ent_index ent_index
;
20 typedef struct ent_marker ent_marker
;
39 k_ent_function_trigger
,
40 k_ent_function_particle_spawn
44 mdl_transform transform
;
49 k_light_type_point
= 0,
54 mdl_transform transform
;
67 k_gate_type_unlinked
= 0,
68 k_gate_type_teleport
= 1,
69 k_gate_type_nonlocal
= 2
76 /* TODO: World index */
84 m4x3f to_world
, transport
;
90 u8 ref_count
, ref_total
;
95 u16 routes
[4]; /* routes that pass through this gate */
98 struct ent_route_node
{
100 u8 ref_count
, ref_total
;
103 struct ent_path_index
{
107 struct ent_checkpoint
{
116 mdl_transform transform
;
117 u32 official_track_id
;
121 u16 checkpoints_start
,
127 u32 active_checkpoint
;
129 m4x3f board_transform
;
135 mdl_transform transform
;
137 u32 reserved0
, reserved1
;
140 struct ent_audio_clip
{
149 struct volume_particles
{
153 struct volume_trigger
{
158 k_volume_subtype_trigger
,
159 k_volume_subtype_particle
163 mdl_transform transform
;
164 m4x3f to_world
, to_local
;
170 volume_trigger trigger
;
171 volume_particles particles
;
176 mdl_transform transform
;
180 float volume
, crossfade
;
188 mdl_transform transform
;
192 enum channel_behaviour
{
193 k_channel_behaviour_unlimited
= 0,
194 k_channel_behaviour_discard_if_full
= 1,
195 k_channel_behaviour_crossfade_if_full
= 2
198 enum probability_curve
{
199 k_probability_curve_constant
= 0,
200 k_probability_curve_wildlife_day
= 1,
201 k_probability_curve_wildlife_night
= 2
204 VG_STATIC ent_marker
*ent_find_marker( mdl_context
*mdl
,
205 mdl_array_ptr
*arr
, const char *alias
)
207 for( u32 i
=0; i
<mdl_arrcount(arr
); i
++ ){
208 ent_marker
*marker
= mdl_arritm( arr
, i
);
210 if( !strcmp( mdl_pstr( mdl
, marker
->pstr_alias
), alias
) ){
218 #endif /* ENTITY_H */