Anyone use Crafty or HTML 5?
Hey everyone! I’m working on my first real game called Binge! and it’s almost finished. I’m just trying to work out a few bugs and I could use a little help with understanding how the browser handles resources with the Crafty engine. I use faucets and pipes to shoot streams of water around the screen that create barriers that block the avatar. The avatar is supposed to solve puzzles to get around them. It works great with just one or two faucets in a level. However, if I have more than a few of these faucets on the screen everything starts to really slow down. This causes the water droplets to spawn unevenly, with lots of space between some of them that the avatar can just walk right though.
Any advice on what is causing the slow down (too many things to draw on screen? too much memory used? too many entities trying to create simultaneously?)
The faucet entities call a component that has a timeout function that calls itself every 100 ms. The timeout function creates a water droplet entity that switches directions when it hits a pipe, and destroys itself when it goes off screen. The water droplet entity has a component that blocks the avatar from passing through it. Any better way to do this?
Thanks!
