AI Characters Ragdoll behaves strangely after respawned. Proper respawn for characters?

finaratic

Member
So i have set up enemy zombie AI character. Everything works fine when i use just Instantiate, but if i pool this enemies after sometime their ragdolls on death starts behave strangely. For example it crushes to the ground with a lot more force than usual or enemy character "folds" down and it looks like from all the ragdoll colliders only few collides and the rest are not colliding.

So my question is what is the PROPER SET UP for respawning character using pooling? If you disable\enable the object without destroying it. I've seen character respawner script but i would preferably spawn them from game manager using pool and not this script.
 
If you are creating your own respawner you should base it off of CharacterRespawner. If you have created your own then you likely aren't executing the correct events which resets the object. Alternatively you can manage the CharacterRespawner from your own pooling script by manually calling Respawn. This is likely the cleanest method.
 
Okay, got it. So the thing here is JUST events right? Can you tell me which ones or compulsory when you respawn enemy?
 
Okie, thanks, i figured out there are only 2 events you should call before "reenabling" the character. I have game manager that gets Enemy from pool system that UCC provides and then i execute this events, so it should be good now i hope
 
Last edited:
Top