Hello. I am making powerful equipment system for my project and i have problem. Let me show you, because explanation of this… problem may take a lot of time.
Here is my scene:
Pay attention to chest and sword and other item on background. They are THERE. Now let me equip sword from my inventory to it’s slot. It is Static slot.
It is attached to the hand socket. When we equip item, it is equipped by Set Static Mesh bp function. Let’s equip it.
as we can see it is worked and everything is set.
Ok. Let me unequip it now.
And… All items that had static mesh slot just Removed from the scene at all. As you see there is no sword, no anything.
To unequip i use this code:
and you might say that this is because of my mistake, like multiple call for set static mesh function. But it is not. I am never used trace for objects. This different object do not have any common parts. Even static slot names on them are different.
I checked in debug mode how many times it will call Set Static mesh. And it does it once. as it should be.
For the test i made this simple code inside of my character BP:
And… how do you think… does my bug disappeared? NO. It is not. Here how looks my scene after pressing R.
No chest. No sword. All actors that had Static Mesh slot just reseted this slot. I don’t know why.
All my day i am trying to underestand what’s wrong. And now i certainly tell - this is unreal engine’s bug. I am using 2.25 version with latest update on it(2.25.1). I never seen bugs like this before.
Here is how my actors structure looks like.
Here is how my character looks like(part of it, there is more than 24 different slots)
No common parts, no global variables at all. No game instance class at all. (in future, if i will make loading screen, it will be, but not now)
No set static mesh loops. As i shown yoou before it resets all static meshes even by key press!
And that bug works even with other static mesh attachments. for example with static hair mesh attachment.
if i remove it from there this will happen:
It’s just Impossible!
Can anyone help me with this, please. Because… i have to use static mehs component attachment on my character. It’s impossible to continue development like that.