X-Git-Url: https://harrygodden.com/git/?a=blobdiff_plain;f=skaterift_imgui_dev.c;h=9d69bfcc7d7ca6e8cd196f2c9e4c8ce6140026b6;hb=4b8fc63f926737ca0593a4e471550f9f4995c538;hp=c51acbe082b2d05b6ba3fac8ce92b3ff6632eb04;hpb=ac6288a8951db15eab6c681b8add8f350eb60746;p=carveJwlIkooP6JGAAIwe30JlM.git diff --git a/skaterift_imgui_dev.c b/skaterift_imgui_dev.c index c51acbe..9d69bfc 100644 --- a/skaterift_imgui_dev.c +++ b/skaterift_imgui_dev.c @@ -13,18 +13,18 @@ #define SR_NETWORKED #define VG_DEVWINDOW -#include "common.h" -#include "conf.h" -#include "steam.h" -#include "render.h" -#include "audio.h" -#include "world.h" -#include "font.h" -#include "player.h" -#include "entity.c" -#include "workshop.c" + +#define SKATERIFT_APPID 2103940 + +#define VG_TIMESTEP_FIXED (1.0/60.0) +#define VG_3D +#define VG_GAME +#define VG_MSG_V1_SUPPORT +#define VG_LOG_SOURCE_INFO +#include "vg/vg.h" static int skaterift_loaded = 0; +static char g_an_buffer[ 4096 ]; int main( int argc, char *argv[] ) { @@ -47,9 +47,6 @@ vg_info(" | \\ / | | / | | \\ | / | \n" ); vg_info(" | \\/ | | / | | \\ | / | \n" ); vg_info(" ' ' '--' [] '----- '----- ' ' '---' " "SOFTWARE\n" ); - - steam_init(); - vg_loader_step( NULL, steam_end ); } VG_STATIC void skaterift_load_post( void *data, u32 len ) @@ -65,7 +62,6 @@ VG_STATIC void vg_load(void) VG_STATIC void vg_update(void) { - steam_update(); } VG_STATIC void vg_update_fixed(void) @@ -78,7 +74,7 @@ VG_STATIC void vg_update_post(void) VG_STATIC void vg_framebuffer_resize( int w, int h ) { - render_fb_resize(); + //render_fb_resize(); } VG_STATIC void vg_render(void) @@ -111,20 +107,20 @@ VG_STATIC void vg_gui(void) ui_outline( window, 1, ui_colour( k_ui_bg+7 ) ); ui_rect title, panel; - ui_split_px( window, k_ui_axis_h, 28, 0, title, panel ); + ui_split( window, k_ui_axis_h, 28, 0, title, panel ); ui_fill( title, ui_colour( k_ui_bg+7 ) ); ui_text( title, "Workshop tool", 1, k_ui_align_middle_center, ui_colourcont(k_ui_bg+7) ); ui_rect quit_button; - ui_split_px( title, k_ui_axis_v, title[2]-title[3], 2, title, quit_button ); - - if( workshop_form.operation == k_workshop_form_op_none ){ - if( ui_button_text( quit_button, "X", 1 ) ){ - workshop_quit_form(); - return; - } + ui_split( title, k_ui_axis_v, title[2]-title[3], 2, title, quit_button ); + if( ui_button_text( quit_button, "x", 1 ) ){ + ui_start_modal( g_an_buffer, UI_MODAL_GOOD ); } + ui_rect tbox; + ui_split( panel, k_ui_axis_h, 28, 0, tbox, panel ); + ui_textbox( tbox, g_an_buffer, 4096, 0, NULL ); + ui_dev_colourview(); }