X-Git-Url: https://harrygodden.com/git/?a=blobdiff_plain;f=respawn.c;h=d8c470a83679fdfaa35d38c5796863313c3602dc;hb=5f5d02725031cad23f1cab3290b8a9d661c89728;hp=e90f9be3ebf389fb088370ad67905beb2a39e9dd;hpb=77c2df4874873fb2d085b9413ed97f66681ad7ac;p=carveJwlIkooP6JGAAIwe30JlM.git diff --git a/respawn.c b/respawn.c index e90f9be..d8c470a 100644 --- a/respawn.c +++ b/respawn.c @@ -1,6 +1,7 @@ #ifndef RESPAWN_C #define RESPAWN_C +#if 1 #include "respawn.h" #include "skaterift.h" #include "world.h" @@ -87,13 +88,8 @@ static void respawn_map_draw_icon( camera *cam, static void respawn_chooser_pre_update(void){ if( skaterift.activity != k_skaterift_respawning ) return; - gui_helper_action( joystick_display_string(k_srjoystick_steer,2), "move" ); - if( world_static.instances[0].status == k_world_status_loaded ) - gui_helper_action( axis_display_string(k_sraxis_mworld_h), "world" ); - gui_helper_action( button_display_string(k_srbind_maccept), "spawn" ); - gui_helper_action( button_display_string(k_srbind_home), "home" ); - if( button_down( k_srbind_mback ) ){ + gui_helper_clear(); srinput.state = k_input_state_resume; skaterift.activity = k_skaterift_menu; menu.page = 0xffffffff; @@ -107,31 +103,11 @@ static void respawn_chooser_pre_update(void){ if( respawn_chooser.spawn ){ world_static.active_instance = respawn_chooser.world_id; - localplayer.viewable_world = - &world_static.instances[ respawn_chooser.world_id ]; player__spawn( respawn_chooser.spawn ); } return; } - if( button_down( k_srbind_world_left ) ){ - if( respawn_chooser.world_id > 0 ) - respawn_chooser_setworld( respawn_chooser.world_id-1 ); - } - - if( button_down( k_srbind_world_right ) ){ - u32 next = respawn_chooser.world_id+1; - if( next < vg_list_size(world_static.instances) ) - respawn_chooser_setworld( next ); - } - - if( button_down(k_srbind_home) ){ - respawn_chooser.home_select ++; - if( respawn_chooser.home_select >= vg_list_size(respawn_homes) ) - respawn_chooser.home_select = 0; - respawn_chooser_gohome(); - } - world_instance *world = &world_static.instances[ respawn_chooser.world_id ]; v3f *bbx = world->scene_geo.bbx; f32 *pos = respawn_chooser.plane_pos; @@ -197,9 +173,9 @@ static void respawn_chooser_pre_update(void){ for( u32 i=0; ient_challenge); i++ ){ ent_challenge *challenge = mdl_arritm( &world->ent_challenge, i ); - enum gui_icon icon = k_gui_icon_exclaim; + enum gui_icon icon = k_gui_icon_exclaim_2d; if( challenge->status ) - icon = k_gui_icon_tick; + icon = k_gui_icon_tick_2d; respawn_map_draw_icon( cam, icon, challenge->transform.co ); } @@ -228,7 +204,7 @@ static void respawn_chooser_pre_update(void){ v4_copy( route->colour, colour ); v3_muls( colour, 1.6666f, colour ); gui_icon_setcolour( colour ); - respawn_map_draw_icon( cam, k_gui_icon_rift_run, + respawn_map_draw_icon( cam, k_gui_icon_rift_run_2d, route->board_transform[3] ); } } @@ -243,8 +219,21 @@ static void respawn_begin_chooser(void){ respawn_world_to_plane_pos( localplayer.rb.co, respawn_chooser.plane_pos ); respawn_chooser.boom_dist = 400.0f; respawn_chooser.home_select = 0; + + gui_helper_clear(); + + vg_str text; + if( gui_new_helper( input_joy_list[k_srjoystick_steer], &text ) ) + vg_strcat( &text, "move" ); + + if( gui_new_helper( input_button_list[k_srbind_maccept], &text ) ) + vg_strcat( &text, "spawn" ); + + if( gui_new_helper( input_button_list[k_srbind_mback], &text ) ) + vg_strcat( &text, "exit" ); } +#if 0 static void respawn_chooser_shader_uniforms(void){ v4f uPlayerPos, uSpawnPos; v4_zero( uPlayerPos ); @@ -261,5 +250,7 @@ static void respawn_chooser_shader_uniforms(void){ shader_scene_override_uPlayerPos( uPlayerPos ); shader_scene_override_uSpawnPos( uSpawnPos ); } +#endif +#endif #endif /* RESPAWN_C */