整理场景实体相关,优化同步

This commit is contained in:
huangxiaolei
2022-12-12 10:24:59 +08:00
parent 7fa4cd7f10
commit 62b08c2ac7
20 changed files with 847 additions and 1012 deletions

View File

@@ -7,18 +7,18 @@ import (
// 泛型通用转发器
type InvokeType interface {
type InvokeEntryType interface {
proto.CombatInvokeEntry | proto.AbilityInvokeEntry
}
type InvokeHandler[T InvokeType] struct {
type InvokeHandler[T InvokeEntryType] struct {
EntryListForwardAll []*T
EntryListForwardAllExceptCur []*T
EntryListForwardHost []*T
EntryListForwardServer []*T
}
func NewInvokeHandler[T InvokeType]() (r *InvokeHandler[T]) {
func NewInvokeHandler[T InvokeEntryType]() (r *InvokeHandler[T]) {
r = new(InvokeHandler[T])
r.InitInvokeHandler()
return r