Skip to content

Instantly share code, notes, and snippets.

View X-Raym's full-sized avatar

Raymond Radet X-Raym

View GitHub Profile
@X-Raym
X-Raym / X-Raym_Repeat action by sets of 100 items max in selection.lua
Created February 14, 2022 17:32
repeat action by sets of 100 items max in selection
--[[
* ReaScript Name: Repeat action by sets of 100 items max in selection
* Screenshot: https://i.imgur.com/nQsH3mL.gif
* Author: X-Raym
* Author URI:
* Repository:
* Repository URI:
* Licence: GPL v3
* Forum Thread:
* Forum Thread URI:
@X-Raym
X-Raym / open X-Raym ReaScript API.js
Created March 3, 2021 13:15
Grease monkey script to open X-Raym ReaScript API from local reascript.help.html
// ==UserScript==
// @name ReaScript Doc: Local to XR
// @version 1
// @grant none
// ==/UserScript==
// console.log(window.location)
window.addEventListener("load", function(event) {
if( window.location.toString().search("reascripthelp.html") >= 0 ) {
<?php
/*
Plugin Name: LearnDash Add Button On Quiz Fail
Description: Add Learndash continue button even if user fails the quiz. Based on https://developers.learndash.com/hook/show_quiz_continue_buttom_on_fail/
*/
add_filter( 'show_quiz_continue_buttom_on_fail', 'show_quiz_continue_buttom_on_fail_proc', 10, 2 );
function show_quiz_continue_buttom_on_fail_proc( $show_button = false, $quiz_id = 0 ) {
return true;
}
@X-Raym
X-Raym / Missing Davinci Resolve Actions.md
Created November 20, 2020 22:43
Missing davinci resolve action
  • Split at markers
  • Select all itemw with same source

Missing API:

  • select items
  • split items
--[[
* ReaScript Name: Save_FX_Preset
* Lua script for Cockos REAPER
* Author: EUGEN27771
* Author URI: http://forum.cockos.com/member.php?u=50462
* Licence: GPL v3
* Version: 1.04
* Mod by X-Raym
]]
spearkers_presets = {}
spearkers_presets[1] = speakers_bits["KSAUDIO_SPEAKER_MONO"]
spearkers_presets[2] = speakers_bits["KSAUDIO_SPEAKER_STEREO"]
spearkers_presets[3] = speakers_bits["SPEAKER_FRONT_LEFT"] + speakers_bits["SPEAKER_FRONT_CENTER"] + speakers_bits["SPEAKER_FRONT_CENTER"] -- custom LCR
spearkers_presets[4] = speakers_bits["KSAUDIO_SPEAKER_QUAD"]
spearkers_presets[5] = speakers_bits["KSAUDIO_SPEAKER_SURROUND"]
spearkers_presets[6] = speakers_bits["KSAUDIO_SPEAKER_5POINT1_SURROUND"]
spearkers_presets[7] = speakers_bits["SPEAKER_FRONT_LEFT"] + speakers_bits["SPEAKER_FRONT_RIGHT"] + speakers_bits["SPEAKER_FRONT_CENTER"] + speakers_bits["SPEAKER_SIDE_LEFT"] + speakers_bits["SPEAKER_SIDE_RIGHT"] -- custom , based on 7.1, without LFE
spearkers_presets[8] = speakers_bits["KSAUDIO_SPEAKER_7POINT1_SURROUND"]
@X-Raym
X-Raym / memberpress-corporate-all-sub-accounts.php
Last active July 9, 2020 16:24 — forked from cartpauj/memberpress-corporate-all-sub-accounts.php
Get all sub-accounts for a parent user in MemberPress Corporate Accounts
<?php
/**
* Plugin Name: MemberPress Corporate Sub Account Shortcode
* Plugin URI: https://gist.github.com/X-Raym/a2c5a2eb05b9be3c04ee9972876aa2df/edit
* Description: AMemberPress Corporate Sub Account Shortcode
* Author: X-Raym
* Author URI: https://www.extremraym.com/
* License: GNU AGPLv3
* License URI: http://www.gnu.org/licenses/agpl-3.0.html
@X-Raym
X-Raym / X-Raym_Search and replace.py
Last active June 25, 2020 16:37
Search and replace in text files from a folder and its subfolders without changing last modified date - Here is demo with .rpp and .rpp-bak files REAPER files
import sys
import os
from os import path
debug = False
#### USER INPUT ####
if debug:
dirName = "E:\\Bureau\\"
search = "F:\\Bureau\\SOUNDS"
@X-Raym
X-Raym / affinity script - obect.lua
Last active May 9, 2020 14:39
Affinity App API Protocode
-- Object based. Like Adobe API.
doc = affinity.GetDocument(1) -- get first opened doc. affinity is an objevt with all functions exposed by the api.
layer = doc.GetLayer(1) --get first dpcument. return a layer obect with its own set of functions.
name = layer.GetName() -- get name from layer object
layer.SetName( name:gsub(search, replace) ) -- use Set method of layer object.
resolve = Resolve()
pm = resolve:GetProjectManager()
proj = pm:GetCurrentProject()
tl = proj:GetCurrentTimeline()
items = tl:GetItemsInTrack("subtitle", 1)
for i, v in ipairs( items ) do
print( v:GetName() )
end