How do I make multiple bullet sprites shoot out the same gun

Get help using Construct 2

Post » Sat Jul 01, 2017 3:22 am

I need to have each bullet sprite shoot out the same gun on a power-up pick up
B
13
S
3
Posts: 13
Reputation: 753

Post » Sat Jul 01, 2017 4:47 am

Can you add some more information please?
B
45
S
15
G
73
Posts: 2,021
Reputation: 43,424

Post » Sat Jul 01, 2017 10:36 am

You can have a function called shoot, and on it copy paste the spawn bullet action like 3-5 times, this will make the gun to shot 3-5 bullet at once, you can also set them at different image points so it will look like shotgun.

Then you just need to restrict the function to be used only on power up pickup with a variable, lets say when you pick up the variable you set variable called power_up to 1, and then in the function add another condition power_up == 1.
Like my work? Fallow me on social media, and see my games on the arcade.
B
7
S
5
G
9
Posts: 298
Reputation: 5,357

Post » Sat Jul 01, 2017 12:13 pm

Just set the bullet sprite frames lets call frames (f)
On normal set bullet to shoot f0 on power up 1 set bullet spire to show f1
So voor every power up you have you can get a diffrent bullet
So on pick up power up
Set bullet frame to bullet you whant also you can edit the dmg and speed diffrent voor each power up pick up.
Its easy to do in your event sheet and also on your bullet sprite
Just first add all different bullets to your bullet sprite set them in the frame every frame 1 bullet
And write witch one is on witch frame then make 1event in your event sheet copy paste it So if you have on bullets so 9 bullets 9 events total and then edit the power up objects and the bullet frames and if you have dmg and speed settings you can edit them to and your done easy i think its faster done then writhing this poste 😀
Hope that helps you
i always whanted to make games and now i finally can
B
6
S
1
G
2
Posts: 22
Reputation: 1,401

Post » Tue Jul 04, 2017 7:59 am

you can watch my video on how i quickly got different bullets to shoot out of the same tank when the tank pick up a power up here
http://www.youtube.com/watch?v=AFWur1Jyr0E

for a beter and basic understanding of arrays watch jerementors video here
https://youtu.be/Us6aTgpreQ4
i always whanted to make games and now i finally can
B
6
S
1
G
2
Posts: 22
Reputation: 1,401

Post » Thu Jul 06, 2017 1:45 am

Thank you so much for the video. Now how would I make bullet 2 do -2 to enemy health and bullet 3 to do -3 to enemy health and so on and so fourth?

So how do I control each bullets Damage ?? A video or picture of an event sheet would be Great! Since I am new to this. Thanks Again
B
13
S
3
Posts: 13
Reputation: 753

Post » Thu Jul 06, 2017 5:09 am

spartan05 thank for your comment on my previus video.

here is a video on the second question.
lucky i still had the demo.capx on how to shoot different bullets.
so this was made fast xd
hope it helps you.
http://www.youtube.com/watch?v=Im9Z-ez8Wds
i always whanted to make games and now i finally can
B
6
S
1
G
2
Posts: 22
Reputation: 1,401


Return to How do I....?

Who is online

Users browsing this forum: imothep85, KTML5 and 9 guests