在线时间:8:00-16:00
迪恩网络APP
随时随地掌握行业动态
扫描二维码
关注迪恩网络微信公众号
开源软件名称:shaw3257/hive开源软件地址:https://github.com/shaw3257/hive开源编程语言:JavaScript 86.8%开源软件介绍:https://playhive.herokuapp.com/About HiveHive is a tabletop game designed by John Yianni and published in 2001 by Gen42 Games. It's a two player turn based game where the goal is to completely surround the opposing player's queen bee. Each game piece has different ways of moving around the hexagonal grid -- More information about these movements and game rules can be found here https://www.gen42.com/download/rules/hive/Hive_English_Rules.pdf. Developmenthttps://github.com/shaw3257/hive/blob/master/lib/board.jsGame Engine -The game engine is written in javascript with no 3rd party dependencies. It’s job is to keep game state and to emit events when moves are validated or processed. https://github.com/shaw3257/hive/blob/master/lib/ai.jsAI -The AI is also written in javascript with no 3rd party dependencies and is an implementation of the minimax algorithm with alpha beta pruning. It runs on the client-side in a separate thread via the Web Worker API. https://github.com/shaw3257/hive/blob/master/app/assets/javascripts/game/board/board-ui.jsUI -The UI uses the Canvas API along with Kinetic.js to render the pieces. The hexagonal grid was constructed with good ol’e fashion trigonometry. https://github.com/shaw3257/hive/blob/master/app/server.jsServer -The hive server runs on Node.js through Socket.io on the Express framework. The decision to use Node.js was to potentially use the game engine on the server-side. Develop LocallyInstall Depsnpm install Run Testsnpm test Compile and Watch Assetsgrunt && grunt watch Run Servernode app/server.js View in Browseropen http://localhost:3001 |
2023-10-27
2022-08-15
2022-08-17
2022-09-23
2022-08-13
请发表评论