Giter Site home page Giter Site logo

caohuilin / snake_react_v2 Goto Github PK

View Code? Open in Web Editor NEW
31.0 3.0 1.0 1.08 MB

React-Redux-Typescript-Immutable实现贪吃蛇小游戏

Home Page: https://caohuilin.github.io/Snake_React_v2/

JavaScript 24.17% TypeScript 54.55% CSS 18.48% HTML 2.79%
game react snake-game typescript redux immutablejs

snake_react_v2's Introduction

贪吃蛇小游戏(第二版)

home

2015年,React诞生不久,想着它组件的生命周期管理可以用来写小游戏,于是贪吃蛇小游戏V1版本诞生了 https://github.com/caohuilin/Snake_React ,现在还记得当时完成的兴奋和喜悦。

后来,学习了Redux, Immutable,一直想重新写一下这个项目。 苦于一直忙于工作,没有空。 近期终于有空更新项目,于是V2就来了 https://caohuilin.github.io/Snake_React_v2

概述

React生态圈技术实现网页版贪吃蛇小游戏。模拟游戏机界面,传统的游戏模式,找回小时候的回忆!

游戏规则

贪吃蛇大家都不陌生了,吃掉一个食物,蛇的身体会变长,食物随机出现在屏幕的另一个位置。碰到自己或者碰到墙壁游戏结束。 注意一点就是设置目前只支持游戏模式的设置。 点击设置按钮后,点击左键或者右键进行模式切换。

项目安装部署

Install

yarn install

Start Serve

It's served in http://localhost:3000 .

yarn run serve

Build

yarn run build

试玩

https://caohuilin.github.io/Snake_React_v2

game

补充

基本功能已经实现,难免有处理不当或者没有考虑到的界限问题,欢迎提Issue,https://github.com/caohuilin/Snake_React_v2 祝大家玩的愉快!

snake_react_v2's People

Contributors

caohuilin avatar wangkechun 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

Watchers

 avatar  avatar  avatar

Forkers

yasiwang0315

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.