HTML5 Game Development
   
  • HOME
  • News
  • Tutorials
  • Engines
  • Demos
  • Tools
  • Partners
  • Mobile HTML Game
  • Wind And Solar
  • About us

Pong Game with SVG.js

We were recently introduced to SVG.js, a library for manipulating and animating SVG (Scalable Vector Graphics). The library boasts of having no dependencies and aims to be the leanest of its kind, doing the same things that Snap.svg and Raphael can do, but with half the amount of code.

To highlight some aspects of the  SVG.js library, its creators have given us a neat tutorial on how to make a Pong game within their framework. Look how short the code is for drawing two paddles with different colors:

Pong with SVGjs - coding the paddles

This version of the classic arcade game has some cool effects.

For example, the ball changes its color into that of the opponent while moving towards the other side.

Pong with SVGjs - color blast

Also, there is a huge color blast when the opponent fails to hit the ball back.

You can try the game yourself here.

Check out the tutorial here.

Share List

You might also find this interesting:


  1. HTML5 Game Development Facebook, Twitter and G+ The official HTML5GameDevelopment.org Facebook page up at: http://www.facebook.com/Html5GameDevelopment The official HTML5GameDevelopment.org Twitter account is at: https://twitter.com/#!/gamedevhtml5 The Google Plus page is up at: https://plus.google.com/b/106608051085232600929/ All are updated automatically via the...

  2. Atari Opens up Development Kit for HTML5 Atari Arcade Atari arcade, the Microsoft sponsored HTML5 re-imagining of Atari’s classic catalog, is opening up it’s development platform: Supported by Internet Explorer and Atari, the new Atari Arcade is a browser-based...

  3. CodePlayer Tutorial: Make a snake game using HTML5 and jQuery The folks over at TheCodePlayer.com have written an interactive coding tutorial that walks you through the code for making a snake-game in HTML5. The tutorial walks you through the code...

  4. Ascii Fluid Designer Nick Kwiatek posted a innovative combination of Fluid Dynamics and Ascii Art. Creative JS has some more notes. Share List...

  5. Funky Microsoft Sponsored Japanese SVG Animation A wacky SVG animation created to show off the SVG animation capabilities of IE9 (but works fine in Chrome as well) – cool, rescalable stuff Share List...

Pong, SVG, SVG.js
HTML5 Demos, HTML5 Game Dev Tutorials, HTML5 Tools

License HTML5 Games

Are you a company looking to license HTML5 games? We recommend MarketJS.com, a B2B platform for licensing games.

MarketJS has over 300 HTML5 games for licensing. They also provide additional services such as game reskin, custom development, and white label portals.

Html5 Game Development


Follow @GameDevHTML5



WHAT’S NEW

  • Unity’s Pricing Scheme Changes

  • Unity Game Engine Pricing Fee

  • Open-source 3D Game Engine with Sketchfab Integration

  • MODD.IO Updates – Improved No Coding Required Game Engine

  • GPT3 Voting Board



NEW DEMOS

  • New BabylonJS Feature Within Skybox

  • Creating a Mobile HTML5 RPG – Guidelines for Beginners

  • How to Use HTML5 Games To Engage Social Media Followers

  • Running HTML5 Games for Online Competitions

  • Vertical Platformer Games Using GDevelop


ENGINES

  • Unity’s Pricing Scheme Changes

    In an open letter to the Unity community, the company announced the details of its pricing scheme changes. In the letter, the Personal plan will remain free and there will …Read more

  • Unity Game Engine Pricing Fee

    Early in September 2023, Unity Technologies announced the Unity game engine pricing fee. Starting on 1 January 2024, the company will charge game developers a fee (2 tiers) for each …Read more

  • Open-source 3D Game Engine with Sketchfab Integration

    PlayCanvas, an open-source 3D game engine, has added Sketchfab integration into its latest updates. This improvement gives game developers access to Sketchfab’s high-quality 3D, AR, and VR content. To access …Read more

SEARCH OUR ARCHIVES

CONNECT

rss twitter

HTML5 Game Development is proudly run by 3P Solutions Inc

GOT NEWS?

Send new engines, demos, information and tips to hello@html5gamedevelopment.com

MONTHLY MEETUP

In boston? Join us for the Monthly HTML5 Game Development meetup.

BOOKS

We're in the process of writing a few books about game development. Coming soon!

Copyright HTML5gamedevelopment.com