OK i am working on a 3d bullet hell game and everything was going smoothly till i tried to get some info on how to program the boss and struggled to fined even a trace of helpfulness. Since I am fairly new to the BP I do not know where to start with programming something like this. The set up is that there is a stationary boss in the middle of the boss arena and i want the boss to fire projectiles spawning from himself and shooting outwards all over the room periodically, say every second. I already have a BP for DMG from objects so if the projectiles could be spheres or cubes something that i can attach a BP to that would be best. Please be very specific as i am new I do not know much of the terminology yet.
there are many ways to create the projectile like your talking about. in the simplest terms you need to use a for loop and a spawn actor from class node. basically the loop would run the script beyond it(the spawning) a certain number of times. the number of times its run is set by the index, this controls how many projectiles you want to spawn. then connect the loop body to the spawn actor from class node. youll need a separate actorbp for the projectile. set the class on the spawn node to your projectilebp. now comes the tricky part setting the location and rotation of the projectiles. theres two options, the first involves using vector math to create a algorithm, since you say your new ill assume this option is out. the second option involves placing components around your boss to act as markers for the spawn locations. in this way you manually place the components then reference them to get their location which you can then use for the location of the spawn. there is however one drawback to this method in that you can only spawn as many projectiles as you have spawn points for. the second option isnt as elegant but it should suffice until you up your skills.
Note: In the following pictures i used a timer to fire the projectiles at a regular interval
to make the bullets move randomly you would need to make your bullets into pawns and use something like the move to location or move to actor nodes. if you used a move to location you could pair it with a random point in nav radius node to get a random location within a specified radius of the bullet. there are many more ways to set the location to move towards but it all comes down to how complex you want to make the movement.
Thanks that helped a bunch. However is there a way once the projectiles have spawned to have them move sporadically. Thinking since the boss does the spawning and since the projectiles are actors and can have code would it be easier to put the moving randomly on them? IF so how can I set up that line of code. All of the resources I look at only do it for random enemy AI or for moving platforms using matinee.