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

3
votes
2answers
488 views

Collision detection between draggable object and world objects?

I have a game I'm making in Javascript that will involve combining items by dragging and dropping them onto each other. Think Alchemy or similar. So far, so good, but I hit a snag while trying to ...
3
votes
2answers
410 views

Shadows in html5 canvas game

I'd like to ask for reference. I met an article about how to cast shadows in games. I'm using html5 canvas (currently without webgl) with javascript for my projects. The article mentioned above is ...
0
votes
2answers
33 views

Updating code to include states

The Problem I am having a problem in that I am finding it hard to understand how to update my current code so that it uses states. I am creating a game, the game has a menu, each page in the game ...
3
votes
1answer
99 views

Call a native mobile API in Construct 2?

It is possible to use mobile api features in a Construct 2 game (html 5 / js engine) ? I didn't find anything about that on the net, unlike anothers game frameworks like Corona Entreprise or Cocos2d....
2
votes
1answer
160 views

Centering camera on player div

I've been making a roguelike-style game in HTML5 without using canvas (only divs) with pure JS (fiddle!). I've been trying to enlarge the tile size (font size) while keeping the player centered within ...
1
vote
1answer
169 views

Drawing/adding shape objects with the mouse on html canvas

I've started with the canvas paint tutorial from link which worked fine with a few problems that can be fixed later. I've been checking a lot of posts on drawing shapes on the canvas but they all use ...
0
votes
1answer
50 views

Bouncing from any object after collision JavaScript

I'm trying to make a ball bounce off some obstacles after a bounding box + pixel by pixel collision. Somehow, sometimes the ball is not going in the direction it is supposed to be. If the ball is ...
0
votes
1answer
30 views

How add a PIXI container into a Phaser Game?

How add a PIXI container into a Phaser Game? I have a game made ONLY with PIXI. but now i would like to port it to a Phaser. All my game content happens inside a pixi container "screenContainer". ...
-1
votes
1answer
78 views

Test your Mobile App's Code

I am new to game development in HTML5, and I would like to know how I can test my code out to see what I made with an IDE or something. Thanks!
-1
votes
1answer
676 views

Framework to build scrollable map with item selection in JavaScript?

I need a mobile device to be able to scroll a large, static map image, and also be able to select PNG image "objects", like this: What would be the simplest method? HTML5, jQuery, Sencha Touch, or ...
-4
votes
1answer
1k views

Can I make a downloadable .exe app for my game if I make it in HTML5?

I was going to make a MMORPG in HTML5 and javascript but I think I'm going to make a singelplayer first after all.. It would be nice to make the game in html5 anyway so the transition to making an ...
3
votes
0answers
65 views

Check if a point is touching a user drawn curve in HTML5 canvas

I am having trouble detecting whether a ball is colliding with a red curve. The curve below is an example of what a user may draw on to the canvas. I can't think of any fast ways to detect collision ...
3
votes
0answers
335 views

Card Masking in Phaser

Good Day, I'm new to Phaser and still learning about it to. I am challenging my self to create a simple animation of a card flip somewhat realistic rather that making use of a scale. This is ...
2
votes
0answers
89 views

tilting image for mode7 game in HTML5

I'm making a mode7 game like mario-kart and I need to tilt the image before I draw it, I have tried using a buffer canvas to tilt the image then draw it on the games canvas but this makes it laggy (...
1
vote
0answers
74 views

Pixel by pixel collision detection pinball

I'm currently working on a Pinball game using the HTML5 Canvas and JavaScript. Right now I'm getting a hard time with the pixel by pixel collision, which is fundamental because of the flippers. Right ...
1
vote
0answers
17 views

Using GLFX.js on a full HTML page

I have a friend who is developing a game for HTML, and wants me to implement GLFX into the site page. The problem is GLFX was designed specifically for use with the HTML5 Canvas, which he isn't using, ...
1
vote
0answers
188 views

touch mouseOver in createjs - DispatchEvent() not working in iPhone/iOS

I have recently developed an html5 game using createjs and I am currently in the testing phase. The game seems to work fine in all the devices except for the iPhone. After careful analysis I have come ...
1
vote
0answers
30 views

CocoonJS draws shadow around tiles

I am using CocoonJS launcher on iOS for a simple tiled game. Calling canvas drawImage for tiles adds a shadow or ghost border around tiles. See this screenshot: http://martindrapeau.github.io/cocoon-...
1
vote
0answers
151 views

Balancing fight script in Text Based Javascript Game

I'm working on a little text based javascript game and I've been using chromes Javascript console for the output. The 'game' works off a series of methods written into an object called Player created ...
1
vote
0answers
44 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 ...
1
vote
0answers
74 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 += this.bullets[i]....
1
vote
0answers
61 views

Improving performance on older Androids

I'm learning to build html5 games for mobile. I'm worried about the FPS animation on older model Android... as I use a lot of setTimeouts to update certain aspects and would like some suggestions on ...
1
vote
0answers
1k views

How to turn a 3d camera (in HTML5 2D Canvas)

A few years back I started experimenting with 3d in canvas. Everything went pretty well untill I had to to turn the camera, I couldn't get it done. A few days back I just happened to stumble upon ...
0
votes
0answers
22 views

Floor casting in a Raycasting engine

I'm trying to create a pseudo 3D, raycasting engine with plain JavaScript rendered on the HTML5 canvas. In short: a Wolfenstein 3D clone. So far I have gained inspiration from the following guides: ...
0
votes
0answers
35 views

Detecting collision of multiple moving objects

I have wrote a simple game that has a 100 balls bouncing off the borders of the canvas. Each ball is an instance of ball class function that has the following definition: var cnv = document....
0
votes
0answers
51 views

Collision detection not working for JavaScript Game

I'm working on a JavaScript game called Spacecraft which is minecraft 2d style. The problem is that my collision detection is not working. It works for a all the divs but the ones with the class of ...
0
votes
0answers
22 views

libGDX GWT compile with “-style DETAILED”

So basicly my libgdx HTML5-gradle build doesn't work. When switching from state it gives the following error: __gwt$exception: <skipped>: Cannot read property 'tM' of null Of course I want to ...
0
votes
0answers
20 views

HTML5 game - Difference in layouts in webview of app and webpage

I have created a working prototype of an HTML5 game and tried to convert it into an android app using PhoneGap. My issue is that the layout of the screen is bigger in case of the webview of the app. ...
0
votes
0answers
46 views

Errors in code examples from the book “Advanced Game Design with HTML5 and JavaScript”

I have purchased Advanced Game Design with HTML5 and JavaScript and have started going through the chapters. I notice that after chapter 2 I get code errors and the source code from the downloads ...
0
votes
0answers
40 views

Chrome Canvas bug on Mac OS X when switching spaces?

I have a simple Breakout clone created using the <canvas> element and the 2d context. Whilst playing the game in Google Chrome (version: 49.0.2623.87 (64-bit)) if I switch spaces within Mac OS ...
0
votes
0answers
71 views

UE4 -> HTML packaging not working

In the UE4 editor, if I try to package a project via File -> Package Project -> HTML5 option it creates the package, but doesn't work. A black screen shows up when I try to run the project's HTML file ...
0
votes
0answers
77 views

Unreal Engine - Why is the size of even the most minimal HTML5 project ~ 155 MB?

I created a new project in UE4 (ver 4.10.4) with "no starter content" and "scalable to 2D/3D" settings. Essentially, there are a total of 5 assets in the project 1) floor, 2) light source, 3) sky ...
0
votes
0answers
28 views

Adding rhythmic combat in Construct 2?

Just a simple question here: Is there any way to integrate counter-attacking, stun and punch rhythmic combat mechanics seen in the Batman: Arkham franchise and Shadow of Mordor? I know that Construct ...
0
votes
0answers
75 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
0answers
127 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 ...