I’ve working on my AI animations currently in UE5. I’ve just set up my enemies weapon firing including delay between shots, etc.
I’ve put 3 enemies on my test map, all of which have different weapons attached.
My enemies shoot at me fine, until one of them runs out of ammo and triggers the reload blueprint.
In my AnimBP I have it move over to the reload state once IsReloading inside my BP_EnemyBase is true. The problem I’m having is once 1 enemy starts reloading, they all start the reloading animation despite the other characters still having ammo in their guns.
I’ve tried child blueprints to the main one, and confirmed the Is Reloading variable is set to instance editable but I haven’t found a fix for 3 hours now. I’m not sure what setting or box I need to tick in order to have each animBP be unique to each enemy.
I really don’t ‘know’ the answer to this, but I’ll give you a guess to see if it helps…
The top right of your blueprint shows reloading and sets it to truem but further off the screen there is more blueprint that seems to be using the Enemy Weapon as a target. Are all the relevant variables set to instance editable, or is the target of the instance reload effecting all weapons because they are not instance editable?
Thanks for the reply, The Reload Bool is inside the Enemy Blueprint, all my weapons don’t have a variable for reloading… hmm Perhaps that could be the problem?
My reload bool for my player is in my player blueprint So I put it into my Enemy thinking I’d have the same result
I think it might be. The reload should probably be in the weapon, not the enemy, which would account for all enemies reloading at once. Maybe it could be done either way, but there is a vague answer here: Reload System that is probably worth trying to follow.
If you work with Blueprint Child for Enemies I think you don’t need put the “IsReloading” Variable as public, because the Child can acess the variable, because he have a Base Blueprint for that. I don’t know if this tip is work for you. Also make sure that Variable “IsReloading” is not set to true on each enemy added to the scene.
I’m not expert in Blueprint, but i try to help, check if this things works in yout project