Side Scroller Punching, shooting, damage, and AI

Get help using Construct 2

Post » Fri Aug 14, 2015 9:22 pm

Hello everyone i am making a side scrolling game but am wanting add punching, a sword, and a gun to the game, i already have the animations and buttons set and mapped, i just do not know how to set them so that they hurt the enemy, set how long before the next bullet can be fired, make an AI, set damage, make an AI attack. I know it sounds like a lot but if you think about it, it is not. All help is appreciated, and if anyone does not understand something ask and i will inform you, thanks in advance!
B
4
Posts: 12
Reputation: 224

Post » Fri Aug 14, 2015 11:06 pm

What have you already tried?
Image Image
B
26
S
15
G
143
Posts: 882
Reputation: 74,562

Post » Sat Aug 15, 2015 12:12 am

Nothing really... This is my first, detailed, side scroller
B
4
Posts: 12
Reputation: 224

Post » Sat Aug 15, 2015 12:14 am

To prevent attacking too fast I usually use the flash behaviour. So when the enemy is damaged they flash and you can't damage them while they're flashing.
B
3
Posts: 8
Reputation: 187

Post » Sat Aug 15, 2015 12:17 am

What I meant was keeping the player from shooting too fast
B
4
Posts: 12
Reputation: 224

Post » Sat Aug 15, 2015 12:19 am

You could make it so they can only shoot if a bullet does not exist.
B
3
Posts: 8
Reputation: 187

Post » Sat Aug 15, 2015 12:20 am

I think I know how but what exactly what I need to change/add to do that?
B
4
Posts: 12
Reputation: 224

Post » Sat Aug 15, 2015 12:23 am

MagicCookie wrote:I think I know how but what exactly what I need to change to do that?

If you mean my suggestion...
When you summon the bullet, change an instance variable. Of course first you need to add this.
Only do this when you summon a bullet from the player. Then you can test if a bullet with that value exists, If it doesn't, allow the user to shoot again.
B
3
Posts: 8
Reputation: 187

Post » Sat Aug 15, 2015 12:31 am

I'm new to this... What exactly do I need to change in instance variables and where at in the events ect. I know my way around, I just dont know how to use more complicated things like instance variables
B
4
Posts: 12
Reputation: 224

Post » Sat Aug 15, 2015 12:35 am

MadSpy wrote:What have you already tried?

Nothing yet... This is my first, detailed, side scroller
B
4
Posts: 12
Reputation: 224

Next

Return to How do I....?

Who is online

Users browsing this forum: No registered users and 25 guests