[Plugin] Object Pool Component

Sadly, even with that behavior doesn’t change.

Is there a chance that PooledProjectile doesn’t use Chaos properly or at all ?

All it does is spawn a new projectile component at runtime, because Epic’s code only works for newly spawned projectile.

I was just testing and I can’t see bullets not moving on my end. I just don’t enable gravity on the physics settings then it’s fine.

Nope, not working no matter what I do. It spawn, but doesn’t fly anywhere.

Can you please put together a super simple sample project with pooled projectile for UE 5.2 ? I’d like to replicate your setup, build it locally and test it on both PC and Android. Unfortunately, right now it simply sounds like one of those “works on my PC” conversations.



1 Like

Issues with particles, doesnt fire off.

Should the “auto activate” be checked on particle emitters within a pooled actor?

I have tried to activate the particle on begin pool play and deactivate on pool end, but nothing happenes.

Also, when updating plugin version, should i recreate all pooled actors again or can i count on it working as its supposed to ?

I probably should expose an option to avoid disabling particle components when return to pool.

Your particle systems probably are set to self destroy when they are deactivated.

Ah, man i feel stupid. Basically, what im doing only executes within a frame… ofcs i cant see the particle or the static mesh within that time… My bad bro.

Hi, got a weird thing happening while tracing for pooled pawns…

Im using a sphere trace to deal damage to all pawns within the sphere. Sometimes weirdly enough damage is dealt to targets outside the trace, they can be very far away from it.
I have tried to add GUID to each pooled pawn and sent it as a parameter, still same issue. I have also tried a interface to send damage info directly to the hit pawn but somehow some of the pawns seems to share the information.

Is this something you have encountered before and how to solve it?

EDIT: Seems like its an collision issue, somehow even if the sphere is not touching the pooled pawn it does have it within its hit info so it doesnt seem to be an pooling issue. I first thought it might have to do with memory issues due to pooling the pawns but seems like its an engine issue.

Seems like the culprit is the new orthographic camera, incase anyone else has the issue. A simple distance check solves my issue. Cant trust the hit information of the sphere collision.

1 Like

Strange no activity here for a while.
This plugin is very good, will it be updated to 5.4?

Marketplace update plugins manually.
When a new engine is released, they take some time to release the new plugins.
It’s currently waiting for their review.

1 Like

Hello,

I am getting (UE 4.27) the following errors on game close:
Unhandled Exception: EXCEPTION_ACCESS_VIOLATION reading address 0x00000000000002f8

UE4Editor_OBJPool_0001!UObjectPool::EndPlay() [F:\Temp\JF_BP_4_27_LOD\Plugins\ObjectPoolPlugin\Source\OBJPool\Private\OBJPool.cpp:38]

Anny suggestions on what could be the problem?

Kind regards

I will take a look. Thanks

Thanks, I have checked the functions in 4.27 and 5.2 and they are identical.

I’m uploading a fix for 5.3 and 5.4, but don’t have 5.2 installed right now.

I will test it on 5.2 next weekend (for legal reasons I can’t work on plugins on workdays since these are private projects of mine and not company’s property)

1 Like

This morning I downgraded 5.2 version (2.3.0) to UE 4.27. Compiled without any modifications, except uplugin file. I am testing it, hoping that that might do the trick since I had version 2.0.0. for UE 4.27. Also I analyzed the code and there were many valid checks in newer version.

I will use updated version when it is available.

Thank you and best regards!

Same thing happens in version 2.3.0.

Unhandled Exception: EXCEPTION_ACCESS_VIOLATION reading address 0x0000000000000310

UE4Editor_OBJPool!UObjectPool::EndPlay() [F:\Temp\JF_BP_4_27_LOD\Plugins\ObjectPoolPlugin\Source\OBJPool\Private\OBJPool.cpp:38]
UE4Editor_Engine!AActor::EndPlay() [D:\Build++UE4\Sync\Engine\Source\Runtime\Engine\Private\Actor.cpp:2299]
UE4Editor_Engine!AActor::RouteEndPlay() [D:\Build++UE4\Sync\Engine\Source\Runtime\Engine\Private\Actor.cpp:2263]
UE4Editor_UnrealEd!UEditorEngine::TeardownPlaySession() [D:\Build++UE4\Sync\Engine\Source\Editor\UnrealEd\Private\PlayLevel.cpp:737]
UE4Editor_UnrealEd!UEditorEngine::EndPlayMap() [D:\Build++UE4\Sync\Engine\Source\Editor\UnrealEd\Private\PlayLevel.cpp:297]
UE4Editor_UnrealEd!UEditorEngine::Tick() [D:\Build++UE4\Sync\Engine\Source\Editor\UnrealEd\Private\EditorEngine.cpp:2010]
UE4Editor_UnrealEd!UUnrealEdEngine::Tick() [D:\Build++UE4\Sync\Engine\Source\Editor\UnrealEd\Private\UnrealEdEngine.cpp:426]
UE4Editor!FEngineLoop::Tick() [D:\Build++UE4\Sync\Engine\Source\Runtime\Launch\Private\LaunchEngineLoop.cpp:4921]

1 Like

Epic did not release the fix yet.
It’s waiting for their manual release.

1 Like

The update with a fix for this is released to the marketplace, you should have a update notification on your launcher.

Hello, thank you. I got it yesterday night and I am testing all day. Compiled fine on WIN64 and Linux. Everything works great. I did about 50 runs over the level.

Thank you and keep on with the good work!

1 Like

I’m getting an unexpected behavior with some projectiles that have Niagara particles attached to them. These are very simple Blueprints with a Default Scene Root containing a capsule collider containing a Niagara system. On Pool Begin/End Play are used to initialize the particle system and activate it (with reset anebled) then deactivate it. The Tick event updates the capsule position of the projectile and I have basic collision detection with ActorBeginOverlap.

The pool contains 20 objects and is initialized like this when needed:

For the first few uses of the pooled actors, everything is fine. But I have different locations in the level where the objects can be spawned, so once the pool starts re-using actors, I start seeing traces of the particles as they apparently move from their last position (where On Pool End Play was called) to their new position (where On Pool Begin Play is called).

For example, the long, faint red lines throughout the scene should NOT be present!

I am activating the attached Niagara system in On Pool Begin Play and de-activating it in On Pool End Play, where I also reset the capsule position, since that’s what is being moved during tick updates (Reset Relative Transform). The Niagara system is set to solo mode and auto activate is disabled.

I’ve tried calling ReinitializeSystem and ResetSystem both from On Pool Begin Play and On Pool End Play with no effect. I’ve tried pausing and unpausing the system in the same places and even hiding and unhiding the system in the same places.

Any help would be appreciated!

Thanks,
-Rob