标签:生成 ber get round row play cond param redis
def loadAchieveData(self, data, dbflag):
ffext.dump(‘加载成就数据 ‘)
player = self.ownerref()
back = Achieve()
for row in data:
back = Achieve()
param = row
if not dbflag:
param1 = data[row]
param = json.loads(param1)
if True == back.fromData(param, dbflag):
self.allAchieve[back.type] = back
if dbflag:
DbService.getRedisService().redis_initAchieve(player.uid, back)
return True
对象生成的位置不同 结果会有很大差异
前一种情况
{1: Achieve(conditions="{4: {‘flag‘: 2, ‘num‘: 1}}", type=‘7‘, uid=‘0‘, number=‘1‘), 7: Achieve(conditions="{4: {‘flag‘: 2, ‘num‘: 1}}", type=‘7‘, uid=‘0‘, number=‘1‘)}
后一种情况
{1: Achieve(conditions="{1: {‘flag‘: 2, ‘num‘: 20}, 2: {‘flag‘: 2, ‘num‘: 40}, 5: {‘flag‘: 0, ‘num‘: 300.0}}", type=‘1‘, uid=‘0‘, number=‘2‘), 7: Achieve(conditions="{4: {‘flag‘: 2, ‘num‘: 1}}", type=‘7‘, uid=‘0‘, number=‘1‘)}
标签:生成 ber get round row play cond param redis
原文地址:http://www.cnblogs.com/AngueTone/p/7403616.html