How do I use xbox360 controller in game???

Get help using Construct 2

Post » Fri Mar 27, 2015 4:36 pm

Hello to all

I have buy a xbox 360 joystick working on pc.

but in my game how to tell to the app, when i push DOWN the object move down, i have added "d-pad down is down" object move to...
But nothing happens :s
B
32
S
12
G
6
Posts: 1,625
Reputation: 8,575

Post » Fri Mar 27, 2015 4:57 pm

Maybe try pressing A or another button before using the d-pad ?
Are you selecting the right pad number (0 if you have only one pad plugged in) in your condition ?
B
12
S
7
G
7
Posts: 448
Reputation: 4,272

Post » Fri Mar 27, 2015 5:45 pm

well actually the d-pad work, but how to tell to my app to simulate one of the buttons when the layer start?
B
32
S
12
G
6
Posts: 1,625
Reputation: 8,575

Post » Fri Mar 27, 2015 6:57 pm

You can declare a variable "down" set to 0

And then :

Gamepad : Gamepad 0 D-pad down is down
--> set variable down to 1
else
--> set variable down to 0

On layout start :
--> set variable down to 1

Variable down == 1
--> (your actions)


I could me more precise if you tell me what pressing the down button is supposed to do :)
B
12
S
7
G
7
Posts: 448
Reputation: 4,272

Post » Fri Mar 27, 2015 7:22 pm

down and up just move the cursor on the game menu
B
32
S
12
G
6
Posts: 1,625
Reputation: 8,575

Post » Fri Mar 27, 2015 7:26 pm

actually my menu works, when i push up and down, the cursor move on the selected menu, BUt when i start the layer i can do nothing, the actions works only if i push a button like x,y,b,a and AFTER THAT ONLY the actions of my layer work thats wierd

This is why i need to "simulate" a pushed button when the layer start.
B
32
S
12
G
6
Posts: 1,625
Reputation: 8,575

Post » Fri Mar 27, 2015 8:39 pm

Can you provide a capx ?
B
12
S
7
G
7
Posts: 448
Reputation: 4,272

Post » Sat Mar 28, 2015 8:35 pm

solved, i added another layer where the player has to push any button, then the game title and menu game start
B
32
S
12
G
6
Posts: 1,625
Reputation: 8,575


Return to How do I....?

Who is online

Users browsing this forum: LukeW, oddreal and 4 guests