From f2b1609320d78a51b3b5cc4fe7cc1a60c93fabd0 Mon Sep 17 00:00:00 2001 From: Aussiemon Date: Wed, 5 Apr 2023 00:45:35 -0600 Subject: [PATCH] Fix FFI backup and print path in patcher script --- binaries/mod_loader | 10 +++++----- toggle_darktide_mods.bat | 2 +- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/binaries/mod_loader b/binaries/mod_loader index a84d8cd..b762483 100644 --- a/binaries/mod_loader +++ b/binaries/mod_loader @@ -1,10 +1,5 @@ local mod_directory = "./../mods" --- Mod initialization code -- -local debug = debug -local io = io -local ffi = ffi - local assert = assert local ipairs = ipairs local loadstring = loadstring @@ -20,6 +15,11 @@ local table = table local tonumber = tonumber local tostring = tostring +-- Mod initialization code -- +local debug = rawget(_G, "debug") +local io = rawget(_G, "io") +local ffi = require("ffi") + Mods = { file = {}, message = {}, diff --git a/toggle_darktide_mods.bat b/toggle_darktide_mods.bat index abfed86..0862cb0 100644 --- a/toggle_darktide_mods.bat +++ b/toggle_darktide_mods.bat @@ -1,5 +1,5 @@ @echo off -echo Starting Darktide patcher... +echo Starting Darktide patcher from %~dp0... .\tools\dtkit-patch --toggle .\bundle if errorlevel 1 goto failure pause