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
;
21 typedef struct ent_font ent_font
;
22 typedef struct ent_font_variant ent_font_variant
;
23 typedef struct ent_glyph ent_glyph
;
36 k_ent_font_variant
= 10,
40 static u32
mdl_entity_id_type( u32 entity_id
)
42 return (entity_id
& 0xffff0000) >> 16;
45 static u32
mdl_entity_id_id( u32 entity_id
)
47 return entity_id
& 0x0000ffff;
56 k_ent_function_trigger
,
57 k_ent_function_particle_spawn
61 mdl_transform transform
;
66 k_light_type_point
= 0,
71 mdl_transform transform
;
84 k_gate_type_unlinked
= 0,
85 k_gate_type_teleport
= 1,
86 k_gate_type_nonlocal_unlinked
= 2,
87 k_gate_type_nonlocel
= 3
100 m4x3f to_world
, transport
;
111 u16 routes
[4]; /* routes that pass through this gate */
115 struct ent_route_node
{
117 u8 ref_count
, ref_total
;
120 struct ent_path_index
{
124 struct ent_checkpoint
{
133 mdl_transform transform
;
134 u32 official_track_id
;
138 u16 checkpoints_start
,
144 u16 active_checkpoint
,
148 m4x3f board_transform
;
154 mdl_transform transform
;
156 u32 reserved0
, reserved1
;
159 struct ent_audio_clip
{
168 struct volume_particles
{
172 struct volume_trigger
{
177 k_volume_subtype_trigger
,
178 k_volume_subtype_particle
182 mdl_transform transform
;
183 m4x3f to_world
, to_local
;
189 volume_trigger trigger
;
190 volume_particles particles
;
195 mdl_transform transform
;
199 float volume
, crossfade
;
207 mdl_transform transform
;
211 VG_STATIC ent_marker
*ent_find_marker( mdl_context
*mdl
,
212 mdl_array_ptr
*arr
, const char *alias
)
214 for( u32 i
=0; i
<mdl_arrcount(arr
); i
++ ){
215 ent_marker
*marker
= mdl_arritm( arr
, i
);
217 if( !strcmp( mdl_pstr( mdl
, marker
->pstr_alias
), alias
) ){
225 enum channel_behaviour
{
226 k_channel_behaviour_unlimited
= 0,
227 k_channel_behaviour_discard_if_full
= 1,
228 k_channel_behaviour_crossfade_if_full
= 2
231 enum probability_curve
{
232 k_probability_curve_constant
= 0,
233 k_probability_curve_wildlife_day
= 1,
234 k_probability_curve_wildlife_night
= 2
246 struct ent_font_variant
{
257 #endif /* ENTITY_H */