Skip to content

Instantly share code, notes, and snippets.

@natyusha
natyusha / 23.975fps-to-24fps-chapters
Created September 6, 2025 11:02
A utility that automatically compresses timestamps for mkv chapter xml files from 23.976fps sources that have been converted to 24fps (only affects ChapterTimeStart as other timestamps can be removed)
#!/usr/bin/env python3
import os, sys
import tkinter as tk
import xml.etree.ElementTree as ET
try:
from tkinterdnd2 import TkinterDnD, DND_FILES
except ImportError:
print('Please install tkinterdnd2: pip install tkinterdnd2')
sys.exit(1)
@natyusha
natyusha / 23.976fps-to-24fps-subtitles.lua
Last active September 6, 2025 10:29
An Aegisub macro which automatically compresses timestamps for 23.976fps sources that have been converted to 24fps
script_name = "23.976fps to 24fps Subtitles"
script_description = "Automatically compress timestamps for 23.976fps sources that have been converted to 24fps"
script_author = "natyusha"
script_version = "1.0"
function f23_976fps_to_24fps(subs)
-- Scale factor for 23.976fps to 24fps conversion (23.976 / 24)
local scale_factor = 23.976 / 24 -- Approximately 0.999 (999 / 1000)
-- Process all subtitle lines
@natyusha
natyusha / autovsr.lua
Last active July 12, 2025 05:04 — forked from azumukupoe/autovsr.lua
AutoVSR for MPV w/ HEVC Main 10 Support
local mp = require 'mp'
-- Configuration
local autovsr_enabled = true -- Default to VSR enabled
-- Function to apply VSR with dynamic scaling
local function apply_vsr()
-- Get video and display properties
local video_width = mp.get_property_number("width")
local video_height = mp.get_property_number("height")
@natyusha
natyusha / LuaRenamer-NN.lua
Last active July 6, 2025 02:06
Shoko Anime Lua Renamer Config
-- ###### Shoko LuaRenamer NN ######
-- ### Table Manipulation Functions ###
function append(t, s)
s = string.lower(s)
custom_tags = {}
for i = 1,#t do
if(s:match("%[" .. t[i] .. "%]")) then table.insert(custom_tags, s:match("%[" .. t[i] .. "%]")) end
end
return " " .. table.concat(custom_tags, " ")
@natyusha
natyusha / anidb_tmdb_xrefs.csv
Last active August 14, 2025 01:22
Shoko: AniDB → TMDB Mappings
We can't make this file beautiful and searchable because it's too large.
AnidbAnimeId,AnidbEpisodeId,TmdbMovieId,IsAutomatic
5,163129,969850,False
7,6585,128,False
28,10063,149,False
43,257,919,True
44,19968,62182,False
61,378,9323,True
66,399,15999,False
78,472,9606,True
83,11614,823,False
@natyusha
natyusha / anidb_tmdb_xrefs+comments.csv
Last active August 14, 2025 01:22
Shoko: AniDB → TMDB Mappings (Comments)
We can't make this file beautiful and searchable because it's too large.
#--------------------------------------------------
# AniDB/TMDB Movie Cross-References
AnidbAnimeId,AnidbEpisodeId,TmdbMovieId,IsAutomatic
#--------------------------------------------------
# AniDB: TV ``Seikai no Senki II`` (a5) S01 (e163129) ``Banner of the Stars II Movie`` (e163129) → TMDB: ``Banner of the Stars II Movie`` (m969850)
5,163129,969850,False
@natyusha
natyusha / pairedmuxing.py
Last active September 5, 2025 01:07
This script takes a raw video file and muxes it together with another video file. It will retain chapters/subtitles/attachments from the old file and sync them if there is a delay. Options are included for simply formatting a new file, adding extra audio tracks, and exporting subtitles/attachments/chapters to go along with raws.
#!/usr/bin/env python3
import os, re, sys, json, time, shutil, argparse, subprocess
from xml.etree import ElementTree
r"""
Description:
- This script takes a raw video file and muxes it together with another video file
- It will retain chapters/subtitles/attachments from the old file and sync them if there is a delay
- This script has not been tested on linux and likely won't run there without significant changes
Author:
@natyusha
natyusha / FFXIV Macro HUD.md
Last active April 27, 2025 12:43
An example FFXIV macro HUD.

FFXIV Macro HUD

Macros from an example HUD configuration intended for those who don't use a controller and have no need for the cross hotbars. The hotbar number(s) and slots used in the reference image are listed next to the macro name when applicable (hotbar# :: slot#).

References

FFXIV-MACRO-HUD-Reference HUD Video Walkthrough

Required FFXIV Settings

Tip

Consider disabling "Error Messages" under Character Configuration > Log Window Settings > Log Filters > Chat Tab Name > Announcements. Otherwise some of these macros will spawn errors in the chat under certain circumstances. To avoid this while leaving "Error Messages" enabled you can prepend /merror off to all of the macros below instead.

@natyusha
natyusha / Naty's FFXIV Dawntrail Add-ons, Plugins and Mods.md
Last active September 6, 2025 09:56
All the third party add-ons, plugins and mods I use for FFXIV.

Last Updated: Patch 7.25

The program which most people use for parsing in FFXIV and several other MMOs. For an open source alternative consider using IINACT though configuring it won't be covered here.

Options

  • Main Table Encounters
    • General
      • Uncheck: Number of seconds to wait after the last combat action to begin a new encounter.
      • Uncheck: Number of seconds to wait after the last combat action to pause the encounter duration.

Plugins

@natyusha
natyusha / KeepUI_FFXIV.fx
Created October 22, 2019 10:51
Keep UI for FFXIV Mirror
// KeepUI for FFXIV
// Author: seri14
//
// This is free and unencumbered software released into the public domain.
//
// Anyone is free to copy, modify, publish, use, compile, sell, or
// distribute this software, either in source code form or as a compiled
// binary, for any purpose, commercial or non-commercial, and by any
// means.
//