mirror of
https://github.com/FlourishingWorld/hk4e.git
synced 2026-02-19 04:22:26 +08:00
fix: nil
This commit is contained in:
@@ -254,9 +254,11 @@ func (g *GameManager) CombatInvocationsNotify(player *model.Player, payloadMsg p
|
|||||||
func (g *GameManager) AbilityInvocationsNotify(player *model.Player, payloadMsg pb.Message) {
|
func (g *GameManager) AbilityInvocationsNotify(player *model.Player, payloadMsg pb.Message) {
|
||||||
//logger.LOG.Debug("user ability invocations, uid: %v", player.PlayerID)
|
//logger.LOG.Debug("user ability invocations, uid: %v", player.PlayerID)
|
||||||
req := payloadMsg.(*proto.AbilityInvocationsNotify)
|
req := payloadMsg.(*proto.AbilityInvocationsNotify)
|
||||||
|
|
||||||
if player.AbilityInvokeHandler == nil {
|
if player.AbilityInvokeHandler == nil {
|
||||||
player.AbilityInvokeHandler = model.NewInvokeHandler[proto.AbilityInvokeEntry]()
|
player.AbilityInvokeHandler = model.NewInvokeHandler[proto.AbilityInvokeEntry]()
|
||||||
}
|
}
|
||||||
|
|
||||||
for _, entry := range req.Invokes {
|
for _, entry := range req.Invokes {
|
||||||
//logger.LOG.Debug("AT: %v, FT: %v, UID: %v", entry.ArgumentType, entry.ForwardType, player.PlayerID)
|
//logger.LOG.Debug("AT: %v, FT: %v, UID: %v", entry.ArgumentType, entry.ForwardType, player.PlayerID)
|
||||||
|
|
||||||
@@ -300,6 +302,9 @@ func (g *GameManager) ClientAbilityInitFinishNotify(player *model.Player, payloa
|
|||||||
}
|
}
|
||||||
|
|
||||||
// AbilityInvocationsNotify转发
|
// AbilityInvocationsNotify转发
|
||||||
|
if player.AbilityInvokeHandler == nil {
|
||||||
|
player.AbilityInvokeHandler = model.NewInvokeHandler[proto.AbilityInvokeEntry]()
|
||||||
|
}
|
||||||
// PacketAbilityInvocationsNotify
|
// PacketAbilityInvocationsNotify
|
||||||
if player.AbilityInvokeHandler.AllLen() > 0 {
|
if player.AbilityInvokeHandler.AllLen() > 0 {
|
||||||
abilityInvocationsNotify := new(proto.AbilityInvocationsNotify)
|
abilityInvocationsNotify := new(proto.AbilityInvocationsNotify)
|
||||||
|
|||||||
Reference in New Issue
Block a user