Move object with xbox 360 controller

For questions about using Classic.

Post » Tue Jun 19, 2012 9:19 pm

Hi,
I'm making a platform game. I'll add to my multiplayer game that is played on the same computer. The problem is that when I add the controls for player 2 to the list of controls, I can not put the controls of a game-xbox360 pad. I also added the object "Xbox360 Controller" ... Help me please!
B
3
Posts: 36
Reputation: 347

Post » Wed Jun 20, 2012 2:08 pm

Please, Help!
B
3
Posts: 36
Reputation: 347

Post » Wed Jun 20, 2012 3:41 pm

Can you show us a cap file of what you're trying to do?

Edit: Ah, I think I see what you're trying. Unfortunately you will need to use events to control the behaviors with an Xbox 360 controller.

Can you tell me which behavior you are trying to control? I will then try to make a cap file example for you.Jayjay2012-06-20 15:43:07
"Construct 4 lets YOU make advanced games! (maybe)" Construct Classic - Examples Kit
B
86
S
28
G
13
Posts: 2,092
Reputation: 15,009

Post » Wed Jun 20, 2012 4:51 pm

Currently I can not upload an example of what I'm trying to do, but will try to explain it to you:

I have a layout with the object "Xbox360 Controller" in place, and what I'm trying to make is that when the player press a button of the Xbox 360 Controller (This I will do so by events) the sprite "Player 2" forward for example a pixel . Do you understand me?
B
3
Posts: 36
Reputation: 347

Post » Wed Jun 20, 2012 6:06 pm

Ah yes, that's quite easy. I thought you were suggesting that the controller affects the objects built-in behavior, but pixel movements are not a problem!

Important thing to remember is that Player 2 is being controlled by Controller 1 if the first player uses a keyboard and mouse.

Would you like me to post an example of moving with a 360 controller?
"Construct 4 lets YOU make advanced games! (maybe)" Construct Classic - Examples Kit
B
86
S
28
G
13
Posts: 2,092
Reputation: 15,009

Post » Wed Jun 20, 2012 6:10 pm

I would not, I would love :) This much I need to finish the co-op of my game, please make an example.

And you know how to add gravity as if the platform Behavior?
B
3
Posts: 36
Reputation: 347

Post » Wed Jun 20, 2012 6:41 pm

Sure thing =] Here's files I made for 360 movement a while ago:

360 Control Type1

360 Control Type2

As for gravity you can do this:

Always:
-> Object.Y = Object.Y + (9.8 * 1000 * timedelta)

9.8 to represent something like Earth's gravity, and 1000*timedelta is to keep it at a constant speed regardless of the computer it runs on.Jayjay2012-06-20 18:41:16
"Construct 4 lets YOU make advanced games! (maybe)" Construct Classic - Examples Kit
B
86
S
28
G
13
Posts: 2,092
Reputation: 15,009

Post » Wed Jun 20, 2012 7:04 pm

And gravity could not be done by adding a behavior to the object? = S
B
3
Posts: 36
Reputation: 347

Post » Wed Jun 20, 2012 7:07 pm

@Jayjay

Is the 360 controller the only one Construct can handle?

Will a PS1/2/3 or other controllers work or will they require a special plugin of their own to be functional?
B
8
S
2
Posts: 40
Reputation: 2,136

Post » Wed Jun 20, 2012 7:25 pm

@adriel0000 No, it'd be in events under "Always" from the System object you put an action for the "Object to Set Y" position.

@aznmonkeyboy Kinda, you can use x360ce to emulate an Xbox 360 controller with other kinds, get that here.

Just download the ini and dll for it and you can place that in the folder of any game requiring Xbox360 controllers to use your own =]
"Construct 4 lets YOU make advanced games! (maybe)" Construct Classic - Examples Kit
B
86
S
28
G
13
Posts: 2,092
Reputation: 15,009

Next

Return to Help & Support using Construct Classic

Who is online

Users browsing this forum: No registered users and 2 guests