package mapCall import ( capp "f1-game/internal/cherry_app" "f1-game/internal/enum" nameActor "f1-game/internal/name/actor" nameRemote "f1-game/internal/name/remote" mapTypes "f1-game/nodes/map/internal/types" cfacade "github.com/cherry-game/cherry/facade" ) var ( AOI = &aoiCall{ aoiPath: cfacade.NewPath("", nameActor.Map_AOI), } ) type aoiCall struct { aoiPath string } func (p *aoiCall) Enter(req *mapTypes.AOIRequest) { capp.Call(p.aoiPath, nameRemote.MapAOI_Enter, req) } func (p *aoiCall) Move(req *mapTypes.AOIRequest) { capp.Call(p.aoiPath, nameRemote.MapAOI_Move, req) } func (p *aoiCall) Leave(objectID int64, objectType enum.ObjectType) { capp.Call(p.aoiPath, nameRemote.MapAOI_Leave, objectID) } // AOI 全量更新 func (p *aoiCall) UpdateAll(objectID int64, objectType enum.ObjectType) { req := mapTypes.NewUpdateAOIRequest(objectID, objectType, 0, nameRemote.MapLogic_AOIMarkerUpdate) capp.Call(p.aoiPath, nameRemote.MapAOI_Update, req) } // AOI 增量更新 func (p *aoiCall) UpdateWithID(objectID int64, objectType enum.ObjectType, updateID uint32, funcName string) { req := mapTypes.NewUpdateAOIRequest(objectID, objectType, updateID, funcName) capp.Call(p.aoiPath, nameRemote.MapAOI_Update, req) }