tModLoader / tModLoader

A mod to make and play Terraria mods. Supports Terraria 1.4 (and earlier) installations
https://www.tmodloader.net/
MIT License
4.11k stars 1.85k forks source link

Game crashes when drawing a mod's player layer, even though the code for the layer doesn't exist #3608

Closed Setnour6 closed 10 months ago

Setnour6 commented 1 year ago

Version

Latest 1.4.4-preview

OS

Windows

Platform

Steam

This bug affects

Mod capability as a Modder

Description

the game tries to draw a player layer that doesn't actually exist in the mod's source, which failed when it existed, but removing the player layer code still causes the player layer drawing issue. For context, I was trying to make changes to the player's skin/body color when they had a buff.

image

After I remove the failed PlayerLayer, the game still detects it, despite it being removed from the mod source code.

Log File

client.log

Steps to reproduce

  1. Add a Player Layer in your mod that compiles and loads in Terraria.
  2. Build your mod (you may have to go to the mod sources in tModLoader).
  3. Open tModLoader.
  4. Click on "singleplayer".
  5. Before the player list loads, the game crashes.
  6. Remove the player layer code completely from your mod.
  7. Build your mod.
  8. Reopen tModLoader.
  9. Click on "singleplayer".
  10. The game crashes, and shows a line that contains the keyword "PlayerLayer" in the error message.
  11. Check the client log for more info if needed.

Expected Behavior

The PlayerLayer should not be detected, nor load, since it doesn't exist anymore.

Actual Behavior

The PlayerLayer is detected and cannot load, despite not existing anymore.

Reproduction frequency

100% of the time

Additional Information

Restarting the computer and verifying file integrity does not fix the issue.

JavidPack commented 1 year ago

Did you figure this out? My guess is you had a ModName.dll in your mod sources folder and that was being re-used when building the mod.

JavidPack commented 10 months ago

This issue has either no recent activity or no reproducible steps, so it is being closed. We assume this issue has solved itself in some manner. Feel free to open a new issue if the issue persists and fill out the issue template completely.