hello guys i need help
i need to create a arc of bullets but i can never center the object correctly as you can see from the attached gif
i need to create a 3-4-5 arc and another 360° arc that hits in every direction
can someone help me please?
I know there is an advanced bullet extension but I would like not to use it
I suppose you could calculate the angle of the first bullet based on the total number of bullets to be fired and the angle of spread.
Say, if you’re firing 4 bullets at 20 degrees apart,
you multiply then divide by 2 to get the initial angle:
(4*20)/2 = 40
This result would still be offset so you
subtract half of the spread value. (20/2=10) *edit: i tend to miss this part. heh
40 -10=30
Then you subtract that from the target angle.
If your reference object is rotated towards, let’s say 10 degrees:
that would be 10 - 30 = -20
So there you have the initial angle for your first bullet.
You then add 20 for each succeeding bullet.
Hence:
Bullet1 = -20 ; bullet2 = 0 ; bullet3 = 20 ; bullet4 = 40
Although if the number of bullets and angle difference doesn’t vary too much, I kind of prefer to do this manually. Like if I want the object to shoot 5 bullets, I’d have an event which has 5 sub-events, one for each bullet where I’d manually assign their own angles. I admit it’s pretty crude though. But if it’s a lot more bullets, yeah, that’s the math I’d do above.
If you want to always shoot NOT EVEN number of bullets so 1 > 3 > 5 > 7 > 9
Instead of 1 > 2 > 3 > 4 > 5 > 6 > 7 > 8 > 9
Then change this to 2
Or you can go with static numbers if you want