This commit is contained in:
shoopea 2019-07-08 12:00:11 +08:00
parent 7ed97d0a59
commit 64f9cec17d

9
obj.go
View File

@ -735,13 +735,8 @@ func loadObjItem() error {
return err return err
} }
if _, ok := cacheObjItem.Load(intl_id); !ok { if v, ok := cacheObjItem.Load(intl_id); ok {
c := new(ChatWarsItem) cacheObjItem.Store(name, *v)
c.ObjID64 = id
c.Code = intl_id
c.Name = name
c.Weight = weight
cacheObjItem.Store(name, *c)
} else { } else {
log.Printf("loadObjItem : orphaned obj_name for `%s` : %s.\n", intl_id, name) log.Printf("loadObjItem : orphaned obj_name for `%s` : %s.\n", intl_id, name)
} }