From a458573a849df914b989f6535b0479ed2ca461ab Mon Sep 17 00:00:00 2001 From: DepressedTWM Date: Fri, 7 Aug 2026 13:49:59 +0400 Subject: [PATCH] banchmrask bullshit --- binding-mri/sunshine-binding.cpp | 1 - binding-mri/wallpaper-binding.cpp | 1 - binding-mri/window-binding.cpp | 1 - scripts_benchmark/Main.rb | 66 +++++++++++++++++++++++++++++++ scripts_benchmark/_scripts.txt | 1 + src/eventthread.cpp | 2 +- 6 files changed, 68 insertions(+), 4 deletions(-) create mode 100644 scripts_benchmark/Main.rb create mode 100644 scripts_benchmark/_scripts.txt diff --git a/binding-mri/sunshine-binding.cpp b/binding-mri/sunshine-binding.cpp index e868482..7c6567f 100644 --- a/binding-mri/sunshine-binding.cpp +++ b/binding-mri/sunshine-binding.cpp @@ -53,7 +53,6 @@ static VALUE int_times(VALUE self) { } void SunshineBindingInit(){ - printf("[SunshineBindingInit] Initializing Sunshine binding\n"); VALUE module = rb_define_module("Sunshine"); //SDL versions, for debug info in main menu and other shi idkkkkkkkk rb_const_set(module, rb_intern("SDLVersion_major"), INT2NUM(SDL_MAJOR_VERSION)); diff --git a/binding-mri/wallpaper-binding.cpp b/binding-mri/wallpaper-binding.cpp index fd3f67a..0fefec1 100644 --- a/binding-mri/wallpaper-binding.cpp +++ b/binding-mri/wallpaper-binding.cpp @@ -565,7 +565,6 @@ RB_METHOD(wallpaperReset){ } void wallpaperBindingInit(){ - printf("[wallpaperBindingInit] Initialing Wallpaper binding\n"); VALUE module = rb_define_module("Wallpaper"); // Functions diff --git a/binding-mri/window-binding.cpp b/binding-mri/window-binding.cpp index a8cf07e..42192f9 100644 --- a/binding-mri/window-binding.cpp +++ b/binding-mri/window-binding.cpp @@ -67,7 +67,6 @@ DEF_PROP_I(Window, ContentsOpacity) void windowBindingInit(){ - printf("[windowBindingInit] Initialing Window binding\n"); VALUE klass = rb_define_class("Window", rb_cObject); rb_define_alloc_func(klass, classAllocate<&WindowType>); diff --git a/scripts_benchmark/Main.rb b/scripts_benchmark/Main.rb new file mode 100644 index 0000000..bdb498e --- /dev/null +++ b/scripts_benchmark/Main.rb @@ -0,0 +1,66 @@ +# Engine benchmark idk, check speed via linux time utility + +begin + RPG::Mod.exec_hooks("test", binding) + Audio.bgm_play("Audio/BGM/MyBurdenIsLight.ogg", Audio.bgm_volume, 100) + + count = 0 + while count <= 500000 do + puts count + count += 1 + end + while count >= 1 do + puts count + count -= 1 + end + + count = 1.5 + while count <= 99999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999 do + puts count + count = count * count + end + + count = 2 + while count <= 99999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999 do + puts count + count = count * count + end + count / 67.1488 + count = 1 + while count <= 5000 do + Graphics.frame_rate = count + count += 1 + end + + count = 1 + while count <= 60 do + Font.default_size = count + count += 1 + end + + + Graphics.setVsync(0) + Graphics.setVsync(1) + Graphics.setVsync(-1) + Graphics.smooth = true + Graphics.smooth = false + Graphics.frame_reset + Graphics.update + Oneshot.shake + Sunshine.crashprivacy=true + Wallpaper.reset + Input.set_led(255, 150, 30) + Graphics.freeze + Wallpaper.reset + File.exist?("oneshot") + Oneshot.exiting false + Oneshot.exiting true + Audio.bgm_fade(800) + Audio.bgs_fade(800) + Audio.me_fade(800) + Audio.se_play('Audio/SE/title_decision.wav') + +rescue Errno::ENOENT + filename = $!.message.sub("No such file or directory - ", "") + print("Unable to find file #{filename}.") +end diff --git a/scripts_benchmark/_scripts.txt b/scripts_benchmark/_scripts.txt new file mode 100644 index 0000000..c098216 --- /dev/null +++ b/scripts_benchmark/_scripts.txt @@ -0,0 +1 @@ +Main diff --git a/src/eventthread.cpp b/src/eventthread.cpp index d170927..af697b1 100644 --- a/src/eventthread.cpp +++ b/src/eventthread.cpp @@ -444,7 +444,7 @@ void EventThread::process(RGSSThreadData &rtData){ break; SDL_snprintf(buffer, sizeof(buffer), "%s - %d FPS", rtData.config.windowTitle.c_str(), event.user.code); - + Debug() << event.user.code; /* Updating the window title in fullscreen * mode seems to cause flickering */ if (fullscreen){