Shoot fullauto

Get help using Construct 2

Post » Mon Jan 21, 2013 4:15 pm

How do I repeat events while holding down a mousebutton?

I want my rifle to shoot fullauto when holding Mouse1.
B
4
Posts: 11
Reputation: 438

Post » Mon Jan 21, 2013 4:18 pm

mouse -> Mouse Button is down..

You may want to setup some timer to delay the bullets firing by a small fraction.
B
15
S
5
G
7
Posts: 877
Reputation: 5,650

Post » Mon Jan 21, 2013 4:22 pm

[QUOTE=procrastinator] mouse -> Mouse Button is down..

You may want to setup some timer to delay the bullets firing by a small fraction.[/QUOTE]

amazing.

ty
B
4
Posts: 11
Reputation: 438

Post » Mon Jan 21, 2013 4:36 pm

Well that caused some bug or something because now when I move with the 8 directional movement the bullets go flying in those directions instead of where my mouse and character is pointed.

Any way to fix that?

Or is there any other way to loop an event?anetherus2013-01-21 16:48:17
B
4
Posts: 11
Reputation: 438

Post » Mon Jan 21, 2013 4:41 pm

Posting a capx would be useful, it's really hard to see what you are doing with just written descriptions.
B
24
S
8
G
7
Posts: 756
Reputation: 7,192

Post » Mon Jan 21, 2013 4:48 pm

[QUOTE=vee41] Posting a capx would be useful, it's really hard to see what you are doing with just written descriptions.[/QUOTE]

Nvm.

I fixed it by moving the every tick > set angle towards mouse event to the top of the event list. Strange :D
B
4
Posts: 11
Reputation: 438

Post » Mon Jan 21, 2013 5:20 pm

- While LeftMouse Button is down
- Every FireRate seconds
-> Create Bullet at wherever
-> Set angle towards Mouse.X, Mouse.Y
B
40
S
12
G
7
Posts: 603
Reputation: 7,656


Return to How do I....?

Who is online

Users browsing this forum: dieblume86, Kagubro and 2 guests