1
This commit is contained in:
parent
84a52b0729
commit
5ff979a6ac
@ -49,7 +49,7 @@ var Table = f5.New(func(this *table) {
|
||||
|
||||
this.Global = f5.New(func(this *GlobalTable) {
|
||||
this.FileName = "../res/global@global.json"
|
||||
this.PrimKey = "id"
|
||||
this.PrimKey = "type"
|
||||
})
|
||||
|
||||
this.Reward = f5.New(func(this *RewardTable) {
|
||||
|
@ -15,5 +15,9 @@ type GlobalTable struct {
|
||||
|
||||
func (this *GlobalTable) GetDice() int32 {
|
||||
meta := this.GetById(1)
|
||||
return meta.GetNumber()
|
||||
if meta == nil {
|
||||
return 0
|
||||
} else {
|
||||
return meta.GetNumber()
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user