mirror of
https://forgejo.xatacraft.ru/Sunshine/mkxp-sunshine.git
synced 2026-08-19 13:29:54 +00:00
mya
This commit is contained in:
parent
bb17e127f7
commit
3e892924bd
5 changed files with 29 additions and 30 deletions
|
|
@ -66,12 +66,7 @@ static VALUE profiler_set(VALUE, VALUE v) {
|
|||
|
||||
void ProfilerInit() {
|
||||
VALUE module = rb_define_module("Profiler");
|
||||
tp = rb_tracepoint_new(
|
||||
Qnil,
|
||||
RUBY_EVENT_CALL | RUBY_EVENT_RETURN,
|
||||
tp_cb,
|
||||
nullptr
|
||||
);
|
||||
tp = rb_tracepoint_new(Qnil, RUBY_EVENT_CALL | RUBY_EVENT_RETURN, tp_cb, nullptr);
|
||||
|
||||
rb_gc_register_address(&tp);
|
||||
rb_define_singleton_method(module, "set", RUBY_METHOD_FUNC(profiler_set), 1);
|
||||
|
|
|
|||
|
|
@ -9,7 +9,7 @@
|
|||
# relative to gameFolder and ignoring both RTPs and
|
||||
# encrypted archives.
|
||||
|
||||
# Enable reset on F12 press and Ruby profiller
|
||||
# Enable reset on F12 press and Ruby profiler
|
||||
debugMode=false
|
||||
|
||||
# Start game in fullscreen mode,
|
||||
|
|
|
|||
|
|
@ -50,12 +50,12 @@ module Settings
|
|||
# Debug
|
||||
:debug => false,
|
||||
:debug_character => false,
|
||||
:debug_text => false,
|
||||
:debug_text_scene_title => true,
|
||||
:debug_text => false,
|
||||
:debug_picture_names => false,
|
||||
:debug_lightmap => false,
|
||||
:SDL_HINT_SHUTDOWN_DBUS_ON_QUIT => false,
|
||||
:profiller => false,
|
||||
:profiler => false,
|
||||
}
|
||||
reset_controls!
|
||||
end
|
||||
|
|
@ -579,9 +579,9 @@ class Window_Settings
|
|||
},
|
||||
{
|
||||
:type => :bool,
|
||||
:name => "Profiller",
|
||||
:name => "Profiler",
|
||||
:parameter => :profiler,
|
||||
:icon => [1, 0],
|
||||
:parameter => :profiller
|
||||
},
|
||||
{ :type => :sep },
|
||||
{
|
||||
|
|
|
|||
|
|
@ -850,6 +850,8 @@ class Window_Settings
|
|||
redraw
|
||||
end
|
||||
end
|
||||
|
||||
# ----------------------------------------------------------------------------------------
|
||||
class ActionParameter < BaseParameter
|
||||
TYPE = :action
|
||||
|
||||
|
|
@ -881,6 +883,7 @@ class Window_Settings
|
|||
end
|
||||
end
|
||||
|
||||
# ----------------------------------------------------------------------------------------
|
||||
class CustomParameter < BaseParameter
|
||||
TYPE = :custom
|
||||
def initialize(settings_content, screen_id, position, name, icon, parameter, init_value, callbacks)
|
||||
|
|
|
|||
|
|
@ -97,9 +97,10 @@ module Settings
|
|||
end
|
||||
end
|
||||
|
||||
def profiller(value)
|
||||
def profiler(value)
|
||||
Profiler.set(value)
|
||||
end
|
||||
|
||||
def wallpaper_mode(value)
|
||||
if value == 0
|
||||
Sunshine.wallpapermode="normal"
|
||||
|
|
|
|||
Loading…
Reference in a new issue