HTML5 Game Engines
eBook - ePub

HTML5 Game Engines

App Development and Distribution

  1. 216 pages
  2. English
  3. ePUB (mobile friendly)
  4. Available on iOS & Android
eBook - ePub

HTML5 Game Engines

App Development and Distribution

About this book

This book is an introduction to development with HTML5 game engines, an in-depth look at some popular engines, downloadable example projects for each engine, and techniques on how to package and distribute the final app to all the major platforms.

Trusted by 375,005 students

Access to over 1 million titles for a fair monthly price.

Study more efficiently using our study tools.

Part II
image

HTML5 Game Engines

Chapter 3
image

Crafty

3.1 Source Code

All of the source code and examples are available at the website http://HTML5GameEnginesBook.com/. All the code, graphics, and sound are licensed free for personal and commercial use (MIT and CC-BY-3.0). Crafty is dual licensed MIT or GPL.

3.2 Introduction

Crafty is an open-source JavaScript game library developed by Louis Stowasser [54]. It renders to either Canvas or DOM. Its emphasis is on being lightweight and easy to use. For that reason, it is a good candidate to rewrite the Pong game from the previous chapters.
In this chapter, not only do we rewrite Pong, we will introduce a few more HTML5 considerations and best practices that are more fitting to be discussed here than in Part I.

3.3 Crafty Pong

Our previous Pong game was completed in just a few hundred lines. This time around, we want to have audio and graphics. Our new game will be called Crafty Pong. When finished, Crafty Pong will have a similar line count as before, but it will support far more features. The code itself also will look completely different, as it will have essentially been rewritten from scratch. One problem with game engines is that they have their own way of doing things, which means very little code gets reused. Crafty is no exception. Therefore, it is important to find an engine that...

Table of contents

  1. Preliminaries
  2. Dedication
  3. Preface
  4. How to Use This Book
  5. About the Author
  6. Acknowledgments
  7. I HTML5 Game Development
  8. II HTML5 Game Engines
  9. III HTML5 App Distribution
  10. Tools Appendix
  11. Bibliography

Frequently asked questions

Yes, you can cancel anytime from the Subscription tab in your account settings on the Perlego website. Your subscription will stay active until the end of your current billing period. Learn how to cancel your subscription
No, books cannot be downloaded as external files, such as PDFs, for use outside of Perlego. However, you can download books within the Perlego app for offline reading on mobile or tablet. Learn how to download books offline
Perlego offers two plans: Essential and Complete
  • Essential is ideal for learners and professionals who enjoy exploring a wide range of subjects. Access the Essential Library with 800,000+ trusted titles and best-sellers across business, personal growth, and the humanities. Includes unlimited reading time and Standard Read Aloud voice.
  • Complete: Perfect for advanced learners and researchers needing full, unrestricted access. Unlock 1.4M+ books across hundreds of subjects, including academic and specialized titles. The Complete Plan also includes advanced features like Premium Read Aloud and Research Assistant.
Both plans are available with monthly, semester, or annual billing cycles.
We are an online textbook subscription service, where you can get access to an entire online library for less than the price of a single book per month. With over 1 million books across 990+ topics, we’ve got you covered! Learn about our mission
Look out for the read-aloud symbol on your next book to see if you can listen to it. The read-aloud tool reads text aloud for you, highlighting the text as it is being read. You can pause it, speed it up and slow it down. Learn more about Read Aloud
Yes! You can use the Perlego app on both iOS and Android devices to read anytime, anywhere — even offline. Perfect for commutes or when you’re on the go.
Please note we cannot support devices running on iOS 13 and Android 7 or earlier. Learn more about using the app
Yes, you can access HTML5 Game Engines by Dan Nagle in PDF and/or ePUB format, as well as other popular books in Computer Science & Programming Games. We have over one million books available in our catalogue for you to explore.