sy-records / Game Ddz
Licence: apache-2.0
♦️ 使用Hyperf框架开发斗地主游戏
Stars: ✭ 116
Projects that are alternatives of or similar to Game Ddz
Lba2remake
A Little Big Adventure 2 / Twinsen's Odyssey reimplementation in JavaScript / Three.js / React
Stars: ✭ 116 (+0%)
Mutual labels: game
Powerup Android
PowerUp is an educational choose-your-own-adventure game that utilizes a users uploaded curriculum to empower pre-adolescents to take charge of their reproductive health. This is the Android version of the game.
Stars: ✭ 114 (-1.72%)
Mutual labels: game
Jokenpo
Can a neural network predict your next move on a game of rock, paper and scissor?
Stars: ✭ 112 (-3.45%)
Mutual labels: game
Awk Raycaster
Pseudo-3D shooter written completely in gawk using raycasting technique
Stars: ✭ 1,534 (+1222.41%)
Mutual labels: game
Mmo Server
Distributed Java game server, including login, gateway, game demo
Stars: ✭ 114 (-1.72%)
Mutual labels: game
Trw
The Royal Wedding – coffebreak roguelike with story, lighting, zombies and (sometimes) lutefisk!
Stars: ✭ 113 (-2.59%)
Mutual labels: game
Sleeping Beauty
Sleeping Beauty: a game created for the 7-day Roguelike 2014 challenge. Coffeebreak length.
Stars: ✭ 115 (-0.86%)
Mutual labels: game
Swoole Tadpole
tadpole chatroom (maybe spermium) powered by swoole and slim framework
Stars: ✭ 116 (+0%)
Mutual labels: swoole
Caveexpress
CaveExpress is a classic 2D platformer with physics-based gameplay and dozens of levels. CavePacker is a Sokoban game.
Stars: ✭ 111 (-4.31%)
Mutual labels: game
Owl Bt
owl-bt is editor for Behavior trees. It has been inspired by Unreal engine behavior trees in a way, that it supports special node items like decorators and services. This makes trees smaller and much more readable.
Stars: ✭ 112 (-3.45%)
Mutual labels: game
Hmiyc
Hunt Me If You Can is an UnrealEngine4 Battle Lan Game
Stars: ✭ 114 (-1.72%)
Mutual labels: game
Scala Game Library
Scala library for cross-platform 2D game development
Stars: ✭ 116 (+0%)
Mutual labels: game
斗地主
♦️ 基于Hyperf框架开发斗地主游戏,实现斗地主游戏服务端逻辑,并采用原生js和WebSocket实现简单的客户端打牌逻辑,可以做到简单的玩斗地主游戏。
特性
- 实现前后端二进制封包解包,采用的是msgpack扩展,msgpack对数据进行了压缩,并实现粘包处理;
- 数据采用固定包头,包头4个字节存包体长度,包体前2个字节分别为
cmd
(主命令字),scmd
(子命令字),后面为包体内容 - 采用策略模式解耦游戏中的每个协议逻辑
- 实现定义游戏开发
cmd
(主命令字)和scmd
(子命令字)定义,cmd和scmd主要用来路由到游戏协议逻辑处理
依赖
- 运行 Hyperf 的环境
- msgpack 扩展
安装
git clone https://github.com/sy-records/game-ddz.git
cd game-ddz
composer install --no-dev
php bin/hyperf.php start
安装完成后访问 URL:http://127.0.0.1:9501
使用示例
登陆
请随意输入英文或数字账号,这里是将用户账号当做uid
使用,存入redis
当中
打牌
根据按钮来操作打牌逻辑,消息框里会提示打牌逻辑过程
写在最后
此repo示例修改自swoft-ddz,已和原作者联系。
Note that the project description data, including the texts, logos, images, and/or trademarks,
for each open source project belongs to its rightful owner.
If you wish to add or remove any projects, please contact us at [email protected].