diff options
| author | Simon Robertshaw <simon@hardwired.org.uk> | 2011-05-24 13:55:29 (GMT) |
|---|---|---|
| committer | Simon Robertshaw <simon@hardwired.org.uk> | 2011-05-24 13:55:29 (GMT) |
| commit | 453c69d39aa565ba61aef98f0f7b7bc8f3b94da0 (patch) | |
| tree | 3675b28e5774d1b9f72eccaa4ac554f380b666c7 /src/main.c | |
| parent | eafcdf8ec94b058707f1a6b8a2b9b5076c6275ca (diff) | |
| parent | 956218736b557eb91bb4d841006ddce0d3cdbeed (diff) | |
| download | powder-453c69d39aa565ba61aef98f0f7b7bc8f3b94da0.zip powder-453c69d39aa565ba61aef98f0f7b7bc8f3b94da0.tar.gz | |
Merge branch 'master' of github.com:FacialTurd/The-Powder-Toy
Diffstat (limited to 'src/main.c')
| -rw-r--r-- | src/main.c | 22 |
1 files changed, 16 insertions, 6 deletions
@@ -173,6 +173,7 @@ int sys_pause = 0; int sys_shortcuts = 1; int legacy_enable = 0; //Used to disable new features such as heat, will be set by save. int ngrav_enable = 0; //Newtonian gravity, will be set by save +int decorations_enable = 1; int death = 0, framerender = 0; int amd = 1; int FPSB = 0; @@ -2010,8 +2011,6 @@ int main(int argc, char *argv[]) vy[ny][nx] = -vy[ny][nx]; } } - if ((sdl_mod & (KMOD_RCTRL) )&&( sdl_mod & (KMOD_RALT))) - active_menu = 11; if (sdl_key==SDLK_INSERT)// || sdl_key==SDLK_BACKQUOTE) REPLACE_MODE = !REPLACE_MODE; if (sdl_key==SDLK_BACKQUOTE) @@ -2021,8 +2020,19 @@ int main(int argc, char *argv[]) } if (sdl_key=='b') { - decorations_ui(vid_buf,decorations,&bsx,&bsy);//decoration_mode = !decoration_mode; - sys_pause=1; + if (sdl_mod & KMOD_CTRL) + { + decorations_enable = !decorations_enable; + itc = 51; + if (decorations_enable) strcpy(itc_msg, "Decorations layer: On"); + else strcpy(itc_msg, "Decorations layer: Off"); + } + else + { + decorations_ui(vid_buf,decorations,&bsx,&bsy);//decoration_mode = !decoration_mode; + decorations_enable = 1; + sys_pause=1; + } } if (sdl_key=='g') { @@ -2316,7 +2326,7 @@ int main(int argc, char *argv[]) } } menu_ui_v3(vid_buf, active_menu, &sl, &sr, &dae, b, bq, x, y); //draw the elements in the current menu - draw_decorations(vid_buf,decorations); + if (decorations_enable) draw_decorations(vid_buf,decorations); if (zoom_en && x>=sdl_scale*zoom_wx && y>=sdl_scale*zoom_wy //change mouse position while it is in a zoom window && x<sdl_scale*(zoom_wx+ZFACTOR*ZSIZE) && y<sdl_scale*(zoom_wy+ZFACTOR*ZSIZE)) @@ -3000,7 +3010,7 @@ int main(int argc, char *argv[]) drawtext(vid_buf, 16, YRES-24, "Click-and-drag to specify a rectangle to copy (right click = cancel).", 255, 216, 32, da*5); break; case 270: - drawtext(vid_buf, 16, YRES-24, "Enable or disable compatibility mode (disables heat simulation).", 255, 255, 255, da*5); + drawtext(vid_buf, 16, YRES-24, "Simulation options", 255, 255, 255, da*5); break; case 271: drawtext(vid_buf, 16, YRES-24, "You're a moderator", 255, 255, 255, da*5); |
