v3f pos, int layer_depth ){
if( !world ) return;
if( skaterift.activity == k_skaterift_replay ) return;
+ if( world != world_current_instance() ) return;
/* sort lists */
f32 radius = 40.0f;
while( mdl_entity_id_type(next) == k_ent_objective ){
u32 index = mdl_entity_id_id( next );
objective_list[ objective_count ++ ] = index;
-
+
ent_objective *objective = mdl_arritm( &world->ent_objective, index );
next = objective->id_next;
}
shader_scene_terrain_uBlendOffset( mat->info.colour1 );
}
-VG_STATIC void bindpoint_none( world_instance *world,
- struct world_surface *mat ){
-
+VG_STATIC void bindpoint_override( world_instance *world,
+ struct world_surface *mat ){
+ if( mat->info.flags & k_material_flag_collision ){
+ shader_scene_override_uAlphatest(0);
+ }
+ else{
+ glActiveTexture( GL_TEXTURE1 );
+ glBindTexture( GL_TEXTURE_2D, world->textures[ mat->info.tex_diffuse ] );
+ shader_scene_override_uAlphatest(1);
+ }
}
VG_STATIC void render_terrain( world_instance *world, camera *cam )
VG_STATIC void render_world_override( world_instance *world ){
struct world_pass pass = {
.cam = &skaterift.cam,
- .fn_bind_textures = bindpoint_none,
+ .fn_bind_textures = bindpoint_override,
.fn_set_mdl = shader_scene_override_uMdl,
.fn_set_uPvmPrev = shader_scene_override_uPvmPrev,
.shader = k_shader_override