Can Hype be used to make games? That was one of the primary objectives for A Book About Hype. Hype 4 introduced the Physics API — a way to leverage Matter.js inside your Hype projects. Yet, it’s next-level JavaScript. It’s tough on the brain. Most people use Hype because they don’t want to code. That’s why we haven’t seen too many games built by Hype. This week’s “Jump” template aims to change that. While there is programming involved, it’s not too terrible.
With few lines of code… OK, OK, OK… a few hundred lines of code… you can create a basic platformer. It’s reminiscent of Super Mario Bros or Sonic The Hedgehog.
I went a little nuts with the keyboard controls. There are four basic modes of movement —left, right, jump (up), and stop (down). You have your pick of keys…
- Left — A, 4 (number pad), left arrow
- Right — D, 6 (number pad), right arrow
- Jump — W, 8 (number pad), up arrow, spacebar
- Stop — S, 5 (number pad), down arrow
Is it perfect? HA HA… NO! This is just a proof-of-concept. There are some issues. But in general, this is a very good start. Hype has entered a new era. And if more people show an interest in making games with Hype, then Tumult can justify the work to improve game development features.
Meanwhile, you can download the Jump Template to see how it works. More details are in A Book About Hype.
The “Jump” template reminds me of Arch Fiery. There’s even wall jumping in the “Jump” template. I suppose I could apply the lessons learned from Arch Fiery to build a new platformer with Hype. That’s what “Son of Vojtek” is about. Although, I’m not sure wall jumping would work with a bear.