this repo has no description
1import { Patch } from "@moonlight-mod/types"; 2 3export const patches: Patch[] = [ 4 { 5 find: "isStaffPersonal:", 6 replace: { 7 match: /&&null!=this\.personalConnectionId/, 8 replacement: "||!0" 9 } 10 }, 11 { 12 find: '"scientist:triggered"', // Scientist? Triggered. 13 replace: { 14 match: /(?<=personal_connection_id\|\|)!1/, 15 replacement: "!0" 16 } 17 }, 18 19 // Enable staff help menu 20 // FIXME: either make this actually work live (needs a state hook) or just 21 // wait for #122 22 { 23 find: ".HEADER_BAR)", 24 replace: { 25 match: /&&\((.)\?\(0,/, 26 replacement: (_, isStaff) => 27 `&&(((moonlight.getConfigOption("experiments","devtools")??false)?true:${isStaff})?(0,` 28 } 29 }, 30 31 // Enable further staff-locked options 32 // FIXME: #122, this doesn't work live 33 { 34 find: '"useGenerateUserSettingsSections"', 35 replace: { 36 match: /isStaff:(.),/, 37 replacement: (_, isStaff) => 38 `isStaff:(moonlight.getConfigOption("experiments","staffSettings")??false)?true:${isStaff},` 39 } 40 } 41];