tModLoader

tModLoader

Radiance
Enculaire 9 Aug, 2022 @ 8:07am
Multiplayer - Radiance x WingSlot mods issue.
Reporting an issue that involves both Radiance and WingSlot mods on Multiplayer

On equipping wings in the wingslots : Dedicated server crashes instantly.
No idea if this is because I have too many mods installed.
If Radiance is disabled on server, WingSlot works again.
However, the same issue did not occur on Steam P2P multiplayer.

[14:21:55.205] [Main Thread/WARN] [tML]: Silently Caught Exception: System.Collections.Generic.KeyNotFoundException: Instance of 'PlayerTweaks' does not exist on the current player. at Terraria.Player.GetModPlayer[T](T baseInstance) in tModLoader\Terraria\Player.TML.cs:line 39 at Radiance.PlayerTweaks.GetWingStats(orig_GetWingStats orig, Player self, Int32 wingID) in Radiance\PlayerTweaks.cs:line 180 at Terraria.Player.ApplyEquipFunctional(Item currentItem, Boolean hideVisual) in tModLoader\Terraria\Player.cs:line 11132 at Terraria.ModLoader.ModAccessorySlot.ApplyEquipEffects() in tModLoader\Terraria\ModLoader\ModAccessorySlot.cs:line 81 at Terraria.ModLoader.Default.ModAccessorySlotPlayer.UpdateEquips() in tModLoader\Terraria\ModLoader\Default\ModAccessorySlotPlayer.cs:line 143 at Terraria.ModLoader.PlayerLoader.UpdateEquips(Player player) in tModLoader\Terraria\ModLoader\PlayerLoader.cs:line 219 at Terraria.Player.UpdateEquips(Int32 i) in tModLoader\Terraria\Player.cs:line 10057 at DMD<Terraria.Player::Update>(Player this, Int32 i) at DMD<Terraria.Main::DoUpdateInWorld>(Main this, Stopwatch sw) at Terraria.Main.DoUpdate(GameTime& gameTime) at Terraria.Main.Update(GameTime gameTime) at DMD<Terraria.Main::DedServ_PostModLoad>(Main this, Boolean& reloadMods) at Terraria.Main.DedServ() at Terraria.Program.LaunchGame_(Boolean isServer) at Terraria.Program.LaunchGame(String[] args, Boolean monoArgs) at MonoLaunch.<>c__DisplayClass1_0.<Main>b__0() at MonoLaunch.Main(String[] args)

This will be hard to fix I think...
< >
Showing 1-5 of 5 comments
envyukplays 10 Aug, 2022 @ 8:43am 
This error does not just occur with the Wing Slot mod (although the instant crash seems to be related to that slot)

System.NullReferenceException: Object reference not set to an instance of an object. at Terraria.Player.GetModPlayer[T](T baseInstance) in tModLoader\Terraria\Player.TML.cs:line 39 at Radiance.PlayerTweaks.GetWingStats(orig_GetWingStats orig, Player self, Int32 wingID) in Radiance\PlayerTweaks.cs:line 180 at Terraria.Player.ApplyEquipFunctional(Item currentItem, Boolean hideVisual) in tModLoader\Terraria\Player.cs:line 11132 at Terraria.Player.UpdateEquips(Int32 i) in tModLoader\Terraria\Player.cs:line 10054 at DMD<Terraria.Player::Update>(Player this, Int32 i) at DMD<Terraria.Main::DoUpdateInWorld>(Main this, Stopwatch sw) at Terraria.Main.DoUpdate(GameTime& gameTime) at DMD<Terraria.Main::Update>(Main this, GameTime gameTime) at ImproveGame.Common.Systems.NetPasswordSystem.CheckConnected(orig_Update orig, Main self, GameTime gameTime) at Terraria.Main.DedServ_PostModLoad(Boolean& reloadMods) at Terraria.Main.DedServ() at Terraria.Program.LaunchGame_(Boolean isServer) at Terraria.Program.LaunchGame(String[] args, Boolean monoArgs) at MonoLaunch.<>c__DisplayClass1_0.<Main>b__0() at MonoLaunch.Main(String[] args)

I get this error on a dedicated server without the Wing Slot mod. It does not cause any issues that I can immediately notice, so reporting for visibility.
Stellar  [developer] 10 Aug, 2022 @ 1:47pm 
I'm trying to reproduce this. I did the following:
- Loaded Radiance and Wing Slot Extra.
- Started a dedicated server through 'start-tModLoaderServer.bat'; No steam multiplayer.
- Equipped Celestial Starboard, Empress Wings. Tried unequipping wings as well.

Everything works as intended. No crash, not even an error. Did you do something different?

I might be able to make a band-aid patch for this, but the Empress Wings + Radiant Charm synergy probably still won't work. (Better than the game crashing, though)
Stellar  [developer] 10 Aug, 2022 @ 6:19pm 
A patch to (hopefully) prevent crashing has been released.

If the issue occurs, it should still write something to the game's log file. The new message has more information about the nature of the problem.
EnotikSergo 6 Sep, 2022 @ 12:46pm 
I now have the same problem
[19:33:48.213] [Main Thread/ERROR] [Radiance]: GetWingStats error encountered, falling back on alternate implementation... WingID: 66 Original Exception: System.NullReferenceException: Object reference not set to an instance of an object. at Terraria.Player.TryGetModPlayer[T](T baseInstance, T& result) in tModLoader\Terraria\Player.TML.cs:line 52 at Radiance.PlayerTweaks.GetWingStats(orig_GetWingStats orig, Player self, Int32 wingID) in Radiance\PlayerTweaks.cs:line 189 [19:33:48.214] [Main Thread/WARN] [tML]: Silently Caught Exception: System.NullReferenceException: Object reference not set to an instance of an object. at Terraria.Collision.StepConveyorBelt(Entity entity, Single gravDir) in tModLoader\Terraria\Collision.cs:line 2755 at DMD<Terraria.Player::Update>(Player this, Int32 i) at Terraria.Main.DoUpdateInWorld(Stopwatch sw) at Terraria.Main.DoUpdate(GameTime& gameTime) at Terraria.Main.Update(GameTime gameTime) at Terraria.Main.DedServ_PostModLoad(Boolean& reloadMods) at Terraria.Main.DedServ() at Terraria.Program.LaunchGame_(Boolean isServer) at Terraria.Program.LaunchGame(String[] args, Boolean monoArgs) at MonoLaunch.<>c__DisplayClass1_0.<Main>b__0() at MonoLaunch.Main(String[] args)
Stellar  [developer] 10 Sep, 2022 @ 5:38pm 
I reimplemented the behavior in a way that doesn't use the GetWingStats hook (which was the main source of the problem).

Hopefully it works now.
< >
Showing 1-5 of 5 comments
Per page: 1530 50