Crafty is a Javascript-based HTML5 game engine. http://craftyjs.com/

learn more… | top users | synonyms

0
votes
1answer
598 views

Loading tile maps from files on the fly in Crafty JS

I'm fairly new to Crafty and have been having problems loading large world maps. So i have a world split up into multiple js files. They are represented by two arrays of tiles: one for background ...
0
votes
1answer
146 views

Rotate 2d sprite towards pointer

I'm using Crafty.js and am trying to point a sprite towards the mouse pointer. I have a function for getting the degree between two points and I'm pretty sure it works mathematically (I have it under ...
1
vote
2answers
259 views

Optimize DOM game performance

I am working on a game developed on DOM using Crafty JS framework, and Greensock GSAP JS (http://www.greensock.com/gsap-js/) for animations. It is my first time working with these technologies. I ...
0
votes
1answer
141 views

Play .mp3 with Craftyjs

I want to play .mp3 sound files in a game I built with Crafty.js. Is this possible without converting the sound file?
-3
votes
1answer
113 views

How do I detect when one sprite is moving away from another? [closed]

I'm currently working with crafty.js. I need to know how to detect when one sprite is moving away from another sprite.
2
votes
2answers
130 views

Gameover scene transition [duplicate]

I created a gameover scene in a crafty.js project but it does not run. Crafty.scene('gameover', function() { Crafty.background("#ccc"); Crafty.audio.stop("bg"); }); var gameOver = ...
2
votes
1answer
116 views

Stop music in crafty.js

How do I stop a looping music file from playing in crafty.js? I want the music to stop playing once a gameover condition has been reached.
0
votes
1answer
522 views

How do I make an entity move once per second in crafty.js

I am trying to implement "Snake" using crafty.js but I can't seem to get the snake entity to move just once in a second. How do I do this?