mirror of
https://github.com/FlourishingWorld/hk4e.git
synced 2026-02-17 17:02:25 +08:00
网关客户端协议代理功能加入二级pb数据解析
This commit is contained in:
@@ -33,6 +33,10 @@ func (g *GameManager) AddUserWeapon(userId uint32, itemId uint32) uint64 {
|
||||
}
|
||||
weaponId := uint64(g.snowflake.GenId())
|
||||
dbWeapon := player.GetDbWeapon()
|
||||
// 校验背包武器容量
|
||||
if dbWeapon.GetWeaponMapLen() > constant.STORE_PACK_LIMIT_WEAPON {
|
||||
return 0
|
||||
}
|
||||
dbWeapon.AddWeapon(player, itemId, weaponId)
|
||||
weapon := dbWeapon.GetWeapon(weaponId)
|
||||
if weapon == nil {
|
||||
|
||||
Reference in New Issue
Block a user