Custom controls

Discussion and feedback on Construct 2

Post » Fri Oct 28, 2011 2:50 am

Will the keyboard object eventually allow for custom input or will that, as tradition in MMF/Construct, be something other developers have to make an extension for?

For instance, being able to use an expression instead of being specific like "enter pressed".alspal2011-10-28 02:51:30
B
150
S
75
G
20
Posts: 1,791
Reputation: 22,720

Post » Fri Oct 28, 2011 2:55 am

Do you mean custom controls for behaviors? You can already do that by setting 'default controls' to 'no' then using the 'simulate control' actions, either by different keys or e.g. touch input.
Scirra Founder
B
398
S
236
G
88
Posts: 24,441
Reputation: 194,681

Post » Fri Oct 28, 2011 4:40 am

That's handy didn't notice that. But what I mean is in regards to conditions, so that you can do "[variable] is down" condition.

So this way you could set custom controls (you can do something like this is almost every professional game), such as:
__

-Condition: Any key pressed.
-Action: set sprite variable to [key pressed]
__

-Condition: [variable] is down
-Action: do what everalspal2011-10-28 04:41:37
B
150
S
75
G
20
Posts: 1,791
Reputation: 22,720

Post » Fri Oct 28, 2011 5:02 am

I think what he means is an easy way for the player reassign a key during runtime, so you don't need to make an event for every key of the keyboard when the user wants to change it.

Maybe something like:

On any key pressed
> set variable.leftKey to (last key pressed)

On key (variable.leftKey) pressed
> move player to the left

Scirra Employee
B
153
S
53
G
17
Posts: 710
Reputation: 17,825

Post » Fri Oct 28, 2011 5:45 am

Maybe these plugins can help you.rexrainbow2011-10-28 05:46:31
B
108
S
26
G
272
Posts: 4,473
Reputation: 152,281


Return to Construct 2 General

Who is online

Users browsing this forum: mihirolover, Yahoo [Bot] and 11 guests