Skip to content

Commit 9da52a3

Browse files
committed
Add compatibility with new beta versions
- `Build Dec 30 2023 19:37:04` - `Build Dec 30 2023 19:40:49`
1 parent e83aa68 commit 9da52a3

File tree

1 file changed

+17
-0
lines changed

1 file changed

+17
-0
lines changed

files/modification.lua

+17
Original file line numberDiff line numberDiff line change
@@ -178,6 +178,16 @@ function Modification.SetMemoryOptions(memory)
178178
mPlayerNeverDies = function(value) ffi.cast("char*", 0x01117592)[0] = value end,
179179
mFreezeAI = function(value) ffi.cast("char*", 0x01117593)[0] = value end,
180180
},
181+
{_Offset = 0x00F74FA8, _BuildString = "Build Dec 30 2023 19:37:04", -- Steam dev build.
182+
mPostFxDisabled = function(value) ffi.cast("char*", 0x0111A5BC)[0] = value end,
183+
mGuiDisabled = function(value) ffi.cast("char*", 0x0111A5BD)[0] = value end,
184+
mGuiHalfSize = function(value) ffi.cast("char*", 0x0111A5BE)[0] = value end,
185+
mFogOfWarOpenEverywhere = function(value) ffi.cast("char*", 0x0111A5BF)[0] = value end,
186+
mTrailerMode = function(value) ffi.cast("char*", 0x0111A5C0)[0] = value end,
187+
mDayTimeRotationPause = function(value) ffi.cast("char*", 0x0111A5C1)[0] = value end,
188+
mPlayerNeverDies = function(value) ffi.cast("char*", 0x0111A5C2)[0] = value end,
189+
mFreezeAI = function(value) ffi.cast("char*", 0x0111A5C3)[0] = value end,
190+
},
181191
},
182192
},
183193
[false] = {
@@ -231,6 +241,13 @@ function Modification.SetMemoryOptions(memory)
231241
ptr[0] = value -- This basically just changes the value that Noita forces to the "mods_have_been_active_during_this_run" member of the WorldStateComponent when any mod is enabled.
232242
end,
233243
},
244+
{_Offset = 0x00E180E8, _BuildString = "Build Dec 30 2023 19:40:49", -- Steam build.
245+
enableModDetection = function(value)
246+
local ptr = ffi.cast("char*", 0x00626EFD)
247+
Memory.VirtualProtect(ptr, 1, Memory.PAGE_EXECUTE_READWRITE)
248+
ptr[0] = value -- This basically just changes the value that Noita forces to the "mods_have_been_active_during_this_run" member of the WorldStateComponent when any mod is enabled.
249+
end,
250+
},
234251
},
235252
},
236253
}

0 commit comments

Comments
 (0)