mirror of
https://github.com/FlourishingWorld/hk4e.git
synced 2026-03-01 00:35:36 +08:00
配置表访问接口化,简化常量访问
This commit is contained in:
@@ -1,19 +1,8 @@
|
||||
package constant
|
||||
|
||||
var LifeStateConst *LifeState
|
||||
|
||||
type LifeState struct {
|
||||
LIFE_NONE uint16
|
||||
LIFE_ALIVE uint16
|
||||
LIFE_DEAD uint16
|
||||
LIFE_REVIVE uint16
|
||||
}
|
||||
|
||||
func InitLifeStateConst() {
|
||||
LifeStateConst = new(LifeState)
|
||||
|
||||
LifeStateConst.LIFE_NONE = 0
|
||||
LifeStateConst.LIFE_ALIVE = 1
|
||||
LifeStateConst.LIFE_DEAD = 2
|
||||
LifeStateConst.LIFE_REVIVE = 3
|
||||
}
|
||||
const (
|
||||
LIFE_STATE_NONE uint16 = 0
|
||||
LIFE_STATE_ALIVE uint16 = 1
|
||||
LIFE_STATE_DEAD uint16 = 2
|
||||
LIFE_STATE_REVIVE uint16 = 3
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user