Code Monkey home page Code Monkey logo

endless-runner-html5-game's Introduction

Well hello there! I'm Steven Lambert, a Tech Lead, People Manager, and Accessibility Specialist. I specialize in design systems, performance, accessibility, and front-end architecture. I also enjoy making accessible HTML5 games, and giving back to the community through open source projects.

Below is a list of some of the open source projects and games I work on:

endless-runner-html5-game's People

Contributors

ashishsiot avatar straker avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

endless-runner-html5-game's Issues

Live Demo

can you add live demo link in to readme.md
-thank you

Mobile device compatibility

Hi, do you have any idea on how to make this game works on mobile device? I found out that the action was attached specifically to the space bar key code which doesn't work on mobile device. The codes below is what I used now but it doesn't work smoothly, when the player jumps there is a bit of lag.
canvas.addEventListener('touchstart', function(e) {
KEY_STATUS[KEY_CODES[32]] = true;
e.preventDefault();
}, false);

canvas.addEventListener('touchend', function(e) {
KEY_STATUS[KEY_CODES[32]] = false;
e.preventDefault();
}, false);

Enemy hitting player

Hi, below is the code I use to spawn enemy.

enemies.push(new Sprite(
canvas.width + platformWidth % player.speed,
500,
'slime'
));

However, the dimension of the picture is 55x136. I think once the height was changed, this condition player.minDist(enemies[i]) <= player.width - platformWidth/2 cannot be used to determine if the enemy is hitting the player already. Do you have any idea on how to have a new condition checker to cater for this scenario?

Thanks a lot.

Flicker issue

Hi, I changed the updateEnemies function a little bit by removing the gameOver() function if the player collides with enemy and replace it with splice function. However I noticed when the enemy that collides with the player gets removed, the other enemies nearby will have the flicker effect. any idea how to solve this? Thanks.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.