Skip to content

Releases: SlonickLab/Smart-Replay-Mover

🐧 v2.9.0: Linux Support & Cross-Platform Architecture

10 Apr 16:20
230b043

Choose a tag to compare

This is a landmark release that brings full Linux support to Smart Replay Mover! Huge thanks to @zxsleebu for the massive Pull Request (#19) that laid the foundation for this work.


What's New

  • 🐧 Linux Support — Smart Replay Mover now works natively on Linux (KDE Plasma, X11, and Wayland via XWayland).
  • 🔍 Linux Game Detection — Uses xprop (X11) and gdbus (KWin/Wayland) to identify active windows instead of Win32 APIs.
  • 🎥 Linux OBS Sources — Recognizes Linux-specific capture types like xcomposite_input, pipewire-window-capture-source, and xshm_input.
  • 🔔 Linux Notifications — Uses notify-send for visual popups and paplay (PulseAudio) or pw-play (PipeWire) for notification audio.
  • 🔇 Quiet Sound on Linux — The quiet sound toggle works natively, letting you switch between notification_sound.wav and notification_sound_silent.wav.
  • 🖥️ OS Mode Selector — New dropdown in script properties: Auto-Detect, Windows, or Linux. Auto-Detect determines your OS automatically.
  • 🛡️ Crash Prevention — Every platform-specific code path is wrapped in pcall(). The script never crashes regardless of mismatched settings (e.g. running Linux commands on Windows fails silently).
  • 🔧 FFI Consolidation — All Windows API definitions merged into a single guarded block for maximum stability.

🔧 Technical Changes

  • 🛠️ Cross-Platform Helpers — Added join_path(), quote_shell_arg(), and run_shell_command() for safe, OS-aware execution.
  • 📂 File Operationsget_existing_folder(), delete_file(), and get_file_size() now automatically fallback to standard Lua I/O on Linux.
  • 🎬 FFmpeg on Linux — Runs via shell commands directly (no .bat files). Supports both ffmpeg.exe and ffmpeg with proper shell quoting and error logging.
  • 🎮 Steam Compatibilityis_generic_steam_app_identifier() correctly ignores generic steam_app_12345 folder names on Linux, falling back to window title detection.

🖥️ Adaptive UI

  • 👁️ Smart Settings Menu — Windows-only settings (Scan All Processes, Notification Scale/Position, Update Checker) auto-hide when Linux mode is active.
  • 📁 Dynamic FFmpeg Path — FFmpeg path description adapts contextually (ffmpeg.exe on Windows → /usr/bin/ffmpeg on Linux).
  • 🗂️ Reorganized Tools — OS Mode Selector moved to Tools & Debug group so it doesn't displace update buttons.

💡 For Linux Users:

  1. Install OBS Studio via your package manager.
  2. Add the script in OBS → Tools → Scripts.
  3. The script auto-detects Linux — no configuration needed!
  4. Optional dependencies: notify-send (notifications), paplay or pw-play (sound).
  5. For X11: xprop should be installed (usually included with xorg-xprop).
  6. For KDE Plasma: gdbus is used automatically for window detection on Wayland.

🔍 v2.8.2: Background Game Scanning & Detection Fix

02 Apr 12:01
de95bf6

Choose a tag to compare

This update brings a powerful new feature for detecting games running in the background, making it easier than ever to capture clips even if you frequently alt-tab. Huge thanks to @EndCod3r for suggesting this feature and kicking off the implementation!


What's New

  • 🔍 Background Game Detection (Smart Fallback):

    • Added a new option: "Detect game by scanning all running processes".
    • How it works: If you alt-tab out of your game (say, to message someone on Discord or check your Desktop) and press your Replay Save hotkey, OBS sees that your active window is Discord. With this option enabled, the script will silently scan your background processes, find your running game, and save the clip correctly into its folder!
    • This functions strictly as a fallback — it will never override the game you are actually focused on.
  • 🛡️ 100% Anti-Cheat Safe:

    • Instead of forcefully opening your games to read their data (which aggressive anti-cheats like Vanguard or BattlEye hate), the script uses CreateToolhelp32Snapshot.
    • This is a read-only, split-second "photo" of your system that is completely invisible to anti-cheats and introduces zero performance overhead.

🐛 Bug Fixes

  • 🐛 Alt-Tab Detection Logic Fix:
    • Fixed an architectural flaw from v2.8.0. Previously, if your active window was in the "Ignore List" (like OBS Studio or Discord), the script would immediately give up. It completely bypassed the OBS Game Capture checks. This logic flow has been fixed, so alt-tabbing no longer breaks OBS Game Capture fallback!

💡 How to enable Background Scanning:

  1. Open the script properties in OBS (Tools → Scripts).
  2. Scroll down to the 🗂️ ORGANIZATION section.
  3. Check the box for "🔍 Detect game by scanning all running processes".
  4. You're set! Now you can alt-tab freely and still let the script organize your clips perfectly.

🛡️ v2.8.1: Critical Hotfix — Smart Save Hotkey Stability

30 Mar 10:44
8753326

Choose a tag to compare

This hotfix resolves the critical issue where the "Smart Save Replay" hotkey caused OBS to crash or freeze for some users.

⚠️ If you previously unbound the Smart Save hotkey due to Discussion #16, you can safely re-enable it now.


🐛 What Was Happening

When the "Smart Save Replay (Instant Notification)" hotkey was pressed, OBS would freeze or crash for some users — particularly those with slower HDDs or lower-end systems.

Root Cause: The notification system was making direct Win32 GDI calls (creating windows, drawing text, manipulating pixels) from the hotkey input thread, while the same window was being animated from the graphics thread. Windows strictly requires that a window is only manipulated from the thread that created it. When two threads tried to control the same notification window simultaneously, Windows would deadlock waiting for cross-thread message processing — freezing OBS completely.

On faster systems (NVMe, powerful CPUs), the save completed so quickly that the race condition rarely triggered. On slower systems, the timing gap was large enough to consistently cause the deadlock.


What's Fixed

  • 🧵 Thread-Safe Notification Queue:

    • notify() no longer calls any Win32/GDI functions directly.
    • Instead, it pushes a message into a lightweight Lua queue table — an operation that is safe from any thread.
    • A dedicated timer (process_notification_queue, 50ms interval) running exclusively on the graphics thread is the sole consumer of this queue.
    • Result: All window creation, drawing, and animation now happen on exactly one thread. Cross-thread deadlocks are architecturally impossible.
  • ⚡ Smart Skip Optimization:

    • On fast systems (NVMe/SSD), the replay file is saved almost instantly.
    • In this case, the "Saving..." and "Clip Saved" notifications arrive in the queue back-to-back.
    • The queue processor detects this and skips "Saving...", showing only "Clip Saved" — cleaner and faster.
    • On slower systems (HDD), "Saving..." is still shown as intended, giving the user immediate feedback.
  • 🐛 Double Detection Fix:

    • Fixed a bug where detect_game() was called twice during each replay buffer save — once in the event handler and once inside process_file().
    • Between the two calls, the active window could change (e.g., game minimizing briefly during file write), potentially causing the clip to be saved to the wrong folder.
    • Now the game is detected once and the result is reused consistently.

📋 Technical summary for developers:

  • notify()table.insert(queue) (thread-safe, O(1))
  • process_notification_queue()obs.timer_add(fn, 50) (graphics thread only)
  • Removed deferred_smart_save timer hack (no longer needed)
  • Added process_notification_queue to script_unload() cleanup
  • Changed on_event replay saved handler to use process_file_with_game() instead of process_file()

🚀 v2.8.0: Smart Save, No-Folder Mode & Community DB!

29 Mar 12:10
e532b57

Choose a tag to compare

This major update brings two highly requested community features, massive quality-of-life additions, and officially opens the games database for user contributions!


What's New

  • ⚡ Smart Save Hotkey — Instant "Saving..." Feedback:

    • A new OBS hotkey called "Smart Save Replay (Instant Notification)" is now registered automatically.
    • When pressed, it shows a "Saving..." notification instantly, then the usual "Clip Saved" when the file is ready.
    • Perfect for users with slow HDDs or 4K recordings where the file takes time to write.
    • How to use:
      1. Go to OBS Settings → Hotkeys
      2. Find "Smart Save Replay (Instant Notification)"
      3. Assign your preferred key (e.g., the same key you used for the native "Save Replay")
      4. Optionally unbind the native "Save Replay Buffer" hotkey to avoid double saves
    • Zero risk: If you don't assign the hotkey, everything works exactly as before.
  • 📂 "No Folder" Mode — Keep Files in OBS Output Root:

    • Map a process to /, \, or . (dot) to completely skip subfolder creation.
    • Your recorded files will save perfectly — directly into your main OBS output directory.
    • The Game Name prefix is still beautifully applied to the filename if you have it enabled.
    • Example: chrome > / → clips saved while Chrome is active stay right in your root folder.
    • Special thanks to lemenegg for the suggestion!
  • 🌍 Community-Driven Games Database:

    • The massive built-in database of 1800+ games is now available as a separate games_database.json file in the GitHub repository.
    • Your help is welcome! You can now easily contribute missing games, update existing ones, or fix typos by simply editing the JSON file and opening a Pull Request.
    • This makes it much easier for the community to help grow the database without having to touch the complex Lua code!

🔧 Under-the-Hood Optimizations

  • 🧹 Performance & Stability: I've streamlined the core Windows API integration (FFI definitions) to ensure maximum stability and zero conflicts with other OBS plugins. This removes duplicate memory variables and makes the script run even smoother directly on Windows.

💡 How to use Smart Save:

  1. Open OBS Settings → Hotkeys
  2. Search for "Smart Save Replay"
  3. Assign your key — done!
  4. You'll see "Saving..." instantly when you press the key, then "Clip Saved" when the file is organized.

💡 How to use "No Folder" mode:

  1. In script settings → CUSTOM NAMES section
  2. Enter process name → set folder to /, \, or .
  3. Click Add — files from that process will stay in the output root directory

📋 Idea credits:
"No Folder" mode requested by lemenegg (Resource Review)
Instant notification concept inspired by rambam1120 (Issue #14)

🛡️ v2.7.9: Smart Detection & Position Update

08 Mar 20:25
b368f4a

Choose a tag to compare

This update fixes a core detection bug, adds notification positioning, and introduces auto-start for the Replay Buffer.


🐛 Bug Fix

  • 🔍 Fixed is_ignored() False Positives: The ignore check previously used substring matching, which caused some games to be misidentified as system programs.
    • Example: A game called observer.exe was incorrectly ignored because "obs" appeared in its name.
    • Fix: Converted to exact-match hash set (O(1) lookup). Now "obs" only matches the exact process obs.exe, not observer.exe, barcode.exe, etc.
    • Note: Window title substring matching (for anti-cheat fallback) is unchanged and still works correctly.

What's New

  • 📍 Notification Position: Choose where the notification popup appears on screen.

    • Options: Top Right (default), Top Left, Bottom Right, Bottom Left.
    • Position updates instantly when changed — even reuses the existing window.
  • ▶️ Auto-Start Replay Buffer: New option to automatically start the Replay Buffer when OBS launches.

    • Uses a 5-second delay to ensure OBS is fully initialized before starting.
    • Shows a notification confirming the buffer is active.
    • Combined with v2.7.8's "Auto-restart after save", you now have fully hands-free buffer management.
  • 🔧 Dynamic Version String: The log message now uses the VERSION variable instead of a hardcoded string, preventing future mismatches.


💡 How to use:

  1. Position: Go to NOTIFICATIONS → select Position dropdown.
  2. Auto-start: Go to BUFFER CONTROL → enable "Auto-start Replay Buffer on OBS launch".

📋 Idea credits:
Auto-start Replay Buffer suggested by ReiDaTecnologia

🔄 v2.7.8: Buffer Control Update

01 Feb 14:33
a01ba46

Choose a tag to compare

This update introduces a feature to manage your Replay Buffer automatically, ensuring zero overlap between clips.


What's New

  • 🔄 Auto-Restart Buffer: A new option to automatically stop and restart the Replay Buffer immediately after a clip is saved.
    • Benefit: Prevents "overlap" in clips. If you save two clips back-to-back, the second clip will strictly contain only new footage, similar to NVIDIA ShadowPlay's behavior.
    • Safety: Uses an event-driven system to wait for OBS to fully close the file before restarting, ensuring 100% video integrity.
  • 🛠️ UI Changes: Added a new "BUFFER CONTROL" section in script settings.

💡 How to use:

  1. Go to BUFFER CONTROL in script settings.
  2. Enable "Auto-restart Replay Buffer after save".
  3. Now, every time you save a Replay, the buffer will reset instantly.

🤝 Special Thanks
Idea logic by VoidNW

🎨 v2.7.7: Customization Update

31 Jan 19:54
2a0bbb2

Choose a tag to compare

This update focuses on making the notification system more flexible for different setups, especially 4K monitors.


What's New

  • 📏 Notification Scaling (100% - 300%): You can now resize the notification popup! Perfect for 4K monitors where the original popup looked too small.
  • 🔊 Quiet Sound Option: Added a checkbox to switch between the standard sound and a quieter version (notification_sound_silent.wav).
  • 🔘 Test Button: Added a "Test Notification" button in settings so you can preview the size and sound without saving a clip.

💡 How to use Quiet Sound:

  1. Enable "Use Quiet Sound" in script settings.
  2. Place a file named notification_sound_silent.wav in the script folder.
  3. If the file is missing, it falls back to the system default sound.

🤝 Special Thanks
Idea for this update by Nick-2002b

🛡️ v2.7.6: Anti-Cheat Compatibility Update

30 Jan 20:20
9d514ac

Choose a tag to compare

This update solves a critical issue where games protected by strict Anti-Cheat systems (like EasyAntiCheat) were not being detected.


What's New

  • +~445 games: Added many new game to database
  • Robust Game Detection: The script now uses QueryFullProcessImageNameA windows API as a fallback. This allows it to identify game processes even when standard access rights are blocked by Anti-Cheat software.
  • Fixed Games: Confirmed fixes for ARC Raiders and THE FINALS.
  • Safety First: The new logic works safely alongside the existing detection methods, ensuring no changes for standard games.

❤️ Special Thanks:
Huge thanks to Nick-2002b and Ashenk12 for reporting this issue and helping with testing!

🔄 v2.7.5: Auto Update Check System

24 Jan 15:06
ca79dc4

Choose a tag to compare

This update redesigns the update checking system for a better user experience.


What's New

  • Automatic Update Check: The script now checks for updates automatically when loaded, instead of requiring a manual button click.
  • Status at Top of UI: Update status is now prominently displayed at the very top of the script properties panel.
  • "Download Update" Button: When a new version is available, a clickable button appears that opens the GitHub releases page directly in your browser (silently, without showing a terminal window).
  • "Refresh Status" Button: Manually refresh the update status display if you've been waiting for the check to complete.
  • Improved Status Messages: Clearer messages like 🆕 New version available: vX.X.X instead of ambiguous icons.
  • Credits Link: Added "Made by SlonickLab" with a clickable GitHub link in the script description.
  • Dynamic Version Display: The version in the description now automatically reflects the current script version.

💡 Technical Note: OBS cannot programmatically refresh the properties UI from a timer callback. The auto-check runs in the background, and the "Refresh Status" button triggers a UI rebuild to display the updated status.

🛡️ v2.7.4: Stabilization & Critical Crash Fix

12 Jan 13:46
c419484

Choose a tag to compare

🛡️ v2.7.3 (Pull Request by zxsleebu): The Crash Fix

This version focuses on preventing random OBS crashes when saving clips.

  • Thread-Safe Notifications: Fixed the lua51.dll crash by replacing the old Lua-based window handler with a safe Windows native one (DefWindowProcA).
  • Manual Rendering: Since we switched to a native handler, the script now draws text/backgrounds manually using a timer. This is much safer and avoids thread-related errors.
  • Handle Validation: Added extra checks (IsWindow) to make sure the script doesn't try to draw on a window that's already closed.

🛡️ v2.7.4: Performance & Memory Fixes

  • Update Checker: Added a "Check for Updates" button at the bottom of the settings. It safely checks the main branch on GitHub and notifies you if a new version is available.
  • Frozen OBS Fix (Window Reuse): Solved the hard freeze when starting recordings/screenshots simultaneously.
  • Redraw Throttling: I've optimized rendering so notifications only draw once, significantly reducing CPU usage.
  • Recording Stability: Added a 0.5s delay for recording start tasks to prevent initialization crashes.
  • Screenshot Burst Support: Added a 2-second detection cache and notification throttling to handle rapid bursts.
  • GDI Leak Fix: Fixed a small memory leak where the background brush wasn't being deleted when you reloaded the script.
  • Cleaner Cleanup: Now the script properly removes all timers (like delayed_recording_init) when you unload it, preventing errors in the OBS log.
  • State Reset: Explicitly resets all window handles and states to zero after a notification disappears to prevent overlaps.

💡 Credit: Many thanks to zxsleebu for Pull Request v2.7.3. Your diagnosis of the re-entry issue in lua51.dll helped me release this stability update much faster.