[SOLV]Why does my character attack more than once?

Get help using Construct 2

Post » Fri Feb 14, 2014 1:25 pm

First of all here's a link to my game:

Game

If you attack the jugs most of the time more than one number will appear even if you only attack one jug. The first thing I thought was the problem is that I made a invisible hitbox for the sword that will appear twice: once when the sword is diagonal, and then again when it is horizontal(as soon as I wrote this I made it so the first hit box destroys before the second one appears and it didn't work).

Here's the project download so you can look at the events yourself:

Capx Download

Thanks for all the help in advance.

EDIT: The controls for the game are WASD and K for attacking!

EDIT 2: SOLVED! I made the event check for collisions every 0.1 seconds instead of it automaticaly checking the event every tick.tarik005552014-02-14 16:10:36
Banned User
B
6
S
3
Posts: 105
Reputation: 1,170

Post » Fri Feb 14, 2014 3:32 pm

I didn't download the cap, just played the game. It looks like you have a pickaxe and sword swinging in the first part of the animation. Is the pickaxe colliding with the jugs too?
B
101
S
32
G
11
Posts: 1,546
Reputation: 21,727

Post » Fri Feb 14, 2014 4:13 pm

I'd say you are getting two hits for the same swing. You need to add something to only allow a single hit per hero attack.
ImageImageImage
B
71
S
22
G
247
Posts: 3,756
Reputation: 137,558


Return to How do I....?

Who is online

Users browsing this forum: No registered users and 54 guests