Is a custom melee enemy possible with the new NPC scripting?

I have figured out how to add my own mesh, and how to either bring in my own animations for movement or retarget from Fortnite characters, however I need a way to handle combat and I can’t see any way of dealing with that. I’ve tried using the guard type but will only attack with guns, so it’s not suitable for my needs.

The only functionality I can see is to just move the NPC around by giving it points to go to.

Is there more functionality I’m missing or this just not feasible with what we have currently?

3 Likes

I have look all over the internet and have not found anything. I have a degree in computer science it my thought process is that it should be do able since in BR they have the coin bosses right. I notice that none of them use melee weapons, right? The wolf boss uses animations to fight, I think. Must be Epic hasn’t made a guard or npc that can use melee weapons. My theory is that when they equip weapons it is very useless because it probably uses the script they have for long range guns so not very useful for guard. It would look like the guard is swinging at the air when you are meters away. So most likely Epic does not allow guards/npc to equip melee weapons.

I have been looking for this functionality as well.

You could make an NPC Character Definition that has mele weapons as part of the skeletal mesh’s animation FBX file. Basically, the sword the enemy is holding is an actual bone that is apart of the NPC’s body.

There is something called a socket that is meant to attach items and props to various bones on the mesh of an actor but it seems to be completely bugged. Your NPC will have mele weapons in there hands but when you play the map in Fortnite, the weapons will be stuck to the origin of the NPC instead of the socket locations.

See this post. It has more information about this kind of problem

Guards can use melee weapons, however they won’t attack without being provoked. You can force Guards to attack with ForceAttackTarget through the guard spawner.
image