Commit Graph

167 Commits

Author SHA1 Message Date
NotAlwaysTrue
9b35f6b23f Sync with upstream
* Update bug-reports.yml

* Fix modifyChatMessage hook

* Add LuaCsSetup.Lua back for compatibility

* Fix Game.AssignOnExecute having command arguments be passed as varargs instead of a table

* Actually use the PackageId const everywhere we need to refer to our content package

* Load languages files even if the package is disabled

* Fix Hook.Remove not being implemented properly

* - Changed event aliases to be case insensitive.

* - Fixed assembly logging style.
- Fixed double logging during execution.

* Fix garbage network data being read by the game when reading LuaCs network messages

* PackageId -> PackageName

* Added caching toggle to PluginManagementService

* Fix LuaCs initializing too late for singleplayer campaigns and rework the C# prompt to only show when enabling mods/joining server

* Oops, fix NRE crash

* Fix hide username in logs config not doing anything

* Fix Cs prompt showing up more than one between rounds

* Fix server host being prompted twice with the C# popup

* Ignore our workshop packages from the game's dependency thing since it doesn't really make sense

* Load console commands after executing and possible fix for the not console command permitted

* Added fallback friendly name resolution for ModConfig assembly contents.

* Register Voronoi2 stuff

* Added configinfo null check to SettingBase.cs

* Add safety check so this stops crashing when we look at it the wrong way

* Fixed "Folder" attribute files not being found.

* Keep the LuaCsConfig class laying around for compatibility, not sure anywhere in our code base (and shouldn't be)

* Added fallback compilation for UseInternalsAwareAssembly if the publicized script compilation fails.

* Added legacy overload of AddCommand for mod compat.

* Added LoggerService to Lua env. Made ILoggerService compliant with LuaCsLogger API.

* Changed csharp script compilation algorithm to be best effort.

* Added "RunUnrestricted" mode for lua scripts that need to run outside of sandbox.

* - Fixed networking sync vars failing to sync initially.
- Fixed lua failing to differentiate overloads ISettingBase.

* Add alias for human.CPRSuccess and human.CPRFailed

* - Fixed up the settings menu.
- Made SettingEntry throw an error if "Value" attribute is not found in XML.
- Fixed saved values for settings sometimes not reloading after disabling and re-enabling a package.

* Fix LuaCs net messages received during connection initialization to be read incorrectly, happened because we would reset the BitPosition in our harmony patch which would cause the message to be read incorrectly later

* Allow reloadlua to force the state to running

* New icon for settings and make the top left text more user friendly

* Fix client.packages hook sending normal packages

* Fixed OnUpdate() not passing in deltaTime instead of totalTime.

* Missing diffs from bb21a09244

* Added networking tests for configs.

* Added missing diffs for f61f852a25.

* Some tweaks to the text

* Remove missing Value error, it should just use the default value if it's not specified

* Fix UseInternalAccessName

* Always purge cashes for plugin content on unloading.

* Fix texture not multiple of 4

* v1.12.7.0 (Spring Update 2026 Hotfix 1)

---------

Co-authored-by: Joonas Rikkonen <poe.regalis@gmail.com>
Co-authored-by: Evil Factory <36804725+evilfactory@users.noreply.github.com>
Co-authored-by: MapleWheels <njainanan@hotmail.com>
2026-04-25 12:10:24 +08:00
Evil Factory
3a5fbfde1e Fix cs enabled for session state not being preserved between reloads 2026-04-08 20:12:20 -03:00
MapleWheels
ebe8ec455f LuaCs CSharp Enabled Rework
- New UI for the prompt

- Third time's the charm.

- Fixed TOCTOU for cs prompt on main menu. - Fixed SubEditor not running lua when don't run is selected for cs.

- LuaCs CSharp Enabled Rework
2026-04-08 16:31:42 -03:00
MapleWheels
1294ba6dec - Added API to get package by name to PackageManagementService.cs and LuaScriptManagementService.cs
- Added ILuaConfigService to Lua API.
2026-04-08 11:03:52 -04:00
Evil Factory
f05d4ef129 Fic CSharp enabling message printing before config got loaded 2026-04-04 12:24:12 -03:00
MapleWheels
413cc3ed4c - Added setting to disable lua scripts caching in the storage service for scenarios that use extern editors. 2026-04-02 23:29:21 -04:00
MapleWheels
4f2da55a8e - Added legacy LuaCsPerformanceCounter.cs
- Added legacy redirects.
- Added IConsoleCommandsService injection to plugins.
2026-03-31 10:48:44 -04:00
Evil Factory
2ea97d3d5e Add CallLuaFunction legacy redirect 2026-03-28 10:52:33 -03:00
MapleWheels
ac329a70a4 - Reduced console spam when failing to load config file in release builds.
- Added console logging for failing to unload assembly load ctx.
- Removed unused StorageService instance.
- Removed unused luacs settings.
- Added plugin event service and event service dispatcher api.
2026-03-22 18:01:19 -04:00
Evil Factory
de53b4514e Fix console command registration 2026-03-22 12:42:09 -03:00
Evil Factory
8717706b1c Fix check ready to run not working properly 2026-03-15 18:44:15 -03:00
Evil Factory
b402e09b82 Move MainMenu code to a separate service that just injects our stuff into the mainmenu 2026-03-15 17:52:40 -03:00
Evil Factory
f802356b0a Add legacy redirect for LuaCsSetup.Timer 2026-03-14 14:31:03 -03:00
MapleWheels
5b52d22b1f Added references cache for some hot paths services. 2026-03-06 18:15:44 -05:00
MapleWheels
1fe68aa861 - Added float, double settingentry types. Adjusted display formatting.
- Added menu refresh on Apply button.
- Fixed package name resolution for invalid chars.
- Added helper console command to get xml-safe name for use in localization files.
- Made error messages for bad settings xml more descriptive.
- Modified GUISlider.
- Converted HarmonyEventPatchesService to a System.
- Fixed package name resolution for incompatible names in Xml and files, in many places.
- Fixed base textbox implementation for settings.
2026-03-05 15:45:00 -05:00
Evil Factory
9ee4728e2a Better logging 2026-03-01 13:09:05 -03:00
Maplewheels
e74f083300 LuaCs package bug fixed. 2026-02-28 22:32:01 -05:00
Evil Factory
8e8b8eb8aa GameMain.LuaCs is no more 2026-02-28 16:05:20 -03:00
MapleWheels
d9d980122d - Moved all console commands to their respective services and added via injector service.
- Fixed LuaCs IsCsEnabled prompt not working.
- Add settings profiles support.
2026-02-24 15:26:49 -05:00
Maplewheels
6ac49a10f4 - XML GUI Asset service implemented (alpha, requires testing). 2026-02-16 02:22:14 -05:00
MapleWheels
07d838eee0 Finished removing Impromptu Interfaces package. 2026-02-12 14:59:24 -05:00
MapleWheels
ad152ee747 - pOoosh 2026-02-11 15:19:40 -05:00
MapleWheels
471e256353 Revert "-- MonoMod.Hook replacement."
This reverts commit 948b7c48c5.
2026-02-11 15:17:32 -05:00
MapleWheels
948b7c48c5 -- MonoMod.Hook replacement. 2026-02-11 12:57:49 -05:00
MapleWheels
9e2fc13460 - Fixed the server not loading saved convars and not having absolute authority. 2026-02-10 18:48:31 -05:00
MapleWheels
6b9e48f96a - Added ISystem (automatically run services) service type. 2026-02-10 14:28:22 -05:00
Evil Factory
fb4648d759 Converting everything into Harmony patches part 1 2026-02-09 21:54:44 -03:00
MapleWheels
95376622fa - Added LuaCsForBarotrauma check to enabled packages list. 2026-02-09 16:58:53 -05:00
Maplewheels
a505d48a4c - Loading/Saving for Settings via console. 2026-02-08 20:23:49 -05:00
Evil Factory
5b10661874 Legacy network stuff 2026-02-08 18:26:59 -03:00
Evil Factory
36a126774a Register INetworkIdProvider 2026-02-08 15:06:22 -03:00
Maplewheels
224e32ccf1 Some work on save/load for configs. 2026-02-08 06:39:44 -05:00
Maplewheels
67c195034d Network Sync work. Added network unique key. 2026-02-07 22:58:56 -05:00
Evil Factory
e76aaf5a34 Fix deadlock when reloading packages 2026-02-07 23:29:00 -03:00
Evil Factory
ba10d9d031 Working NetworkingService without net vars 2026-02-07 20:11:46 -05:00
MapleWheels
771e73a798 - Basic Config & Settings working (read-only, changes must be made via debug halt). 2026-02-07 20:11:46 -05:00
MapleWheels
e75208507d - Config Services almost ready.
- Refactored and flattened namespaces.
2026-02-07 20:11:46 -05:00
MapleWheels
863ee23583 - Some work on config service. 2026-02-07 20:11:46 -05:00
Evil Factory
70dd602bcf Move the Lua IL patching bullshit to a separate service 2026-02-07 20:11:45 -05:00
MapleWheels
36bed09bde - Fixed stack ovewrflow from ServicesProvider (???). 2026-02-07 20:11:45 -05:00
Evil Factory
5777b64a18 Move LuaUserData and registration into a proper service 2026-02-07 20:11:41 -05:00
Evil Factory
708fe93efe Some extra logging and bring back LuaCsTimer 2026-02-07 20:11:08 -05:00
MapleWheels
13a9bc443e - Some work on PluginManagementService, IAssemblyLoaderService and IAssemblyManagementService refactors.
- Fixed mod list sync not checking for zero package diff length.
- Fixed the services provider not being able to inject itself as a dependcency.
- Added UseInternalName data spec to ModConfig.xml
- Changed Basic.Reference.Assemblies to Net80.
2026-02-07 20:11:08 -05:00
MapleWheels
37e3a195dc - Now logs results from SyncLoadedPackagesList 2026-02-07 20:11:08 -05:00
MapleWheels
92232d114b Ensures that ILuaCsHook will resolve to the existing event service instance. 2026-02-07 20:11:07 -05:00
Evil Factory
3d51abc56b Semi-working Lua scripts 2026-02-07 20:11:06 -05:00
Maplewheels
0a9c673753 - Removed unused settings
- Added Settings.xml
2026-02-07 20:11:06 -05:00
MapleWheels
6e66a3114a - Made Package loading conditional on resources being available.
- Made States registration use named parameters.
- Changed IPluginManagementService interface to better suit expected return results.
2026-02-07 20:10:55 -05:00
MapleWheels
15e0a2bd10 Disabled LuaCsConfig until ModConfig.xml and ISettingEntry<T> are completed. 2026-02-07 20:10:55 -05:00
MapleWheels
09faa8403a Fixed StatemMachine State delegate assignment being backwards. 2026-02-07 20:10:55 -05:00