How to Learn Construct 3? Next Steps for Beginners

52

Index

Features on these Courses

Contributors

Stats

78,012 visits, 280,154 views

Tools

Translations

This tutorial hasn't been translated.

License

This tutorial is licensed under CC BY 4.0. Please refer to the license text if you wish to reuse, share or remix the content contained within this tutorial.

Published on 1 Mar, 2019.

Endless Runner

Endless Runner is a template that gives you the control of a character that runs and jumps over platforms.

The template displays what is called a horizontal scrolling. The background and platforms will move from right to left in an infinite way, platforms are created randomly, their width and height are random according to the values set in event 6.

Notice this action uses the expression Random().

Random(a,b) will return a random value between the number a and up to but not equal to b.

In this example, only a single number is given. a by default is equal to 0 and b here is 400 (or 180). The expression will return a number between 0 and 400 (but it cannot be 400).

The Block object is using the Bullet behavior for its movement. This behavior automatically moves the object it is applied to a given amount of pixels per second in the “Angle of motion” - this creates the scrolling effect.

Despite the title of the template, the character is not running in this game. Instead, it stays in position and the scenery around it moves.

The character is jumping however, in a vertical direction.

Since the scenery is moving around it, it provides the impression the character is jumping in a parabola, a curved trajectory when in reality it is simply jumping from bottom to top and falling back to the bottom.

The player needs to anticipate and have the character jump at a correct timing so that the landing of the jump will happen on a platform.

The player needs to press the jump key at the correct time.

This input of the player is handled by the Touch plugin OR the Keyboard plugin.

The Keyboard will allow you to determine if the player has pressed (pushed down and then released), is pressing, or has released a key of the keyboard on desktop computers.

Please note the virtual keyboard on a mobile device won’t trigger Keyboard plugin’s events.

The character is using the Platform behavior and the platforms named “Block” have the Solid behavior.

The object having the Platform behavior will be “pushed away” from an object having the Solid behavior, and this is how the block behaves like a floor for the character to walk on.

The death condition is when the character falls in the space between two different platforms.

The game is reset right away and the player starts again with a score of 0 at the original setting.

  • 17 Comments

  • Order by
Want to leave a comment? Login or Register an account!