REPENTOGON phase 5, complete: the render pipeline API, the last functions, XML and behaviour patches, EntitySaveStateEx, the Log window; ASMPatch and Steam-only tests not applicable (13 rows); the REPENTOGON global exposed as version 1.1.3 (e2c5aec); LuaBridge class __type and require search fixes; coverage 2,834 of 2,834; the 12 REPENTOGON mods run without errors alone and together; 72 goldens identical from converted resources and the install
This commit is contained in:
1 parent
8c95737332
commit
4ff67e2e96
145 files changed
+6414
-322
No files matched your search
@@ -1,7 +1,7 @@
|
||||
REPENTOGON = {
|
||||
["Real"] = true,
|
||||
["Name"] = "REPENTOGON", --I avoid having to do RegisterMod this way, sorry ;P
|
||||
["Version"] = "dev build",
|
||||
["Version"] = "1.1.3",
|
||||
["Extras"] = { ["Misc"]={}, }, -- Tables containing additional REPENTOGON data structures, example: ChangeLog or StatsMenu
|
||||
}
|
||||
|
||||
@@ -70,13 +70,12 @@ function _GetModule(modName)
|
||||
end
|
||||
|
||||
local RaiseModError = _CBindings.RaiseModError
|
||||
-- rebuild: the vanilla parity option and whether the REPENTOGON global is exposed
|
||||
-- rebuild: the vanilla parity option
|
||||
local IsVanillaParity = _CBindings.IsVanillaParity
|
||||
local IsExposed = _CBindings.IsExposed
|
||||
local ModManager = _GetModule("repentogon_extras.mod_manager")
|
||||
|
||||
local function MeetsVersion(targetVersion)
|
||||
if (REPENTOGON.Version == "dev build") then return true end
|
||||
if (REPENTOGON.Version == "1.1.3") then return true end
|
||||
local version = {}
|
||||
local target = {}
|
||||
|
||||
@@ -750,14 +749,6 @@ local err_dupecount = 1
|
||||
---@type string[]
|
||||
local printedWarnings = {}
|
||||
|
||||
-- rebuild: the console prints until REPENTOGON's Console is ported
|
||||
local Console = Console or {
|
||||
GetHistory = function() return {} end,
|
||||
PopHistory = function() end,
|
||||
PrintError = print,
|
||||
PrintWarning = print,
|
||||
}
|
||||
|
||||
local function logWarning(callbackID, modName, warn)
|
||||
local cbName = callbackIDToName[callbackID] or callbackID
|
||||
for _, printedWarning in pairs(printedWarnings) do
|
||||
@@ -1312,10 +1303,10 @@ end
|
||||
function _UnloadMod(mod)
|
||||
-- _UnloadMod is called late into the shutdown process where it is not safe to run a callback.
|
||||
-- We separately trigger MC_PRE_MOD_UNLOAD earlier in the shutdown process.
|
||||
-- rebuild: vanilla parity runs it as main.lua does, and IsShuttingDown is not ported yet
|
||||
-- rebuild: vanilla parity runs it as main.lua does
|
||||
if IsVanillaParity() then
|
||||
Isaac.RunCallback(ModCallbacks.MC_PRE_MOD_UNLOAD, mod)
|
||||
elseif not (Isaac.IsShuttingDown and Isaac.IsShuttingDown()) then
|
||||
elseif not Isaac.IsShuttingDown() then
|
||||
Isaac.RunCallback(ModCallbacks.MC_PRE_MOD_UNLOAD, mod, false)
|
||||
end
|
||||
|
||||
@@ -2044,7 +2035,6 @@ local ModReference_SaveModFile = _CBindings.ModReference_SaveModFile
|
||||
local ModReference_LoadModFile = _CBindings.ModReference_LoadModFile
|
||||
local ModReference_RemoveModFile = _CBindings.ModReference_RemoveModFile
|
||||
|
||||
if ModReference_HasModFile then -- rebuild: until the mod file bindings are ported
|
||||
rawset(Isaac, "HasModData", function(modRef, filename)
|
||||
if type(filename) == "string" then
|
||||
return ModReference_HasModFile(modRef, filename)
|
||||
@@ -2076,7 +2066,6 @@ rawset(Isaac, "RemoveModData", function(modRef, filename)
|
||||
return Original_RemoveModData(modRef)
|
||||
end
|
||||
end)
|
||||
end
|
||||
|
||||
--Menuman Hub
|
||||
MenuManager.MainMenu = MainMenu
|
||||
@@ -2237,8 +2226,7 @@ end
|
||||
-- This can allow us to circumvent how the old wrappers handled certain inputs, as well as make
|
||||
-- errors report the actual call site instead of the line in `scripts/main.lua`.
|
||||
-- Make sure you understand what the old wrapper was doing, and that the new hook maintains any features like optional args.
|
||||
-- rebuild: only once the REPENTOGON global is exposed, as these need its own versions of the functions
|
||||
local LuaWrappersToRemove = IsExposed and {
|
||||
local LuaWrappersToRemove = {
|
||||
{ ItemPool, {"GetCollectible"} },
|
||||
{
|
||||
EntityPlayer, {
|
||||
@@ -2258,7 +2246,7 @@ local LuaWrappersToRemove = IsExposed and {
|
||||
}
|
||||
},
|
||||
}
|
||||
for _, tab in ipairs(LuaWrappersToRemove or {}) do
|
||||
for _, tab in ipairs(LuaWrappersToRemove) do
|
||||
local class = tab[1]
|
||||
|
||||
local mt = getmetatable(class).__class
|
||||
@@ -2276,7 +2264,7 @@ end
|
||||
LuaWrappersToRemove = nil
|
||||
|
||||
|
||||
if IsExposed then -- rebuild: the menu extras need the REPENTOGON global and the menu API
|
||||
if not IsVanillaParity() then -- rebuild: the menu extras change the vanilla menus
|
||||
pcall(require, "repentogon_extras/changelog")
|
||||
pcall(require, "repentogon_extras/daily_stats")
|
||||
pcall(require, "repentogon_extras/stats_menu")
|
||||
|
||||
Reference in new issue
Block a user