Platform games with C3. How have things changed since the original tutorial?

0 favourites
  • 2 posts
From the Asset Store
Simplistic hyper-casual game with nature elements. Tap to switch between the 4 elements and reach a better score.
  • Hi,

    I'm teaching a small course on game design with a group of approximately 15 college undergraduates.

    Before they start creating their own platform games, I'm walking students through some of the basics by covering steps that were part of Ashley's original platform game tutorial back in 2012.

    Quite a bit has changed during the past seven years, so I'm curious to know if I should be tweaking a few things.

    Question #1. Should my students use 'system: every tick' or should they use the pin behavior to keep the collision box attached to the player sprite?

    Context: The original tutorial recommends creating a transparent playerBox to handle collisions. This is attached to the actual player sprite with a "system: every tick" event.

    I *think* it is just "six of one or half-dozen the other," but would be interested in knowing what others think.

    Question #2. Is there a better way of handling enemy movement?

    Context: The original tutorial recommends moving the enemies move by attaching the platform behavior to those enemies and disabling the platform controls. A boolean instance variable keeps track of enemy direction, and that variable is flipped whenever the enemy collides with an invisible edge barrier.

    This has *usually* worked, but -- every year for the past three years -- at least one of the fifteen students encounters an issue where the enemies don't collide properly with the edge barrier and end up falling to the bottom of the screen. We have looked over their code with a fine-toothed comb, scrutinized the debugger, and swapped in different sprites, but none of those solutions seemed to work.

    I'm wondering if the new timeline behaviors are now a preferred way of handling enemy movement. If you were creating a platform game with C3 in 2019, how would *you* handle enemy movement?

    Thanks for any suggestions!

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • The original tutorial recommends creating a transparent playerBox to handle collisions.

    It's still a preferred method. You can position Player sprite to playerBox on every tick, or pin it once on start of the layout. The only problem with Pin is that it updates player position at the end of the tick. So, for example, if you are using image points on Player sprite to spawn bullets or to attach weapons, with Pin there may be a small lagging effect.

    an issue where the enemies don't collide properly with the edge barrier and end up falling to the bottom of the screen

    This may happen if the enemy's collision polygon is not symmetrical (relatively to its Origin point), or if it has animation playing with different collision polygons. What happens in this case is the enemy collides with the barrier, turns, collides again and turns again.

    See this file demonstrating the issue:

    dropbox.com/s/ac9suehzb8pcowy/PlatformEnemies.c3p

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)