Memory Leak In getArmorModel
Tfarcenim opened this issue ยท 0 comments
Describe the bug
A new model is created every frame to render while the Jetpack is worn instead of reusing an existing one.
To Reproduce
Steps to reproduce the behavior:
Step 1: Equip jetpack
Step 2: watch as 100s of jetpack models are created every second
Expected behavior
Reusing an existing model
Screenshots / Scripts / Logs
Here is the problem code:
https://github.com/BlakeBr0/IronJetpacks/blob/1.16/src/main/java/com/blakebr0/ironjetpacks/item/JetpackItem.java#L196
Versions (please complete the following information):
- Minecraft: 1.16.2
- Forge: 33.0.20
- Cucumber: 4.1.1
- Iron Jetpacks: 4.1.0