HTML 5 refers to new web technologies such as high performance JavaScript engines, canvas 2D and WebGL, video and audio tags.

learn more… | top users | synonyms

0
votes
0answers
6 views

Crafty Bind “createView” to viewport - TiledMapBuilder

Is there any way to bind the createView function to the player entity? For Example: I am moving forward and the map is automatically loaded. I call the Map with: Crafty.e("2D, DOM, ...
-1
votes
0answers
36 views

What is the cheapest way to quickly and easily make a mobile-friendly HTML5 game? [on hold]

What is the cheapest way to quickly and easily make a mobile-friendly HTML5 game? It doesn't have to be terribly complex or original. Of course, I could find a contractor with relevant experience and ...
3
votes
1answer
48 views

CSS Sprite position updates slow due to addition of 'px'?

I'm moving fewer than 10 position: absolute elements around the screen. An enormous amount of CPU time (profiled in Chrome as (program) i.e. native code) is used where I do the following: style.left ...
0
votes
0answers
19 views

how to disable touch in Quintus?

hi i'm new in web games development and trying to build card game using the Quintus game engine i have object called card i can touch and drag it in the screen but i want just to touch and drag it one ...
0
votes
1answer
42 views

How to handle the different frame rate on different devices?

I am not quite sure how frame per second works on a web page. I have a Canvas game that involves in moving an image from point A to B, and measuring the time elapsed. The code can be as simple as: ...
0
votes
0answers
29 views

Drawing a object with Box2D and HTML5 canvas on current mouse position

I'm attempting to create a air hockey type game with HTML5 canvas and JavaScript, using Box2dWeb for the physics calculation. I need a way to draw the puck at the current mouse x and y position every ...
1
vote
0answers
27 views

Algorithms for positioning rectangles evenly spaced with unknown connecting lines

I'm new to game development, but I'm trying to figure out a good algorithm for positioning rectangles (of any width and height) in a given surface area, and connecting them with any variation of ...
0
votes
1answer
107 views

HTML5 Canvas 2D lighting and normal maps [closed]

How using the HTML5 Canvas can I create a 2D game with light sources and also add an extra depth using normal maps. I have never really done lighting in 2D before and I'm not sure where to start. ...
2
votes
1answer
36 views

Mouse input and structure in JS [closed]

I am creating a simple concept where I have a small menu to choose a tool from and then I can click and drag to build. For example, I click on the rails tool and then I can click and move the mouse ...
0
votes
1answer
40 views

animating a spritesheet using crafty.js

this is my jsfiddle : http://jsfiddle.net/seekpunk/ek6ub4u5/1/ i don't understand what i am missing it's been three days now working and trying to do the animation but i am stuck ...
0
votes
3answers
103 views

2D collisions between 2 arrays

I'm trying to do collision detection between bullets and enemies in my game. But it's very unpredictable and sometimes it works, sometimes it doesn't (bullet goes straight through without doing ...
0
votes
1answer
36 views

How to use setInterval and clearInterval

I have a game that I am making and cannot seem to get the setInterval and clearInterval methods to work. When I debug it in the browser console it shows that the method is still being called over and ...
0
votes
1answer
34 views

HTML5 - multiple animations, different fps

I want to create an html5 game which contains multiple sprites. For different elements I want to create an fixed fps. For example: Walk - 10 fps, so 10 sprites will be shown within 1 second Run - ...
-2
votes
1answer
40 views

HTML5 moving image, doesn't move [closed]

Why my image doesn't move? Can you help me ... <script> window.requestAnimFrame = (function(callback) { return window.requestAnimationFrame || window.webkitRequestAnimationFrame || ...
4
votes
4answers
329 views

Why do I need a local server for HTML5 game development?

I'm new to HTML5 game development. I'm trying to make something using Pixi.js, but when I tried to view it in a browser, I saw a blank page. According to the tutorial I'm following, I need to set up a ...
0
votes
1answer
59 views

Phaser/HTML5 - Trying to add five instances to a group and display on the screen!

just started using Phaser today after seeing Thomas Palef's lessmilk series. I completed PhotonStorm's "Make your first Phaser game" tutorial, and grabbed the skeleton, some CSS, and started to throw ...
0
votes
0answers
31 views

How do I repeat parts of some images in 2D Array in JavaScript but not all of them?

OK, I am trying to make a game that is a little bit like SimTower but utilizing HTML5 (particularly the canvas element) and JavaScript with a little CSS. I have progressed pretty far in the past week ...
0
votes
2answers
141 views

How to move an image back and forth with javascript

I currently am trying to make a baseball game and have this code here: http://jsfiddle.net/769BK/ I have the baseballX set to a decrement, and then I try increasing the value using baseballX++; but it ...
0
votes
1answer
314 views

Is HTML5/WebGL performance unreliable on low-end Android tablets and phones?

I've developed a couple of WebGL games, and am trying them out on Android. I found that they run very slowly on my tablet, however. For example, a game with 10 sprites or so runs as 5fps. I tried ...
2
votes
0answers
148 views

Any open source editor to make video games online without programming knowledge? [closed]

With Scratch we can create video games online, from its web platform, and publish them on the same web. I could download its source code and use it, as many others already did (see Scratch ...
0
votes
1answer
121 views

Is there a way to earn money from non-mobile HTML5 game? [closed]

I'm just a hobbyist, who has some ideas, that would not fit on a mobile screen. I have searched for some method, to make a bit of money from them, but I've found just for mobile-optimized games. So ...
0
votes
2answers
153 views

How to move an object using X and Y coordinates in JavaScript

I am making a 2d baseball game with JavaScript and HTML5 and am trying to move an image that I have drawn with JavaScript like so: //canvas var c = document.getElementById("gameCanvas"); ...
1
vote
1answer
154 views

html5 libgdx project: war to be deployed in a servlet container or only part of the contents to a web server

I am new to compiling games with libgdx to be played on the web and I have some doubts perhaps someone can point me in the right direction: Using the new gradle setup I wrote a simple game to learn ...
0
votes
1answer
81 views

Check legal movement on grid map

i'm trying to develop a simple multiplayer turn base game, i'm start creating the grid map, i have already write the javascript script to display the range movement for the specific unit, but my ...
0
votes
0answers
34 views

Box2d not showing consistent behaviour with sprites

Box2D newbb here. My question is in regards to this create js project:http://mboyeman.com/dashingdog/ (runs best in IE...:3) I wrote a function(assignBlockBodies) to give 2D Edges to sprites based on ...
-2
votes
1answer
61 views

How do I make other players see one player's die rolls? [closed]

I'm new to PHP and making a simple dice game. It works well in single-player, but in multi-player, I don't know how to show the results of one player's rand(1,6) dice roll to the others using a web ...
1
vote
1answer
180 views

Can't create “hero walking” animation

I'm creating a Fez-based HTML5 Canvas game and animating my hero image using sprite sheets. The problem is that I can't create the animation of the hero walking, don't matter how much I try, the ...
0
votes
0answers
52 views

EaselJS SpriteSheet isn't responding to gotoAndPlay

I'm developing a Fez-based HTML5 Canvas game using EaselJS and I've found a problem, that I can't solve myself, while trying to implement SpriteSheets to the hero. The problem is that I've defined ...
2
votes
2answers
89 views

How do I detect when an HTML 5 game has ended?

I'd like to embed HTML5 games in a website, but I need to be able to detect when the game has ended so I can run some of my own JavaScript. Looking at the output of some game engines (Construct 2, ...
-1
votes
1answer
90 views

creating an html5 game [closed]

I am working on a really simple online version of the parachute shooters game that was preprogrammed on old iPods. I'm pretty new to game development and so at first I tried to build the whole game ...
2
votes
0answers
32 views

Presentation / input layer that communicates with server [closed]

I want to learn more abot how to use some kind of presentation/input layer that communicates with server for HTML5 games. Instead of sending all the code to the clients browser, I would like to just ...
2
votes
1answer
80 views

How do I use createPattern with a spritesheet? [closed]

Say that I have a spritesheet like this And I want to use the dirt tile at (1, 1). I know that I can repeat an entire image using createPattern but how do I create the pattern from just the tile ...
2
votes
1answer
56 views

Forcing Non-Pitch Preserving Audio in HTML5, Construct 2

I'm working on a simple game built in HTML5 using Construct 2, in which a circle eats other circles; nothing fancy. The idea is that a song plays during the game, starting at a low pitch, and rising ...
-2
votes
2answers
112 views

collision detection algorithm issue

here is the jsfiddle i am working on so far : http://jsfiddle.net/TLYZS/ if you debug the code and check the collision function you can see that the collision is working fine when the user overlap ...
4
votes
1answer
752 views

How can I run a Phaser engine game without a window?

I'm currently creating a multiplayer game using the HTML5 framework Phaser. It's a game where zombies spawn on the map and players have to shoot them to kill them. The zombies target players that are ...
1
vote
1answer
238 views

Should game logic update per second or per frame?

I'm trying to wrap my head around how and when to update an entities position. My game loop updates logic at 25 FPS and renders at 50-60 (Depending on the computer hardware). So lets say I'm moving ...
1
vote
2answers
535 views

Dealing with multiple animation state in one sprite sheet image using html5 canvas

I am recently creating a Game using html5 canvas .The player have multiple state it can walk jump kick and push and multiple other states my question is simple but after some deep research i couldn't ...
0
votes
1answer
63 views

setting a time delay between two frame when animation a sprite sheet

this is my jsfiddle :http://jsfiddle.net/Z7a5h/ As you can see the animation of the sprite sheet when the player is not moving is too fast so i was trying to make it slow by declaring two variable ...
1
vote
0answers
40 views

Maintaining relative location of objects across different screen resolutions

I'm developing a very simple interactive HTML5 game, in which I need to show a room having multiple objects like cupboard, table, fan etc. How can I bind all of the objects together, so that they ...
0
votes
0answers
49 views

HTML5 Canvas: Get rect coords after rotation (relative to screen)

update: function(delta) { for (var i = 0; i < this.bullets.length; i++) { this.bullets[i].velocity = this.bullets[i].speed * delta; this.bullets[i].contextX += ...
3
votes
1answer
1k views

HTML5 - Dynamic canvas grid for scrolling a big map

I've been working on different scrolling algorithms for my JS-based game. My main problem is that I need to draw a huge map and also have it scroll smoothly. I've made a few attempts and while they're ...
0
votes
1answer
86 views

How do I add a canvas tag to my ocean id in javascript? [closed]

I'm trying to create a "wack-a-mole" type of game. I've gotten all of the lines of code except in one area. Here is all of the code: <!doctype html> <title>Squid Smash!</title> ...
0
votes
2answers
177 views

HTML5 Quintus button click doesn't work in local

If you try to run this example http://html5quintus.com/docs/ui.html, you'll be able to click the buttons, but you won't if you download a local copy of the example and click the index file (without ...
0
votes
1answer
298 views

Planet gravity? [duplicate]

I am trying to make a game with the Phaser game engine and would like to implement some sort of planetary gravity. Essentially I just want the player to be able to walk on a circle or orbit a point. I ...
6
votes
0answers
2k views

Poor performance in android when running APK, runs fine in browser

I have created a small game project in HTML5 using Phaser engine (tried both 1.1.5 and 1.1.6). Then to port it to mobile platform, used Phonegap/Cordova for Windows Phone 8, Android and iOS. In my ...
3
votes
2answers
312 views

HTML5 game fps render lag

I am currently creating a flappyBird-like HTML5 game using Proccessing.js You can see current work here: http://files.tips4design.com/flappySlothRelease/ The problem is that even though the FPS is ...
-2
votes
1answer
176 views

How should I start with Android development? I am basically a PHP HTML JAVASCRIPT developer [closed]

I am a PHP developer wanting to learn Android game programming. I tried java with ADT and android SDK, but I found Java confusing because of its complex Object-Oriented structure. I've heard we can ...
0
votes
2answers
75 views

JavaScript character direction delay [closed]

I am developing a top down game and I'm having trouble with a delay in switching from one character walk direction to another, particularly if the previous direction key is still being pressed by the ...
0
votes
1answer
191 views

How do I make a sprite blink on an HTML5 canvas?

I'm thinking of the flashing effect many games have when a character gets hit and takes damage. Something like overlaying a lighter color on visible sprite pixels for a second.
0
votes
0answers
69 views

Sound Effect Delay occurs when game is deployed with GWT backend?

I've been posting my games on to my personal website recently and I noticed a slight hiccups with the LibGDX games I've made. Within the first few seconds following the loading of the game, there is a ...