sMapPlayer 0 -1 -1 0 <undefined> <undefined> 1 603 7 0 0 -1 2 self 0 0 1 widescreen = oControl.widescreen; widescreen_space = oControl.widescreen_space; global.curropt = 0; category = 0; category_text = ""; currentlog = 0; clognum = 0; dlognum = 0; logobj[0] = 0; sep = 16; active = 0; alarm[0] = 5; rectoffset = 0; surf = surface_create(130, 123); scroll = 0; lines = 0; currentline = 0; text = ""; expanded = 0; expandable = 0; scrolltimer = 0; targety = 112; currenty = 112; load_logs(); if (global.gotolog < 10) category = 0; if (global.gotolog >= 10 && global.gotolog < 20) category = 1; if (global.gotolog >= 20 && global.gotolog < 30) category = 2; if (global.gotolog >= 30 && global.gotolog < 40) category = 3; if (global.gotolog >= 40 && global.gotolog < 50) category = 4; // <------- NEWLOGSCODE if (global.gotolog == 44) category = 2; create_log_category(category); category_text = cat[category]; text = logobj[global.curropt].ltext; event_user(0); 1 603 7 0 0 -1 2 self 0 0 1 surface_free(surf); with (oLog) instance_destroy(); 1 603 7 0 0 -1 2 self 0 0 1 surface_free(surf); 1 603 7 0 0 -1 2 self 0 0 1 active = 1; global.gotolog = -1; 1 603 7 0 0 -1 2 self 0 0 1 widescreen = oControl.widescreen; widescreen_space = oControl.widescreen_space; if (active) { if (oControl.kDown && oControl.kDownPushedSteps == 0) { if (expanded == 0) { global.curropt += 1; if (global.curropt > dlognum - 1) global.curropt = 0; event_user(0); sfx_play(sndMenuMove); } } if (oControl.kUp && oControl.kUpPushedSteps == 0) { if (expanded == 0) { global.curropt -= 1; if (global.curropt < 0) global.curropt = dlognum - 1; event_user(0); sfx_play(sndMenuMove); } } if (oControl.kDown > 0 && oControl.kDownPushedSteps == 0 || scrolltimer == 0 && oControl.kDown && oControl.kDownPushedSteps > 20) { if (expanded && scroll) { currentline += 1; if (currentline > lines) currentline = lines; event_user(1); sfx_play(sndMenuMove); } } if (oControl.kUp > 0 && oControl.kUpPushedSteps == 0 || scrolltimer == 0 && oControl.kUp && oControl.kUpPushedSteps > 20) { if (expanded && scroll) { currentline -= 1; if (currentline < 0) currentline = 0; event_user(1); sfx_play(sndMenuMove); } } if (oControl.kRight > 0 && oControl.kRightPushedSteps == 0 && expanded == 0) { category += 1; if (category > 4) category = 0; // <--------- NEWLOGSCODE create_log_category(category); event_user(0); category_text = cat[category]; sfx_play(sndMenuMove); } if (oControl.kLeft > 0 && oControl.kLeftPushedSteps == 0 && expanded == 0) { category -= 1; if (category < 0) category = 4; // <--------- NEWLOGSCODE create_log_category(category); event_user(0); category_text = cat[category]; sfx_play(sndMenuMove); } if (oControl.kMenu1 && oControl.kMenu1PushedSteps == 0 && expandable) expanded = !expanded; scrolltimer += 1; if (scrolltimer > 8) scrolltimer = 0; if (expanded) { targety = 59; } else targety = 112; if (currenty != targety) currenty += (targety - currenty) / 4; } // if (active) if(os_type == os_android && os_is_paused()) alarm[1] = 1; if (!surface_exists(surf)) { surface_free(surf); surf = surface_create(130, 123); event_user(1); } 1 603 7 0 0 -1 2 self 0 0 1 surface_set_target(surf); draw_set_font(fontMenuSmall); draw_set_color(c_white); draw_set_alpha(1); draw_clear(c_black); draw_text_ext(2, -8 * currentline - 2, text, 8, 128); surface_reset_target(); 1 603 7 0 0 -1 2 self 0 0 1 currentline = 0; text = logobj[global.curropt].ltext; draw_set_font(fontMenuSmall2); height = string_height_ext(text, 8, 128); if (height > 67) { expandable = 1; } else expandable = 0; if (height > 123) { scroll = 1; lines = (height - 123) / 8; } else scroll = 0; surface_set_target(surf); draw_set_font(fontMenuSmall2); draw_set_color(c_white); draw_set_alpha(1); draw_clear(c_black); draw_text_ext(2, -2, text, 8, 128); surface_reset_target(); 1 603 7 0 0 -1 2 self 0 0 1 if (surface_exists(surf)) draw_surface_part(surf, 0, 0, 130, 179 - currenty, 160 + rectoffset * 4, currenty); if (expanded) { draw_background(bg_Line130, 160, currenty); draw_background(bg_Line130, 160, 179); if (scroll) { if (currentline > 0) draw_sprite_ext(sLogScroll, 1, 285, currenty + 4, 1, -1, 0, -1, 1); if (currentline < lines) draw_sprite(sLogScroll, 1, 285, 176); } } else { draw_background(bg_Line130, 160, currenty); draw_background(bg_Line130, 160, 178); if (expandable) draw_sprite(sLogScroll, 2, 285, 174); } 0 0 0 0.5 0.100000001490116 0 0.100000001490116 0.100000001490116 0.200000002980232 -1 -1