mirror of
https://github.com/FlourishingWorld/hk4e.git
synced 2026-03-01 00:35:36 +08:00
场景物件实体状态更新
This commit is contained in:
@@ -508,6 +508,17 @@ func (g *Group) GetAllEntity() map[uint32]*Entity {
|
||||
return entityMap
|
||||
}
|
||||
|
||||
func (g *Group) GetEntityByConfigId(configId uint32) *Entity {
|
||||
for _, suite := range g.suiteMap {
|
||||
for _, entity := range suite.entityMap {
|
||||
if entity.configId == configId {
|
||||
return entity
|
||||
}
|
||||
}
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func (s *Suite) GetEntityById(entityId uint32) *Entity {
|
||||
return s.entityMap[entityId]
|
||||
}
|
||||
@@ -662,6 +673,10 @@ func (g *GadgetEntity) GetGadgetState() uint32 {
|
||||
return g.gadgetState
|
||||
}
|
||||
|
||||
func (g *GadgetEntity) SetGadgetState(v uint32) {
|
||||
g.gadgetState = v
|
||||
}
|
||||
|
||||
func (g *GadgetEntity) GetGadgetClientEntity() *GadgetClientEntity {
|
||||
return g.gadgetClientEntity
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user