# Model_Shop_ShopDataModel_100.luac
; fn @ShopDataModel.lua  line 0-0 np=0 va=1 ms=4 code=83 consts=29 upvals=1 protos=25
;   K[0]='ShopDataModel'
;   K[1]='__index'
;   K[2]='it'
;   K[3]=0.33333
;   K[4]='OnLoadFileConfigFinished'
;   K[5]='_InitShopOrderConfig'
;   K[6]='GetShopOrderConfig'
;   K[7]='_InitIAPConfigDatas'
;   K[8]='GetIAPConfigDatas'
;   K[9]='GetIAPConfigData'
;   K[10]='GeRefreshBaseGemCost'
;   K[11]='GetNextRefreshGemCost'
;   K[12]='_InitDailyDealsDatas'
;   K[13]='GetNewItemDatasForDailyDeals'
;   K[14]='GetDailyDealsConfig'
;   K[15]='GetNextDailyDealsPrice'
;   K[16]='_InitFlashSaleConfigDatas'
;   K[17]='_GetLackedCount'
;   K[18]='GetNewItemDatasForFlashSale'
;   K[19]='_GetNewItemDatasForFlashSale'
;   K[20]='_ExpandFlashSalePool'
;   K[21]='GetShopLastNoBuyItem'
;   K[22]='GetBuyEnergyCount'
;   K[23]='GetBuyEnergyBaseGemCost'
;   K[24]='GetMaxBuyEnergyGemCost'
;   K[25]='GetBuyEnergyMultiplier'
;   K[26]='GetNextBuyEnergyGemCost'
;   K[27]='GetConfigGemCostForItemType'
;   K[28]='GetGemCostForItemType'
;   upvals: _ENV
;   locals: FLASH_SALE_IT_KEY(6-83), nShopManualRefreshNoBuyItemMultiple(7-83)
0000  NEWTABLE  R0 = {} (0 items)
0001  SETTABUP  _ENV[K0('ShopDataModel')] = R0
0002  GETTABUP  R0 = _ENV[K0('ShopDataModel')]
0003  GETTABUP  R1 = _ENV[K0('ShopDataModel')]
0004  SETTABLE  R0[K1('__index')] = R1
0005  LOADK     R0 = K2 'it'
0006  LOADK     R1 = K3 0.33333
0007  GETTABUP  R2 = _ENV[K0('ShopDataModel')]
0008  CLOSURE   R3 = closure proto0
0009  SETTABLE  R2[K4('OnLoadFileConfigFinished')] = R3
0010  GETTABUP  R2 = _ENV[K0('ShopDataModel')]
0011  CLOSURE   R3 = closure proto1
0012  SETTABLE  R2[K5('_InitShopOrderConfig')] = R3
0013  GETTABUP  R2 = _ENV[K0('ShopDataModel')]
0014  CLOSURE   R3 = closure proto2
0015  SETTABLE  R2[K6('GetShopOrderConfig')] = R3
0016  GETTABUP  R2 = _ENV[K0('ShopDataModel')]
0017  CLOSURE   R3 = closure proto3
0018  SETTABLE  R2[K7('_InitIAPConfigDatas')] = R3
0019  GETTABUP  R2 = _ENV[K0('ShopDataModel')]
0020  CLOSURE   R3 = closure proto4
0021  SETTABLE  R2[K8('GetIAPConfigDatas')] = R3
0022  GETTABUP  R2 = _ENV[K0('ShopDataModel')]
0023  CLOSURE   R3 = closure proto5
0024  SETTABLE  R2[K9('GetIAPConfigData')] = R3
0025  GETTABUP  R2 = _ENV[K0('ShopDataModel')]
0026  CLOSURE   R3 = closure proto6
0027  SETTABLE  R2[K10('GeRefreshBaseGemCost')] = R3
0028  GETTABUP  R2 = _ENV[K0('ShopDataModel')]
0029  CLOSURE   R3 = closure proto7
0030  SETTABLE  R2[K11('GetNextRefreshGemCost')] = R3
0031  GETTABUP  R2 = _ENV[K0('ShopDataModel')]
0032  CLOSURE   R3 = closure proto8
0033  SETTABLE  R2[K12('_InitDailyDealsDatas')] = R3
0034  GETTABUP  R2 = _ENV[K0('ShopDataModel')]
0035  CLOSURE   R3 = closure proto9
0036  SETTABLE  R2[K13('GetNewItemDatasForDailyDeals')] = R3
0037  GETTABUP  R2 = _ENV[K0('ShopDataModel')]
0038  CLOSURE   R3 = closure proto10
0039  SETTABLE  R2[K14('GetDailyDealsConfig')] = R3
0040  GETTABUP  R2 = _ENV[K0('ShopDataModel')]
0041  CLOSURE   R3 = closure proto11
0042  SETTABLE  R2[K15('GetNextDailyDealsPrice')] = R3
0043  GETTABUP  R2 = _ENV[K0('ShopDataModel')]
0044  CLOSURE   R3 = closure proto12
0045  SETTABLE  R2[K16('_InitFlashSaleConfigDatas')] = R3
0046  GETTABUP  R2 = _ENV[K0('ShopDataModel')]
0047  CLOSURE   R3 = closure proto13
0048  SETTABLE  R2[K17('_GetLackedCount')] = R3
0049  GETTABUP  R2 = _ENV[K0('ShopDataModel')]
0050  CLOSURE   R3 = closure proto14
0051  SETTABLE  R2[K18('GetNewItemDatasForFlashSale')] = R3
0052  GETTABUP  R2 = _ENV[K0('ShopDataModel')]
0053  CLOSURE   R3 = closure proto15
0054  SETTABLE  R2[K19('_GetNewItemDatasForFlashSale')] = R3
0055  GETTABUP  R2 = _ENV[K0('ShopDataModel')]
0056  CLOSURE   R3 = closure proto16
0057  SETTABLE  R2[K20('_ExpandFlashSalePool')] = R3
0058  GETTABUP  R2 = _ENV[K0('ShopDataModel')]
0059  CLOSURE   R3 = closure proto17
0060  SETTABLE  R2[K21('GetShopLastNoBuyItem')] = R3
0061  GETTABUP  R2 = _ENV[K0('ShopDataModel')]
0062  CLOSURE   R3 = closure proto18
0063  SETTABLE  R2[K22('GetBuyEnergyCount')] = R3
0064  GETTABUP  R2 = _ENV[K0('ShopDataModel')]
0065  CLOSURE   R3 = closure proto19
0066  SETTABLE  R2[K23('GetBuyEnergyBaseGemCost')] = R3
0067  GETTABUP  R2 = _ENV[K0('ShopDataModel')]
0068  CLOSURE   R3 = closure proto20
0069  SETTABLE  R2[K24('GetMaxBuyEnergyGemCost')] = R3
0070  GETTABUP  R2 = _ENV[K0('ShopDataModel')]
0071  CLOSURE   R3 = closure proto21
0072  SETTABLE  R2[K25('GetBuyEnergyMultiplier')] = R3
0073  GETTABUP  R2 = _ENV[K0('ShopDataModel')]
0074  CLOSURE   R3 = closure proto22
0075  SETTABLE  R2[K26('GetNextBuyEnergyGemCost')] = R3
0076  GETTABUP  R2 = _ENV[K0('ShopDataModel')]
0077  CLOSURE   R3 = closure proto23
0078  SETTABLE  R2[K27('GetConfigGemCostForItemType')] = R3
0079  GETTABUP  R2 = _ENV[K0('ShopDataModel')]
0080  CLOSURE   R3 = closure proto24
0081  SETTABLE  R2[K28('GetGemCostForItemType')] = R3
0082  RETURN    return R0..R-1
; ---------- proto0 [OnLoadFileConfigFinished] ----------
  ; fn ?  line 10-15 np=1 va=0 ms=3 code=9 consts=4 upvals=0 protos=0
  ;   K[0]='_InitShopOrderConfig'
  ;   K[1]='_InitIAPConfigDatas'
  ;   K[2]='_InitDailyDealsDatas'
  ;   K[3]='_InitFlashSaleConfigDatas'
  ;   locals: self(0-9)
  0000  SELF      R2 = R0[K0('_InitShopOrderConfig')] (self)
  0001  CALL      R1 = call(R1, 0 args, 1 rets)
  0002  SELF      R2 = R0[K1('_InitIAPConfigDatas')] (self)
  0003  CALL      R1 = call(R1, 0 args, 1 rets)
  0004  SELF      R2 = R0[K2('_InitDailyDealsDatas')] (self)
  0005  CALL      R1 = call(R1, 0 args, 1 rets)
  0006  SELF      R2 = R0[K3('_InitFlashSaleConfigDatas')] (self)
  0007  CALL      R1 = call(R1, 0 args, 1 rets)
  0008  RETURN    return R0..R-1
; ---------- proto1 [_InitShopOrderConfig] ----------
  ; fn ?  line 17-24 np=1 va=0 ms=9 code=17 consts=8 upvals=1 protos=0
  ;   K[0]='GM'
  ;   K[1]='ConfigModel'
  ;   K[2]='GetLocalConfig'
  ;   K[3]='LocalConfigKey'
  ;   K[4]='ShopOrder'
  ;   K[5]='ipairs'
  ;   K[6]='Name'
  ;   K[7]='m_mapShopOrderConfig'
  ;   upvals: _ENV
  ;   locals: self(0-17), shopOrderConfig(6-17), mapShopOrderConfig(7-17), (for generator)(10-15), (for state)(10-15), (for control)(10-15), _(11-13), orderConfig(11-13)
  0000  GETTABUP  R1 = _ENV[K0('GM')]
  0001  GETTABLE  R1 = R1[K1('ConfigModel')]
  0002  SELF      R2 = R1[K2('GetLocalConfig')] (self)
  0003  GETTABUP  R3 = _ENV[K3('LocalConfigKey')]
  0004  GETTABLE  R3 = R3[K4('ShopOrder')]
  0005  CALL      R1 = call(R1, 1 args, 2 rets)
  0006  NEWTABLE  R2 = {} (0 items)
  0007  GETTABUP  R3 = _ENV[K5('ipairs')]
  0008  MOVE      R4 = R0
  0009  CALL      R3 = call(R3, 3 args, 1 rets)
  0010  JMP       (jump)   -> 13
  0011  GETTABLE  R8 = R7[K6('Name')]
  0012  SETTABLE  R2[R8] = R7
  0013  TFORCALL  tforcall R3
  0014  TFORLOOP  tforloop R5(sBx=-4)   -> 11
  0015  SETTABLE  R0[K7('m_mapShopOrderConfig')] = R2
  0016  RETURN    return R0..R-1
; ---------- proto2 [GetShopOrderConfig] ----------
  ; fn ?  line 26-28 np=1 va=0 ms=2 code=3 consts=1 upvals=0 protos=0
  ;   K[0]='m_mapShopOrderConfig'
  ;   locals: self(0-3)
  0000  GETTABLE  R1 = R0[K0('m_mapShopOrderConfig')]
  0001  RETURN    return R1..R0
  0002  RETURN    return R0..R-1
; ---------- proto3 [_InitIAPConfigDatas] ----------
  ; fn ?  line 39-51 np=1 va=0 ms=9 code=35 consts=13 upvals=1 protos=0
  ;   K[0]='m_mapIAPDatas'
  ;   K[1]='ipairs'
  ;   K[2]='GM'
  ;   K[3]='ConfigModel'
  ;   K[4]='GetLocalConfig'
  ;   K[5]='LocalConfigKey'
  ;   K[6]='ShopIAP'
  ;   K[7]='goods'
  ;   K[8]='ConfigUtil'
  ;   K[9]='GetCurrencyFromArrStr'
  ;   K[10]='type'
  ;   K[11]=nil
  ;   K[12]=1
  ;   upvals: _ENV
  ;   locals: self(0-35), eShopType(3-35), (for generator)(11-34), (for state)(11-34), (for control)(11-34), _(12-32), data(12-32)
  0000  NEWTABLE  R1 = {} (0 items)
  0001  SETTABLE  R0[K0('m_mapIAPDatas')] = R1
  0002  LOADNIL   R1..R1 = nil
  0003  GETTABUP  R2 = _ENV[K1('ipairs')]
  0004  GETTABUP  R3 = _ENV[K2('GM')]
  0005  GETTABLE  R3 = R3[K3('ConfigModel')]
  0006  SELF      R4 = R3[K4('GetLocalConfig')] (self)
  0007  GETTABUP  R5 = _ENV[K5('LocalConfigKey')]
  0008  GETTABLE  R5 = R5[K6('ShopIAP')]
  0009  CALL      R3 = call(R3, -1 args, 2 rets)
  0010  CALL      R2 = call(R2, 3 args, -1 rets)
  0011  JMP       (jump)   -> 32
  0012  GETTABUP  R7 = _ENV[K8('ConfigUtil')]
  0013  GETTABLE  R7 = R7[K9('GetCurrencyFromArrStr')]
  0014  GETTABLE  R8 = R6[K7('goods')]
  0015  CALL      R7 = call(R7, 1 args, 1 rets)
  0016  SETTABLE  R6[K7('goods')] = R7
  0017  GETTABLE  R1 = R6[K10('type')]
  0018  GETTABLE  R7 = R0[K0('m_mapIAPDatas')]
  0019  GETTABLE  R7 = R7[R1]
  0020  EQ        if R0 eq K11(nil)   -> -127199
  0021  JMP       (jump)   -> 25
  0022  GETTABLE  R7 = R0[K0('m_mapIAPDatas')]
  0023  NEWTABLE  R8 = {} (0 items)
  0024  SETTABLE  R7[R1] = R8
  0025  GETTABLE  R7 = R0[K0('m_mapIAPDatas')]
  0026  GETTABLE  R7 = R7[R1]
  0027  GETTABLE  R8 = R0[K0('m_mapIAPDatas')]
  0028  GETTABLE  R8 = R8[R1]
  0029  LEN       R8 = len R0
  0030  ADD       R8 = K12(1) add R8
  0031  SETTABLE  R7[R8] = R6
  0032  TFORCALL  tforcall R2
  0033  TFORLOOP  tforloop R4(sBx=-22)   -> 12
  0034  RETURN    return R0..R-1
; ---------- proto4 [GetIAPConfigDatas] ----------
  ; fn ?  line 53-55 np=2 va=0 ms=3 code=4 consts=1 upvals=0 protos=0
  ;   K[0]='m_mapIAPDatas'
  ;   locals: self(0-4), shopType(0-4)
  0000  GETTABLE  R2 = R0[K0('m_mapIAPDatas')]
  0001  GETTABLE  R2 = R2[R1]
  0002  RETURN    return R2..R1
  0003  RETURN    return R0..R-1
; ---------- proto5 [GetIAPConfigData] ----------
  ; fn ?  line 57-68 np=3 va=0 ms=9 code=20 consts=4 upvals=1 protos=0
  ;   K[0]='m_mapIAPDatas'
  ;   K[1]=nil
  ;   K[2]='ipairs'
  ;   K[3]='purchaseId'
  ;   upvals: _ENV
  ;   locals: self(0-20), shopType(0-20), eIAPType(0-20), (for generator)(10-17), (for state)(10-17), (for control)(10-17), _(11-15), v(11-15)
  0000  GETTABLE  R3 = R0[K0('m_mapIAPDatas')]
  0001  GETTABLE  R3 = R3[R1]
  0002  EQ        if R0 eq K1(nil)   -> -129275
  0003  JMP       (jump)   -> 6
  0004  LOADNIL   R3..R3 = nil
  0005  RETURN    return R3..R2
  0006  GETTABUP  R3 = _ENV[K2('ipairs')]
  0007  GETTABLE  R4 = R0[K0('m_mapIAPDatas')]
  0008  GETTABLE  R4 = R4[R1]
  0009  CALL      R3 = call(R3, 3 args, 1 rets)
  0010  JMP       (jump)   -> 15
  0011  GETTABLE  R8 = R7[K3('purchaseId')]
  0012  EQ        if R0 eq R2   -> -126960
  0013  JMP       (jump)   -> 15
  0014  RETURN    return R7..R6
  0015  TFORCALL  tforcall R3
  0016  TFORLOOP  tforloop R5(sBx=-6)   -> 11
  0017  LOADNIL   R3..R3 = nil
  0018  RETURN    return R3..R2
  0019  RETURN    return R0..R-1
; ---------- proto6 [GeRefreshBaseGemCost] ----------
  ; fn ?  line 70-72 np=1 va=0 ms=3 code=9 consts=4 upvals=1 protos=0
  ;   K[0]='tonumber'
  ;   K[1]='m_mapFlashSaleConfig'
  ;   K[2]='refreshCostCount'
  ;   K[3]=10
  ;   upvals: _ENV
  ;   locals: self(0-9)
  0000  GETTABUP  R1 = _ENV[K0('tonumber')]
  0001  GETTABLE  R2 = R0[K1('m_mapFlashSaleConfig')]
  0002  GETTABLE  R2 = R2[K2('refreshCostCount')]
  0003  CALL      R1 = call(R1, 1 args, 1 rets)
  0004  TEST      if not R1 then   -> -131065
  0005  JMP       (jump)   -> 7
  0006  LOADK     R1 = K3 10
  0007  RETURN    return R1..R0
  0008  RETURN    return R0..R-1
; ---------- proto7 [GetNextRefreshGemCost] ----------
  ; fn ?  line 75-79 np=2 va=0 ms=8 code=24 consts=9 upvals=1 protos=0
  ;   K[0]='tonumber'
  ;   K[1]='m_mapFlashSaleConfig'
  ;   K[2]='refreshMultiplier'
  ;   K[3]=2
  ;   K[4]='refreshMaxCost'
  ;   K[5]=40
  ;   K[6]='math'
  ;   K[7]='ceil'
  ;   K[8]='min'
  ;   upvals: _ENV
  ;   locals: self(0-24), former(0-24), multiplier(7-24), maxCost(14-24)
  0000  GETTABUP  R2 = _ENV[K0('tonumber')]
  0001  GETTABLE  R3 = R0[K1('m_mapFlashSaleConfig')]
  0002  GETTABLE  R3 = R3[K2('refreshMultiplier')]
  0003  CALL      R2 = call(R2, 1 args, 1 rets)
  0004  TEST      if not R2 then   -> -131065
  0005  JMP       (jump)   -> 7
  0006  LOADK     R2 = K3 2
  0007  GETTABUP  R3 = _ENV[K0('tonumber')]
  0008  GETTABLE  R4 = R0[K1('m_mapFlashSaleConfig')]
  0009  GETTABLE  R4 = R4[K4('refreshMaxCost')]
  0010  CALL      R3 = call(R3, 1 args, 1 rets)
  0011  TEST      if not R3 then   -> -131058
  0012  JMP       (jump)   -> 14
  0013  LOADK     R3 = K5 40
  0014  GETTABUP  R4 = _ENV[K6('math')]
  0015  GETTABLE  R4 = R4[K7('ceil')]
  0016  GETTABUP  R5 = _ENV[K6('math')]
  0017  GETTABLE  R5 = R5[K8('min')]
  0018  MOVE      R6 = R0
  0019  MUL       R7 = R2 mul R1
  0020  CALL      R5 = call(R5, -1 args, 2 rets)
  0021  TAILCALL  tailcall(R4, 0)
  0022  RETURN    return R4..R3
  0023  RETURN    return R0..R-1
; ---------- proto8 [_InitDailyDealsDatas] ----------
  ; fn ?  line 84-94 np=1 va=0 ms=8 code=33 consts=16 upvals=1 protos=1
  ;   K[0]='m_arrDailyDealsConfigs'
  ;   K[1]='Table'
  ;   K[2]='DeepCopy'
  ;   K[3]='GM'
  ;   K[4]='ConfigModel'
  ;   K[5]='GetLocalConfig'
  ;   K[6]='LocalConfigKey'
  ;   K[7]='ShopDailyDeals'
  ;   K[8]='Empty'
  ;   K[9]='m_mapDailyDealsConfigs'
  ;   K[10]='table'
  ;   K[11]='sort'
  ;   K[12]='ipairs'
  ;   K[13]='id'
  ;   K[14]=nil
  ;   K[15]='itemCode'
  ;   upvals: _ENV
  ;   locals: self(0-33), (for generator)(25-32), (for state)(25-32), (for control)(25-32), _(26-30), config(26-30)
  0000  GETTABUP  R1 = _ENV[K1('Table')]
  0001  GETTABLE  R1 = R1[K2('DeepCopy')]
  0002  GETTABUP  R2 = _ENV[K3('GM')]
  0003  GETTABLE  R2 = R2[K4('ConfigModel')]
  0004  SELF      R3 = R2[K5('GetLocalConfig')] (self)
  0005  GETTABUP  R4 = _ENV[K6('LocalConfigKey')]
  0006  GETTABLE  R4 = R4[K7('ShopDailyDeals')]
  0007  CALL      R2 = call(R2, 1 args, 2 rets)
  0008  TEST      if not R2 then   -> -131061
  0009  JMP       (jump)   -> 12
  0010  GETTABUP  R2 = _ENV[K1('Table')]
  0011  GETTABLE  R2 = R2[K8('Empty')]
  0012  LOADBOOL  R3 = true
  0013  CALL      R1 = call(R1, 1 args, 2 rets)
  0014  SETTABLE  R0[K0('m_arrDailyDealsConfigs')] = R1
  0015  NEWTABLE  R1 = {} (0 items)
  0016  SETTABLE  R0[K9('m_mapDailyDealsConfigs')] = R1
  0017  GETTABUP  R1 = _ENV[K10('table')]
  0018  GETTABLE  R1 = R1[K11('sort')]
  0019  GETTABLE  R2 = R0[K0('m_arrDailyDealsConfigs')]
  0020  CLOSURE   R3 = closure proto0
  0021  CALL      R1 = call(R1, 0 args, 2 rets)
  0022  GETTABUP  R1 = _ENV[K12('ipairs')]
  0023  GETTABLE  R2 = R0[K0('m_arrDailyDealsConfigs')]
  0024  CALL      R1 = call(R1, 3 args, 1 rets)
  0025  JMP       (jump)   -> 30
  0026  SETTABLE  R5[K13('id')] = K14(nil)
  0027  GETTABLE  R6 = R0[K9('m_mapDailyDealsConfigs')]
  0028  GETTABLE  R7 = R5[K15('itemCode')]
  0029  SETTABLE  R6[R7] = R5
  0030  TFORCALL  tforcall R1
  0031  TFORLOOP  tforloop R3(sBx=-6)   -> 26
  0032  RETURN    return R0..R-1
  ; ---------- proto0 [] ----------
    ; fn ?  line 87-87 np=2 va=0 ms=4 code=8 consts=1 upvals=0 protos=0
    ;   K[0]='id'
    ;   locals: a(0-8), b(0-8)
    0000  GETTABLE  R2 = R0[K0('id')]
    0001  GETTABLE  R3 = R1[K0('id')]
    0002  LT        if R1 lt R3   -> -130041
    0003  JMP       (jump)   -> 5
    0004  LOADBOOL  R2 = false
    0005  LOADBOOL  R2 = true
    0006  RETURN    return R2..R1
    0007  RETURN    return R0..R-1
; ---------- proto9 [GetNewItemDatasForDailyDeals] ----------
  ; fn ?  line 96-98 np=1 va=0 ms=2 code=3 consts=1 upvals=0 protos=0
  ;   K[0]='m_arrDailyDealsConfigs'
  ;   locals: self(0-3)
  0000  GETTABLE  R1 = R0[K0('m_arrDailyDealsConfigs')]
  0001  RETURN    return R1..R0
  0002  RETURN    return R0..R-1
; ---------- proto10 [GetDailyDealsConfig] ----------
  ; fn ?  line 100-102 np=2 va=0 ms=3 code=7 consts=1 upvals=0 protos=0
  ;   K[0]='m_mapDailyDealsConfigs'
  ;   locals: self(0-7), itemCode(0-7)
  0000  GETTABLE  R2 = R0[K0('m_mapDailyDealsConfigs')]
  0001  GETTABLE  R2 = R2[R1]
  0002  TEST      if not R2 then   -> -131067
  0003  JMP       (jump)   -> 5
  0004  NEWTABLE  R2 = {} (0 items)
  0005  RETURN    return R2..R1
  0006  RETURN    return R0..R-1
; ---------- proto11 [GetNextDailyDealsPrice] ----------
  ; fn ?  line 104-116 np=3 va=0 ms=8 code=22 consts=5 upvals=1 protos=0
  ;   K[0]='m_mapDailyDealsConfigs'
  ;   K[1]='multiplier'
  ;   K[2]='maxCostCount'
  ;   K[3]='math'
  ;   K[4]='ceil'
  ;   upvals: _ENV
  ;   locals: self(0-22), itemCode(0-22), lastPrice(0-22), config(2-22), nextPrice(10-22), maxCost(11-22)
  0000  GETTABLE  R3 = R0[K0('m_mapDailyDealsConfigs')]
  0001  GETTABLE  R3 = R3[R1]
  0002  TEST      if not R3 then   -> -131068
  0003  JMP       (jump)   -> 7
  0004  GETTABLE  R4 = R3[K1('multiplier')]
  0005  TEST      if not R4 then   -> -131064
  0006  JMP       (jump)   -> 8
  0007  RETURN    return R2..R1
  0008  GETTABLE  R4 = R3[K1('multiplier')]
  0009  MUL       R4 = R4 mul R2
  0010  GETTABLE  R5 = R3[K2('maxCostCount')]
  0011  TEST      if not R5 then   -> -131059
  0012  JMP       (jump)   -> 16
  0013  LT        if R0 lt R4   -> -128493
  0014  JMP       (jump)   -> 16
  0015  MOVE      R4 = R0
  0016  GETTABUP  R6 = _ENV[K3('math')]
  0017  GETTABLE  R6 = R6[K4('ceil')]
  0018  MOVE      R7 = R0
  0019  TAILCALL  tailcall(R6, 0)
  0020  RETURN    return R6..R5
  0021  RETURN    return R0..R-1
; ---------- proto12 [_InitFlashSaleConfigDatas] ----------
  ; fn ?  line 120-152 np=1 va=0 ms=18 code=116 consts=32 upvals=2 protos=0
  ;   K[0]='m_mapItemPrice'
  ;   K[1]='GM'
  ;   K[2]='ConfigModel'
  ;   K[3]='GetLocalConfig'
  ;   K[4]='LocalConfigKey'
  ;   K[5]='ItemProperty'
  ;   K[6]='ipairs'
  ;   K[7]='Type'
  ;   K[8]='BubblePrice'
  ;   K[9]='ItemDataModel'
  ;   K[10]='m_mapFlashSaleConfig'
  ;   K[11]='ShopFlashSale'
  ;   K[12]='Table'
  ;   K[13]='Empty'
  ;   K[14]=0
  ;   K[15]='slots'
  ;   K[16]=1
  ;   K[17]='tonumber'
  ;   K[18]='leftCount'
  ;   K[19]='Log'
  ;   K[20]='Error'
  ;   K[21]='ShopFlashSaleConfig 闪售 leftCount 配置错误'
  ;   K[22]='item'
  ;   K[23]='ShopFlashSaleConfig 闪售 item 配置错误'
  ;   K[24]='itemId'
  ;   K[25]='IsItemExist'
  ;   K[26]='ShopFlashSaleConfig 闪售 itemId 配置错误'
  ;   K[27]='ShopFlashSaleConfig 闪售 itemId 没有价格 '
  ;   K[28]='tostring'
  ;   K[29]='Assert'
  ;   K[30]=3
  ;   K[31]='闪售商品槽位数不能被3整除！'
  ;   upvals: _ENV, FLASH_SALE_IT_KEY
  ;   locals: self(0-116), config(8-116), (for generator)(11-18), (for state)(11-18), (for control)(11-18), index(12-16), config(12-16), itemDataModel(20-116), flashSaleSlotCount(32-116), (for generator)(39-104), (for state)(39-104), (for control)(39-104), _(40-102), slotConfig(40-102), (for generator)(65-102), (for state)(65-102), (for control)(65-102), _(66-100), slotItemConfig(66-100)
  0000  NEWTABLE  R1 = {} (0 items)
  0001  SETTABLE  R0[K0('m_mapItemPrice')] = R1
  0002  GETTABUP  R1 = _ENV[K1('GM')]
  0003  GETTABLE  R1 = R1[K2('ConfigModel')]
  0004  SELF      R2 = R1[K3('GetLocalConfig')] (self)
  0005  GETTABUP  R3 = _ENV[K4('LocalConfigKey')]
  0006  GETTABLE  R3 = R3[K5('ItemProperty')]
  0007  CALL      R1 = call(R1, 1 args, 2 rets)
  0008  GETTABUP  R2 = _ENV[K6('ipairs')]
  0009  MOVE      R3 = R0
  0010  CALL      R2 = call(R2, 3 args, 1 rets)
  0011  JMP       (jump)   -> 16
  0012  GETTABLE  R7 = R0[K0('m_mapItemPrice')]
  0013  GETTABLE  R8 = R6[K7('Type')]
  0014  GETTABLE  R9 = R6[K8('BubblePrice')]
  0015  SETTABLE  R7[R8] = R9
  0016  TFORCALL  tforcall R2
  0017  TFORLOOP  tforloop R4(sBx=-6)   -> 12
  0018  GETTABUP  R2 = _ENV[K1('GM')]
  0019  GETTABLE  R2 = R2[K9('ItemDataModel')]
  0020  GETTABUP  R3 = _ENV[K1('GM')]
  0021  GETTABLE  R3 = R3[K2('ConfigModel')]
  0022  SELF      R4 = R3[K3('GetLocalConfig')] (self)
  0023  GETTABUP  R5 = _ENV[K4('LocalConfigKey')]
  0024  GETTABLE  R5 = R5[K11('ShopFlashSale')]
  0025  CALL      R3 = call(R3, 1 args, 2 rets)
  0026  TEST      if not R3 then   -> -131043
  0027  JMP       (jump)   -> 30
  0028  GETTABUP  R3 = _ENV[K12('Table')]
  0029  GETTABLE  R3 = R3[K13('Empty')]
  0030  SETTABLE  R0[K10('m_mapFlashSaleConfig')] = R3
  0031  LOADK     R3 = K14 0
  0032  GETTABUP  R4 = _ENV[K6('ipairs')]
  0033  GETTABLE  R5 = R0[K10('m_mapFlashSaleConfig')]
  0034  GETTABLE  R5 = R5[K15('slots')]
  0035  TEST      if not R5 then   -> -131034
  0036  JMP       (jump)   -> 38
  0037  NEWTABLE  R5 = {} (0 items)
  0038  CALL      R4 = call(R4, 3 args, 1 rets)
  0039  JMP       (jump)   -> 102
  0040  ADD       R3 = K16(1) add R3
  0041  GETTABUP  R9 = _ENV[K17('tonumber')]
  0042  GETTABLE  R10 = R8[K18('leftCount')]
  0043  CALL      R9 = call(R9, 1 args, 1 rets)
  0044  TEST      if not R9 then   -> -131025
  0045  JMP       (jump)   -> 50
  0046  GETTABUP  R9 = _ENV[K19('Log')]
  0047  GETTABLE  R9 = R9[K20('Error')]
  0048  LOADK     R10 = K21 'ShopFlashSaleConfig 闪售 leftCount 配置错误'
  0049  CALL      R9 = call(R9, 0 args, 1 rets)
  0050  GETTABLE  R9 = R8[K22('item')]
  0051  TEST      if not R9 then   -> -131019
  0052  JMP       (jump)   -> 57
  0053  GETTABLE  R9 = R8[K22('item')]
  0054  GETTABLE  R9 = R9[K16(1)]
  0055  TEST      if not R9 then   -> -131014
  0056  JMP       (jump)   -> 62
  0057  GETTABUP  R9 = _ENV[K19('Log')]
  0058  GETTABLE  R9 = R9[K20('Error')]
  0059  LOADK     R10 = K23 'ShopFlashSaleConfig 闪售 item 配置错误'
  0060  CALL      R9 = call(R9, 0 args, 1 rets)
  0061  JMP       (jump)   -> 102
  0062  GETTABUP  R9 = _ENV[K6('ipairs')]
  0063  GETTABLE  R10 = R8[K22('item')]
  0064  CALL      R9 = call(R9, 3 args, 1 rets)
  0065  JMP       (jump)   -> 100
  0066  GETTABLE  R14 = R13[K24('itemId')]
  0067  TEST      if not R14 then   -> -131003
  0068  JMP       (jump)   -> 78
  0069  GETTABLE  R14 = R13[K24('itemId')]
  0070  GETUPVAL  R15 = _ENV
  0071  EQ        if R1 eq R15   -> -123816
  0072  JMP       (jump)   -> 83
  0073  SELF      R15 = R2[K25('IsItemExist')] (self)
  0074  GETTABLE  R16 = R13[K24('itemId')]
  0075  CALL      R14 = call(R14, 1 args, 2 rets)
  0076  TEST      if not R14 then   -> -130993
  0077  JMP       (jump)   -> 83
  0078  GETTABUP  R14 = _ENV[K19('Log')]
  0079  GETTABLE  R14 = R14[K20('Error')]
  0080  LOADK     R15 = K26 'ShopFlashSaleConfig 闪售 itemId 配置错误'
  0081  CALL      R14 = call(R14, 0 args, 1 rets)
  0082  JMP       (jump)   -> 100
  0083  GETTABLE  R14 = R13[K24('itemId')]
  0084  GETUPVAL  R15 = _ENV
  0085  EQ        if R1 eq R15   -> -123802
  0086  JMP       (jump)   -> 100
  0087  GETTABLE  R14 = R0[K0('m_mapItemPrice')]
  0088  GETTABLE  R15 = R13[K24('itemId')]
  0089  GETTABLE  R14 = R14[R15]
  0090  TEST      if not R14 then   -> -130979
  0091  JMP       (jump)   -> 100
  0092  GETTABUP  R14 = _ENV[K19('Log')]
  0093  GETTABLE  R14 = R14[K20('Error')]
  0094  LOADK     R15 = K27 'ShopFlashSaleConfig 闪售 itemId 没有价格 '
  0095  GETTABUP  R16 = _ENV[K28('tostring')]
  0096  GETTABLE  R17 = R13[K24('itemId')]
  0097  CALL      R16 = call(R16, 1 args, 1 rets)
  0098  CONCAT    R15 = concat(R15..R15)
  0099  CALL      R14 = call(R14, 0 args, 1 rets)
  0100  TFORCALL  tforcall R9
  0101  TFORLOOP  tforloop R11(sBx=-36)   -> 66
  0102  TFORCALL  tforcall R4
  0103  TFORLOOP  tforloop R6(sBx=-64)   -> 40
  0104  GETTABUP  R4 = _ENV[K19('Log')]
  0105  GETTABLE  R4 = R4[K29('Assert')]
  0106  LT        if R0 lt R3   -> 7279
  0107  JMP       (jump)   -> 111
  0108  MOD       R5 = K30(3) mod R3
  0109  EQ        if R1 eq K14(0)   -> -128131
  0110  JMP       (jump)   -> 112
  0111  LOADBOOL  R5 = false
  0112  LOADBOOL  R5 = true
  0113  LOADK     R6 = K31 '闪售商品槽位数不能被3整除！'
  0114  CALL      R4 = call(R4, 0 args, 2 rets)
  0115  RETURN    return R0..R-1
; ---------- proto13 [_GetLackedCount] ----------
  ; fn ?  line 154-171 np=4 va=0 ms=6 code=21 consts=2 upvals=0 protos=0
  ;   K[0]=0
  ;   K[1]=nil
  ;   locals: self(0-21), itemCode(0-21), itemCount(0-21), codeCountMap(0-21), existCount(1-21)
  0000  GETTABLE  R4 = R3[R1]
  0001  TEST      if not R4 then   -> -131069
  0002  JMP       (jump)   -> 19
  0003  LT        if R0 lt R4   -> 9
  0004  JMP       (jump)   -> 19
  0005  LE        if R0 le R4   -> -130037
  0006  JMP       (jump)   -> 15
  0007  SUB       R5 = R2 sub R4
  0008  SETTABLE  R3[R1] = R5
  0009  EQ        if R0 eq R2   -> -129011
  0010  JMP       (jump)   -> 12
  0011  SETTABLE  R3[R1] = K1(nil)
  0012  LOADK     R5 = K0 0
  0013  RETURN    return R5..R4
  0014  JMP       (jump)   -> 20
  0015  SETTABLE  R3[R1] = K1(nil)
  0016  SUB       R5 = R4 sub R2
  0017  RETURN    return R5..R4
  0018  JMP       (jump)   -> 20
  0019  RETURN    return R2..R1
  0020  RETURN    return R0..R-1
; ---------- proto14 [GetNewItemDatasForFlashSale] ----------
  ; fn ?  line 176-208 np=2 va=0 ms=16 code=79 consts=21 upvals=2 protos=0
  ;   K[0]='ipairs'
  ;   K[1]='m_mapFlashSaleConfig'
  ;   K[2]='slots'
  ;   K[3]='Table'
  ;   K[4]='ListWeightSelectOne'
  ;   K[5]='item'
  ;   K[6]='weight'
  ;   K[7]=1
  ;   K[8]='itemId'
  ;   K[9]='leftCount'
  ;   K[10]='_GetNewItemDatasForFlashSale'
  ;   K[11]='table'
  ;   K[12]='remove'
  ;   K[13]='itemCode'
  ;   K[14]='startCount'
  ;   K[15]='costType'
  ;   K[16]='EPropertyType'
  ;   K[17]='Gem'
  ;   K[18]='costCount'
  ;   K[19]='m_mapItemPrice'
  ;   K[20]=999
  ;   upvals: _ENV, FLASH_SALE_IT_KEY
  ;   locals: self(0-79), aLastShopItem(0-79), arrItemSelected(1-79), arrCount(2-79), arrITCount(3-79), mapITIndex(4-79), (for generator)(11-35), (for state)(11-35), (for control)(11-35), _(12-33), slotConfig(12-33), selected(17-33), arrITResults(39-79), arrResults(40-79), (for generator)(43-77), (for state)(43-77), (for control)(43-77), index(44-75), itemId(44-75)
  0000  NEWTABLE  R2 = {} (0 items)
  0001  NEWTABLE  R3 = {} (0 items)
  0002  NEWTABLE  R4 = {} (0 items)
  0003  NEWTABLE  R5 = {} (0 items)
  0004  GETTABUP  R6 = _ENV[K0('ipairs')]
  0005  GETTABLE  R7 = R0[K1('m_mapFlashSaleConfig')]
  0006  GETTABLE  R7 = R7[K2('slots')]
  0007  TEST      if not R7 then   -> -131062
  0008  JMP       (jump)   -> 10
  0009  NEWTABLE  R7 = {} (0 items)
  0010  CALL      R6 = call(R6, 3 args, 1 rets)
  0011  JMP       (jump)   -> 33
  0012  GETTABUP  R11 = _ENV[K3('Table')]
  0013  GETTABLE  R11 = R11[K4('ListWeightSelectOne')]
  0014  GETTABLE  R12 = R10[K5('item')]
  0015  LOADK     R13 = K6 'weight'
  0016  CALL      R11 = call(R11, 1 args, 2 rets)
  0017  LEN       R12 = len R0
  0018  ADD       R12 = K7(1) add R12
  0019  GETTABLE  R13 = R11[K8('itemId')]
  0020  SETTABLE  R2[R12] = R13
  0021  LEN       R12 = len R0
  0022  ADD       R12 = K7(1) add R12
  0023  GETTABLE  R13 = R10[K9('leftCount')]
  0024  SETTABLE  R3[R12] = R13
  0025  GETTABLE  R12 = R11[K8('itemId')]
  0026  GETUPVAL  R13 = _ENV
  0027  EQ        if R0 eq R13   -> -124886
  0028  JMP       (jump)   -> 33
  0029  LEN       R12 = len R0
  0030  ADD       R12 = K7(1) add R12
  0031  GETTABLE  R13 = R10[K9('leftCount')]
  0032  SETTABLE  R4[R12] = R13
  0033  TFORCALL  tforcall R6
  0034  TFORLOOP  tforloop R8(sBx=-23)   -> 12
  0035  SELF      R7 = R0[K10('_GetNewItemDatasForFlashSale')] (self)
  0036  MOVE      R8 = R0
  0037  MOVE      R9 = R0
  0038  CALL      R6 = call(R6, 1 args, 3 rets)
  0039  NEWTABLE  R7 = {} (0 items)
  0040  GETTABUP  R8 = _ENV[K0('ipairs')]
  0041  MOVE      R9 = R0
  0042  CALL      R8 = call(R8, 3 args, 1 rets)
  0043  JMP       (jump)   -> 75
  0044  GETUPVAL  R13 = _ENV
  0045  EQ        if R0 eq R13   -> -124868
  0046  JMP       (jump)   -> 57
  0047  LEN       R13 = len R0
  0048  ADD       R13 = K7(1) add R13
  0049  GETTABLE  R14 = R6[K7(1)]
  0050  SETTABLE  R7[R13] = R14
  0051  GETTABUP  R13 = _ENV[K11('table')]
  0052  GETTABLE  R13 = R13[K12('remove')]
  0053  MOVE      R14 = R0
  0054  LOADK     R15 = K7 1
  0055  CALL      R13 = call(R13, 0 args, 2 rets)
  0056  JMP       (jump)   -> 75
  0057  LEN       R13 = len R0
  0058  ADD       R13 = K7(1) add R13
  0059  NEWTABLE  R14 = {} (0 items)
  0060  SETTABLE  R14[K13('itemCode')] = R12
  0061  GETTABLE  R15 = R3[R11]
  0062  SETTABLE  R14[K9('leftCount')] = R15
  0063  GETTABLE  R15 = R3[R11]
  0064  SETTABLE  R14[K14('startCount')] = R15
  0065  GETTABUP  R15 = _ENV[K16('EPropertyType')]
  0066  GETTABLE  R15 = R15[K17('Gem')]
  0067  SETTABLE  R14[K15('costType')] = R15
  0068  GETTABLE  R15 = R0[K19('m_mapItemPrice')]
  0069  GETTABLE  R15 = R15[R12]
  0070  TEST      if not R15 then   -> -130999
  0071  JMP       (jump)   -> 73
  0072  LOADK     R15 = K20 999
  0073  SETTABLE  R14[K18('costCount')] = R15
  0074  SETTABLE  R7[R13] = R14
  0075  TFORCALL  tforcall R8
  0076  TFORLOOP  tforloop R10(sBx=-33)   -> 44
  0077  RETURN    return R7..R6
  0078  RETURN    return R0..R-1
; ---------- proto15 [_GetNewItemDatasForFlashSale] ----------
  ; fn ?  line 210-346 np=3 va=0 ms=26 code=279 consts=41 upvals=1 protos=0
  ;   K[0]=0
  ;   K[1]='GameConfig'
  ;   K[2]='IsTestMode'
  ;   K[3]='TestAccumulatedLogInfo'
  ;   K[4]='LogNow'
  ;   K[5]='--------------商城闪售刷新了----------------'
  ;   K[6]='商城闪售无需随机生成 IT 棋子'
  ;   K[7]='Start'
  ;   K[8]='GM'
  ;   K[9]='MainBoardModel'
  ;   K[10]='GetUnfilledDirectOrderRequirements'
  ;   K[11]='ItemDataModel'
  ;   K[12]='pairs'
  ;   K[13]='IsDishes'
  ;   K[14]='ipairs'
  ;   K[15]='GetMaterials'
  ;   K[16]='_GetLackedCount'
  ;   K[17]='m_mapItemPrice'
  ;   K[18]='next'
  ;   K[19]=nil
  ;   K[20]='GetShopLastNoBuyItem'
  ;   K[21]='_ExpandFlashSalePool'
  ;   K[22]=128
  ;   K[23]=1
  ;   K[24]='Code'
  ;   K[25]='Weight'
  ;   K[26]=true
  ;   K[27]='Table'
  ;   K[28]='ListWeightSelectOne'
  ;   K[29]='table'
  ;   K[30]='remove'
  ;   K[31]='itemCode'
  ;   K[32]='leftCount'
  ;   K[33]='startCount'
  ;   K[34]='costType'
  ;   K[35]='EPropertyType'
  ;   K[36]='Gem'
  ;   K[37]='costCount'
  ;   K[38]='IsUnlocked'
  ;   K[39]='ListRandomSelectN'
  ;   K[40]='TestPrintShopFlashSaleInfo'
  ;   upvals: _ENV
  ;   locals: self(0-279), aLastShopItem(0-279), arrITCount(0-279), directResult(30-279), codeCountMap(30-279), mapPool(31-279), mapDishResult(32-279), itemDataModel(34-279), (for generator)(37-58), (for state)(37-58), (for control)(37-58), directCode(38-56), count(38-56), mapMaterials(59-123), (for generator)(62-81), (for state)(62-81), (for control)(62-81), code(63-79), count(63-79), (for generator)(70-79), (for state)(70-79), (for control)(70-79), _(71-77), materialCode(71-77), tempDishResult(82-123), (for generator)(85-117), (for state)(85-117), (for control)(85-117), materialCode(86-115), count(86-115), lackedCount(91-115), mapWeight(124-279), mapNoBuyTarget(127-279), (for generator)(130-141), (for state)(130-141), (for control)(130-141), code(131-139), _(131-139), arrWeight(142-279), mapFinalWeight(143-279), index(144-279), mapNoSellItems(145-279), (for generator)(148-163), (for state)(148-163), (for control)(148-163), code(149-161), weight(149-161), arrResult(164-279), (for index)(167-200), (for limit)(167-200), (for step)(167-200), i(168-199), selected(175-199), index(175-199), arrPocketSelected(201-279), arrItems(206-258), index(207-258), (for generator)(210-225), (for state)(210-225), (for control)(210-225), code(211-223), price(211-223), (for generator)(236-258), (for state)(236-258), (for control)(236-258), _(237-256), code(237-256)
  0000  LEN       R3 = len R0
  0001  LE        if R0 le K0(0)   -> -129277
  0002  JMP       (jump)   -> 18
  0003  GETTABUP  R3 = _ENV[K1('GameConfig')]
  0004  GETTABLE  R3 = R3[K2('IsTestMode')]
  0005  CALL      R3 = call(R3, 1 args, 0 rets)
  0006  TEST      if not R3 then   -> -131064
  0007  JMP       (jump)   -> 16
  0008  GETTABUP  R3 = _ENV[K3('TestAccumulatedLogInfo')]
  0009  GETTABLE  R3 = R3[K4('LogNow')]
  0010  LOADK     R4 = K5 '--------------商城闪售刷新了----------------'
  0011  CALL      R3 = call(R3, 0 args, 1 rets)
  0012  GETTABUP  R3 = _ENV[K3('TestAccumulatedLogInfo')]
  0013  GETTABLE  R3 = R3[K4('LogNow')]
  0014  LOADK     R4 = K6 '商城闪售无需随机生成 IT 棋子'
  0015  CALL      R3 = call(R3, 0 args, 1 rets)
  0016  NEWTABLE  R3 = {} (0 items)
  0017  RETURN    return R3..R2
  0018  GETTABUP  R3 = _ENV[K1('GameConfig')]
  0019  GETTABLE  R3 = R3[K2('IsTestMode')]
  0020  CALL      R3 = call(R3, 1 args, 0 rets)
  0021  TEST      if not R3 then   -> -131049
  0022  JMP       (jump)   -> 26
  0023  GETTABUP  R3 = _ENV[K3('TestAccumulatedLogInfo')]
  0024  GETTABLE  R3 = R3[K7('Start')]
  0025  CALL      R3 = call(R3, 0 args, 0 rets)
  0026  GETTABUP  R3 = _ENV[K8('GM')]
  0027  GETTABLE  R3 = R3[K9('MainBoardModel')]
  0028  SELF      R4 = R3[K10('GetUnfilledDirectOrderRequirements')] (self)
  0029  CALL      R3 = call(R3, 2 args, 1 rets)
  0030  NEWTABLE  R5 = {} (0 items)
  0031  NEWTABLE  R6 = {} (0 items)
  0032  GETTABUP  R7 = _ENV[K8('GM')]
  0033  GETTABLE  R7 = R7[K11('ItemDataModel')]
  0034  GETTABUP  R8 = _ENV[K12('pairs')]
  0035  MOVE      R9 = R0
  0036  CALL      R8 = call(R8, 3 args, 1 rets)
  0037  JMP       (jump)   -> 56
  0038  SELF      R14 = R7[K13('IsDishes')] (self)
  0039  MOVE      R15 = R0
  0040  CALL      R13 = call(R13, 1 args, 2 rets)
  0041  TEST      if not R13 then   -> -131029
  0042  JMP       (jump)   -> 50
  0043  GETTABLE  R13 = R6[R11]
  0044  TEST      if not R13 then   -> -131025
  0045  JMP       (jump)   -> 47
  0046  LOADK     R13 = K0 0
  0047  ADD       R13 = R12 add R13
  0048  SETTABLE  R6[R11] = R13
  0049  JMP       (jump)   -> 56
  0050  GETTABLE  R13 = R5[R11]
  0051  TEST      if not R13 then   -> -131018
  0052  JMP       (jump)   -> 54
  0053  LOADK     R13 = K0 0
  0054  ADD       R13 = R12 add R13
  0055  SETTABLE  R5[R11] = R13
  0056  TFORCALL  tforcall R8
  0057  TFORLOOP  tforloop R10(sBx=-20)   -> 38
  0058  NEWTABLE  R8 = {} (0 items)
  0059  GETTABUP  R9 = _ENV[K12('pairs')]
  0060  MOVE      R10 = R0
  0061  CALL      R9 = call(R9, 3 args, 1 rets)
  0062  JMP       (jump)   -> 79
  0063  GETTABUP  R14 = _ENV[K14('ipairs')]
  0064  SELF      R16 = R7[K15('GetMaterials')] (self)
  0065  MOVE      R17 = R0
  0066  LOADBOOL  R18 = false
  0067  LOADBOOL  R19 = true
  0068  CALL      R15 = call(R15, -1 args, 4 rets)
  0069  CALL      R14 = call(R14, 3 args, -1 rets)
  0070  JMP       (jump)   -> 77
  0071  GETTABLE  R19 = R8[R18]
  0072  TEST      if not R19 then   -> -130997
  0073  JMP       (jump)   -> 75
  0074  LOADK     R19 = K0 0
  0075  ADD       R19 = R13 add R19
  0076  SETTABLE  R8[R18] = R19
  0077  TFORCALL  tforcall R14
  0078  TFORLOOP  tforloop R16(sBx=-8)   -> 71
  0079  TFORCALL  tforcall R9
  0080  TFORLOOP  tforloop R11(sBx=-18)   -> 63
  0081  NEWTABLE  R9 = {} (0 items)
  0082  GETTABUP  R10 = _ENV[K12('pairs')]
  0083  MOVE      R11 = R0
  0084  CALL      R10 = call(R10, 3 args, 1 rets)
  0085  JMP       (jump)   -> 115
  0086  SELF      R16 = R0[K16('_GetLackedCount')] (self)
  0087  MOVE      R17 = R0
  0088  MOVE      R18 = R0
  0089  MOVE      R19 = R0
  0090  CALL      R15 = call(R15, 1 args, 4 rets)
  0091  LT        if R0 lt R15   -> 108
  0092  JMP       (jump)   -> 115
  0093  SELF      R17 = R7[K13('IsDishes')] (self)
  0094  MOVE      R18 = R0
  0095  CALL      R16 = call(R16, 1 args, 2 rets)
  0096  TEST      if not R16 then   -> -130974
  0097  JMP       (jump)   -> 102
  0098  GETTABLE  R16 = R0[K17('m_mapItemPrice')]
  0099  GETTABLE  R16 = R16[R13]
  0100  TEST      if not R16 then   -> -130970
  0101  JMP       (jump)   -> 109
  0102  GETTABLE  R16 = R5[R13]
  0103  TEST      if not R16 then   -> -130966
  0104  JMP       (jump)   -> 106
  0105  LOADK     R16 = K0 0
  0106  ADD       R16 = R15 add R16
  0107  SETTABLE  R5[R13] = R16
  0108  JMP       (jump)   -> 115
  0109  GETTABLE  R16 = R9[R13]
  0110  TEST      if not R16 then   -> -130959
  0111  JMP       (jump)   -> 113
  0112  LOADK     R16 = K0 0
  0113  ADD       R16 = R14 add R16
  0114  SETTABLE  R9[R13] = R16
  0115  TFORCALL  tforcall R10
  0116  TFORLOOP  tforloop R12(sBx=-31)   -> 86
  0117  MOVE      R6 = R0
  0118  GETTABUP  R10 = _ENV[K18('next')]
  0119  MOVE      R11 = R0
  0120  CALL      R10 = call(R10, 1 args, 1 rets)
  0121  EQ        if R0 eq K19(nil)   -> -125554
  0122  JMP       (jump)   -> 58
  0123  NEWTABLE  R8 = {} (0 items)
  0124  SELF      R10 = R0[K20('GetShopLastNoBuyItem')] (self)
  0125  MOVE      R11 = R0
  0126  CALL      R9 = call(R9, 1 args, 2 rets)
  0127  GETTABUP  R10 = _ENV[K12('pairs')]
  0128  MOVE      R11 = R0
  0129  CALL      R10 = call(R10, 3 args, 1 rets)
  0130  JMP       (jump)   -> 139
  0131  SELF      R16 = R0[K21('_ExpandFlashSalePool')] (self)
  0132  MOVE      R17 = R0
  0133  MOVE      R18 = R0
  0134  MOVE      R19 = R0
  0135  MOVE      R20 = R0
  0136  LOADK     R21 = K22 128
  0137  LOADK     R22 = K23 1
  0138  CALL      R15 = call(R15, 0 args, 7 rets)
  0139  TFORCALL  tforcall R10
  0140  TFORLOOP  tforloop R12(sBx=-10)   -> 131
  0141  NEWTABLE  R10 = {} (0 items)
  0142  NEWTABLE  R11 = {} (0 items)
  0143  LOADK     R12 = K0 0
  0144  NEWTABLE  R13 = {} (0 items)
  0145  GETTABUP  R14 = _ENV[K12('pairs')]
  0146  MOVE      R15 = R0
  0147  CALL      R14 = call(R14, 3 args, 1 rets)
  0148  JMP       (jump)   -> 161
  0149  GETTABLE  R19 = R0[K17('m_mapItemPrice')]
  0150  GETTABLE  R19 = R19[R17]
  0151  TEST      if not R19 then   -> -130919
  0152  JMP       (jump)   -> 160
  0153  ADD       R12 = K23(1) add R12
  0154  NEWTABLE  R19 = {} (0 items)
  0155  SETTABLE  R19[K24('Code')] = R17
  0156  SETTABLE  R19[K25('Weight')] = R18
  0157  SETTABLE  R10[R12] = R19
  0158  SETTABLE  R11[R17] = R18
  0159  JMP       (jump)   -> 161
  0160  SETTABLE  R13[R17] = K26(true)
  0161  TFORCALL  tforcall R14
  0162  TFORLOOP  tforloop R16(sBx=-14)   -> 149
  0163  NEWTABLE  R14 = {} (0 items)
  0164  LOADK     R15 = K23 1
  0165  LEN       R16 = len R0
  0166  LOADK     R17 = K23 1
  0167  FORPREP   forprep R15(sBx=31)   -> 199
  0168  GETTABLE  R19 = R10[K23(1)]
  0169  TEST      if not R19 then   -> -130901
  0170  JMP       (jump)   -> 200
  0171  GETTABUP  R19 = _ENV[K27('Table')]
  0172  GETTABLE  R19 = R19[K28('ListWeightSelectOne')]
  0173  MOVE      R20 = R0
  0174  CALL      R19 = call(R19, 2 args, 1 rets)
  0175  TEST      if not R19 then   -> -130895
  0176  JMP       (jump)   -> 200
  0177  GETTABUP  R21 = _ENV[K29('table')]
  0178  GETTABLE  R21 = R21[K30('remove')]
  0179  MOVE      R22 = R0
  0180  MOVE      R23 = R0
  0181  CALL      R21 = call(R21, 0 args, 2 rets)
  0182  NEWTABLE  R21 = {} (0 items)
  0183  GETTABLE  R22 = R19[K24('Code')]
  0184  SETTABLE  R21[K31('itemCode')] = R22
  0185  GETTABLE  R22 = R2[R18]
  0186  SETTABLE  R21[K32('leftCount')] = R22
  0187  GETTABLE  R22 = R2[R18]
  0188  SETTABLE  R21[K33('startCount')] = R22
  0189  GETTABUP  R22 = _ENV[K35('EPropertyType')]
  0190  GETTABLE  R22 = R22[K36('Gem')]
  0191  SETTABLE  R21[K34('costType')] = R22
  0192  GETTABLE  R22 = R0[K17('m_mapItemPrice')]
  0193  GETTABLE  R23 = R19[K24('Code')]
  0194  GETTABLE  R22 = R22[R23]
  0195  SETTABLE  R21[K37('costCount')] = R22
  0196  SETTABLE  R14[R18] = R21
  0197  JMP       (jump)   -> 199
  0198  JMP       (jump)   -> 200
  0199  FORLOOP   forloop R15(sBx=-32)   -> 168
  0200  NEWTABLE  R15 = {} (0 items)
  0201  LEN       R16 = len R0
  0202  LEN       R17 = len R0
  0203  LT        if R0 lt R17   -> -122658
  0204  JMP       (jump)   -> 258
  0205  NEWTABLE  R16 = {} (0 items)
  0206  LOADK     R17 = K0 0
  0207  GETTABUP  R18 = _ENV[K12('pairs')]
  0208  GETTABLE  R19 = R0[K17('m_mapItemPrice')]
  0209  CALL      R18 = call(R18, 3 args, 1 rets)
  0210  JMP       (jump)   -> 223
  0211  LT        if R0 lt R22   -> 235
  0212  JMP       (jump)   -> 223
  0213  GETTABLE  R23 = R8[R21]
  0214  TEST      if not R23 then   -> -130855
  0215  JMP       (jump)   -> 223
  0216  SELF      R24 = R7[K38('IsUnlocked')] (self)
  0217  MOVE      R25 = R0
  0218  CALL      R23 = call(R23, 1 args, 2 rets)
  0219  TEST      if not R23 then   -> -130851
  0220  JMP       (jump)   -> 223
  0221  ADD       R17 = K23(1) add R17
  0222  SETTABLE  R16[R17] = R21
  0223  TFORCALL  tforcall R18
  0224  TFORLOOP  tforloop R20(sBx=-14)   -> 211
  0225  GETTABUP  R18 = _ENV[K27('Table')]
  0226  GETTABLE  R18 = R18[K39('ListRandomSelectN')]
  0227  MOVE      R19 = R0
  0228  LEN       R20 = len R0
  0229  LEN       R21 = len R0
  0230  SUB       R20 = R21 sub R20
  0231  CALL      R18 = call(R18, 1 args, 2 rets)
  0232  MOVE      R15 = R0
  0233  GETTABUP  R18 = _ENV[K14('ipairs')]
  0234  MOVE      R19 = R0
  0235  CALL      R18 = call(R18, 3 args, 1 rets)
  0236  JMP       (jump)   -> 256
  0237  LEN       R23 = len R0
  0238  ADD       R23 = K23(1) add R23
  0239  NEWTABLE  R24 = {} (0 items)
  0240  SETTABLE  R24[K31('itemCode')] = R22
  0241  LEN       R25 = len R0
  0242  ADD       R25 = K23(1) add R25
  0243  GETTABLE  R25 = R2[R25]
  0244  SETTABLE  R24[K32('leftCount')] = R25
  0245  LEN       R25 = len R0
  0246  ADD       R25 = K23(1) add R25
  0247  GETTABLE  R25 = R2[R25]
  0248  SETTABLE  R24[K33('startCount')] = R25
  0249  GETTABUP  R25 = _ENV[K35('EPropertyType')]
  0250  GETTABLE  R25 = R25[K36('Gem')]
  0251  SETTABLE  R24[K34('costType')] = R25
  0252  GETTABLE  R25 = R0[K17('m_mapItemPrice')]
  0253  GETTABLE  R25 = R25[R22]
  0254  SETTABLE  R24[K37('costCount')] = R25
  0255  SETTABLE  R14[R23] = R24
  0256  TFORCALL  tforcall R18
  0257  TFORLOOP  tforloop R20(sBx=-21)   -> 237
  0258  GETTABUP  R16 = _ENV[K1('GameConfig')]
  0259  GETTABLE  R16 = R16[K2('IsTestMode')]
  0260  CALL      R16 = call(R16, 1 args, 0 rets)
  0261  TEST      if not R16 then   -> -130809
  0262  JMP       (jump)   -> 277
  0263  GETTABUP  R16 = _ENV[K3('TestAccumulatedLogInfo')]
  0264  GETTABLE  R16 = R16[K40('TestPrintShopFlashSaleInfo')]
  0265  MOVE      R17 = R0
  0266  MOVE      R18 = R0
  0267  MOVE      R19 = R0
  0268  MOVE      R20 = R0
  0269  MOVE      R21 = R0
  0270  MOVE      R22 = R0
  0271  MOVE      R23 = R0
  0272  MOVE      R24 = R0
  0273  CALL      R16 = call(R16, 0 args, 8 rets)
  0274  GETTABUP  R16 = _ENV[K3('TestAccumulatedLogInfo')]
  0275  GETTABLE  R16 = R16[K4('LogNow')]
  0276  CALL      R16 = call(R16, 0 args, 0 rets)
  0277  RETURN    return R14..R13
  0278  RETURN    return R0..R-1
; ---------- proto16 [_ExpandFlashSalePool] ----------
  ; fn ?  line 348-382 np=7 va=0 ms=22 code=70 consts=11 upvals=2 protos=0
  ;   K[0]=0
  ;   K[1]=3
  ;   K[2]='IsDishes'
  ;   K[3]='ipairs'
  ;   K[4]='GetMaterials'
  ;   K[5]='_ExpandFlashSalePool'
  ;   K[6]=2
  ;   K[7]=1
  ;   K[8]='GetModelConfig'
  ;   K[9]='TransformFrom'
  ;   K[10]='MergedFromType'
  ;   upvals: nShopManualRefreshNoBuyItemMultiple, _ENV
  ;   locals: self(0-70), itemDataModel(0-70), mapWeight(0-70), mapNoBuyTarget(0-70), code(0-70), weight(0-70), level(0-70), saveWeight(4-70), newWeight(12-70), (for generator)(30-41), (for state)(30-41), (for control)(30-41), _(31-39), materialCode(31-39), itemConfig(45-70), transformFrom(46-70), mergeFrom(58-70)
  0000  GETTABLE  R7 = R2[R4]
  0001  TEST      if not R7 then   -> -131068
  0002  JMP       (jump)   -> 4
  0003  LOADK     R7 = K0 0
  0004  GETTABLE  R8 = R3[R4]
  0005  TEST      if not R8 then   -> -131065
  0006  JMP       (jump)   -> 11
  0007  GETUPVAL  R8 = nShopManualRefreshNoBuyItemMultiple
  0008  MUL       R8 = R8 mul R5
  0009  TEST      if not R8 then   -> -131060
  0010  JMP       (jump)   -> 12
  0011  MOVE      R8 = R0
  0012  LT        if R0 lt R8   -> -127466
  0013  JMP       (jump)   -> 15
  0014  SETTABLE  R2[R4] = R8
  0015  LE        if R0 le R6   -> 535
  0016  JMP       (jump)   -> 18
  0017  RETURN    return R0..R-1
  0018  SELF      R10 = R1[K2('IsDishes')] (self)
  0019  MOVE      R11 = R0
  0020  CALL      R9 = call(R9, 1 args, 2 rets)
  0021  TEST      if not R9 then   -> -131049
  0022  JMP       (jump)   -> 42
  0023  GETTABUP  R9 = _ENV[K3('ipairs')]
  0024  SELF      R11 = R1[K4('GetMaterials')] (self)
  0025  MOVE      R12 = R0
  0026  LOADBOOL  R13 = false
  0027  LOADBOOL  R14 = true
  0028  CALL      R10 = call(R10, -1 args, 4 rets)
  0029  CALL      R9 = call(R9, 3 args, -1 rets)
  0030  JMP       (jump)   -> 39
  0031  SELF      R15 = R0[K5('_ExpandFlashSalePool')] (self)
  0032  MOVE      R16 = R0
  0033  MOVE      R17 = R0
  0034  MOVE      R18 = R0
  0035  MOVE      R19 = R0
  0036  DIV       R20 = K6(2) div R5
  0037  ADD       R21 = K7(1) add R6
  0038  CALL      R14 = call(R14, 0 args, 7 rets)
  0039  TFORCALL  tforcall R9
  0040  TFORLOOP  tforloop R11(sBx=-10)   -> 31
  0041  RETURN    return R0..R-1
  0042  SELF      R10 = R1[K8('GetModelConfig')] (self)
  0043  MOVE      R11 = R0
  0044  CALL      R9 = call(R9, 1 args, 2 rets)
  0045  GETTABLE  R10 = R9[K9('TransformFrom')]
  0046  TEST      if not R10 then   -> -131024
  0047  JMP       (jump)   -> 57
  0048  SELF      R12 = R0[K5('_ExpandFlashSalePool')] (self)
  0049  MOVE      R13 = R0
  0050  MOVE      R14 = R0
  0051  MOVE      R15 = R0
  0052  MOVE      R16 = R0
  0053  DIV       R17 = K6(2) div R5
  0054  ADD       R18 = K7(1) add R6
  0055  CALL      R11 = call(R11, 0 args, 7 rets)
  0056  RETURN    return R0..R-1
  0057  GETTABLE  R11 = R9[K10('MergedFromType')]
  0058  TEST      if not R11 then   -> -131012
  0059  JMP       (jump)   -> 69
  0060  SELF      R13 = R0[K5('_ExpandFlashSalePool')] (self)
  0061  MOVE      R14 = R0
  0062  MOVE      R15 = R0
  0063  MOVE      R16 = R0
  0064  MOVE      R17 = R0
  0065  DIV       R18 = K6(2) div R5
  0066  ADD       R19 = K7(1) add R6
  0067  CALL      R12 = call(R12, 0 args, 7 rets)
  0068  RETURN    return R0..R-1
  0069  RETURN    return R0..R-1
; ---------- proto17 [GetShopLastNoBuyItem] ----------
  ; fn ?  line 386-396 np=2 va=0 ms=10 code=20 consts=7 upvals=1 protos=0
  ;   K[0]='pairs'
  ;   K[1]='tonumber'
  ;   K[2]='startCount'
  ;   K[3]=5
  ;   K[4]='leftCount'
  ;   K[5]='itemCode'
  ;   K[6]=true
  ;   upvals: _ENV
  ;   locals: self(0-20), aLastShopItem(0-20), mapNoBuyTarget(1-20), (for generator)(4-18), (for state)(4-18), (for control)(4-18), _(5-16), eleItemCfg(5-16), startCount(11-16)
  0000  NEWTABLE  R2 = {} (0 items)
  0001  GETTABUP  R3 = _ENV[K0('pairs')]
  0002  MOVE      R4 = R0
  0003  CALL      R3 = call(R3, 3 args, 1 rets)
  0004  JMP       (jump)   -> 16
  0005  GETTABUP  R8 = _ENV[K1('tonumber')]
  0006  GETTABLE  R9 = R7[K2('startCount')]
  0007  CALL      R8 = call(R8, 1 args, 1 rets)
  0008  TEST      if not R8 then   -> -131061
  0009  JMP       (jump)   -> 11
  0010  LOADK     R8 = K3 5
  0011  GETTABLE  R9 = R7[K4('leftCount')]
  0012  EQ        if R0 eq R9   -> -126953
  0013  JMP       (jump)   -> 16
  0014  GETTABLE  R9 = R7[K5('itemCode')]
  0015  SETTABLE  R2[R9] = K6(true)
  0016  TFORCALL  tforcall R3
  0017  TFORLOOP  tforloop R5(sBx=-13)   -> 5
  0018  RETURN    return R2..R1
  0019  RETURN    return R0..R-1
; ---------- proto18 [GetBuyEnergyCount] ----------
  ; fn ?  line 401-403 np=1 va=0 ms=2 code=3 consts=1 upvals=0 protos=0
  ;   K[0]=100
  ;   locals: self(0-3)
  0000  LOADK     R1 = K0 100
  0001  RETURN    return R1..R0
  0002  RETURN    return R0..R-1
; ---------- proto19 [GetBuyEnergyBaseGemCost] ----------
  ; fn ?  line 406-408 np=1 va=0 ms=4 code=11 consts=6 upvals=1 protos=0
  ;   K[0]='GM'
  ;   K[1]='SystemConfigModel'
  ;   K[2]='GetConfig'
  ;   K[3]='SystemConfigKey'
  ;   K[4]='BuyEnergyBaseGemPrice'
  ;   K[5]=10
  ;   upvals: _ENV
  ;   locals: self(0-11)
  0000  GETTABUP  R1 = _ENV[K0('GM')]
  0001  GETTABLE  R1 = R1[K1('SystemConfigModel')]
  0002  SELF      R2 = R1[K2('GetConfig')] (self)
  0003  GETTABUP  R3 = _ENV[K3('SystemConfigKey')]
  0004  GETTABLE  R3 = R3[K4('BuyEnergyBaseGemPrice')]
  0005  CALL      R1 = call(R1, 1 args, 2 rets)
  0006  TEST      if not R1 then   -> -131063
  0007  JMP       (jump)   -> 9
  0008  LOADK     R1 = K5 10
  0009  RETURN    return R1..R0
  0010  RETURN    return R0..R-1
; ---------- proto20 [GetMaxBuyEnergyGemCost] ----------
  ; fn ?  line 410-412 np=1 va=0 ms=4 code=11 consts=6 upvals=1 protos=0
  ;   K[0]='GM'
  ;   K[1]='SystemConfigModel'
  ;   K[2]='GetConfig'
  ;   K[3]='SystemConfigKey'
  ;   K[4]='BuyEnergyMaxGemPrice'
  ;   K[5]=40
  ;   upvals: _ENV
  ;   locals: self(0-11)
  0000  GETTABUP  R1 = _ENV[K0('GM')]
  0001  GETTABLE  R1 = R1[K1('SystemConfigModel')]
  0002  SELF      R2 = R1[K2('GetConfig')] (self)
  0003  GETTABUP  R3 = _ENV[K3('SystemConfigKey')]
  0004  GETTABLE  R3 = R3[K4('BuyEnergyMaxGemPrice')]
  0005  CALL      R1 = call(R1, 1 args, 2 rets)
  0006  TEST      if not R1 then   -> -131063
  0007  JMP       (jump)   -> 9
  0008  LOADK     R1 = K5 40
  0009  RETURN    return R1..R0
  0010  RETURN    return R0..R-1
; ---------- proto21 [GetBuyEnergyMultiplier] ----------
  ; fn ?  line 414-416 np=1 va=0 ms=4 code=11 consts=6 upvals=1 protos=0
  ;   K[0]='GM'
  ;   K[1]='SystemConfigModel'
  ;   K[2]='GetConfig'
  ;   K[3]='SystemConfigKey'
  ;   K[4]='BuyEnergyMultiplier'
  ;   K[5]=2
  ;   upvals: _ENV
  ;   locals: self(0-11)
  0000  GETTABUP  R1 = _ENV[K0('GM')]
  0001  GETTABLE  R1 = R1[K1('SystemConfigModel')]
  0002  SELF      R2 = R1[K2('GetConfig')] (self)
  0003  GETTABUP  R3 = _ENV[K3('SystemConfigKey')]
  0004  GETTABLE  R3 = R3[K4('BuyEnergyMultiplier')]
  0005  CALL      R1 = call(R1, 1 args, 2 rets)
  0006  TEST      if not R1 then   -> -131063
  0007  JMP       (jump)   -> 9
  0008  LOADK     R1 = K5 2
  0009  RETURN    return R1..R0
  0010  RETURN    return R0..R-1
; ---------- proto22 [GetNextBuyEnergyGemCost] ----------
  ; fn ?  line 419-422 np=2 va=0 ms=6 code=14 consts=5 upvals=1 protos=0
  ;   K[0]='math'
  ;   K[1]='min'
  ;   K[2]='GetMaxBuyEnergyGemCost'
  ;   K[3]='GetBuyEnergyMultiplier'
  ;   K[4]='ceil'
  ;   upvals: _ENV
  ;   locals: self(0-14), former(0-14), nextCost(8-14)
  0000  GETTABUP  R2 = _ENV[K0('math')]
  0001  GETTABLE  R2 = R2[K1('min')]
  0002  SELF      R4 = R0[K2('GetMaxBuyEnergyGemCost')] (self)
  0003  CALL      R3 = call(R3, 1 args, 1 rets)
  0004  SELF      R5 = R0[K3('GetBuyEnergyMultiplier')] (self)
  0005  CALL      R4 = call(R4, 1 args, 1 rets)
  0006  MUL       R4 = R4 mul R1
  0007  CALL      R2 = call(R2, 1 args, 2 rets)
  0008  GETTABUP  R3 = _ENV[K0('math')]
  0009  GETTABLE  R3 = R3[K4('ceil')]
  0010  MOVE      R4 = R0
  0011  TAILCALL  tailcall(R3, 0)
  0012  RETURN    return R3..R2
  0013  RETURN    return R0..R-1
; ---------- proto23 [GetConfigGemCostForItemType] ----------
  ; fn ?  line 426-428 np=2 va=0 ms=3 code=4 consts=1 upvals=0 protos=0
  ;   K[0]='m_mapItemPrice'
  ;   locals: self(0-4), itemType(0-4)
  0000  GETTABLE  R2 = R0[K0('m_mapItemPrice')]
  0001  GETTABLE  R2 = R2[R1]
  0002  RETURN    return R2..R1
  0003  RETURN    return R0..R-1
; ---------- proto24 [GetGemCostForItemType] ----------
  ; fn ?  line 433-477 np=2 va=0 ms=14 code=90 consts=19 upvals=1 protos=0
  ;   K[0]='GM'
  ;   K[1]='ItemDataModel'
  ;   K[2]='IsItemExist'
  ;   K[3]=99999
  ;   K[4]='GetChainLevel'
  ;   K[5]='m_mapItemPrice'
  ;   K[6]=0
  ;   K[7]=5
  ;   K[8]='IsDishes'
  ;   K[9]='GetMaterials'
  ;   K[10]='ipairs'
  ;   K[11]='GetGemCostForItemType'
  ;   K[12]='math'
  ;   K[13]='max'
  ;   K[14]=1
  ;   K[15]='GetChainId'
  ;   K[16]='_'
  ;   K[17]='ceil'
  ;   K[18]=2
  ;   upvals: _ENV
  ;   locals: self(0-90), itemType(0-90), level(14-90), price(16-90), total(34-59), materials(41-59), (for generator)(46-53), (for state)(46-53), (for control)(46-53), _(47-51), materialType(47-51), chainId(64-90), nextType(68-90)
  0000  GETTABUP  R2 = _ENV[K0('GM')]
  0001  GETTABLE  R2 = R2[K1('ItemDataModel')]
  0002  SELF      R3 = R2[K2('IsItemExist')] (self)
  0003  MOVE      R4 = R0
  0004  CALL      R2 = call(R2, 1 args, 2 rets)
  0005  TEST      if not R2 then   -> -131064
  0006  JMP       (jump)   -> 9
  0007  LOADK     R2 = K3 99999
  0008  RETURN    return R2..R1
  0009  GETTABUP  R2 = _ENV[K0('GM')]
  0010  GETTABLE  R2 = R2[K1('ItemDataModel')]
  0011  SELF      R3 = R2[K4('GetChainLevel')] (self)
  0012  MOVE      R4 = R0
  0013  CALL      R2 = call(R2, 1 args, 2 rets)
  0014  GETTABLE  R3 = R0[K5('m_mapItemPrice')]
  0015  GETTABLE  R3 = R3[R1]
  0016  TEST      if not R3 then   -> -131054
  0017  JMP       (jump)   -> 22
  0018  LT        if R0 lt R3   -> 3095
  0019  JMP       (jump)   -> 22
  0020  RETURN    return R3..R2
  0021  JMP       (jump)   -> 26
  0022  LT        if R0 lt R2   -> 3610
  0023  JMP       (jump)   -> 26
  0024  LOADK     R4 = K3 99999
  0025  RETURN    return R4..R3
  0026  GETTABUP  R4 = _ENV[K0('GM')]
  0027  GETTABLE  R4 = R4[K1('ItemDataModel')]
  0028  SELF      R5 = R4[K8('IsDishes')] (self)
  0029  MOVE      R6 = R0
  0030  CALL      R4 = call(R4, 1 args, 2 rets)
  0031  TEST      if not R4 then   -> -131039
  0032  JMP       (jump)   -> 59
  0033  LOADK     R4 = K6 0
  0034  GETTABUP  R5 = _ENV[K0('GM')]
  0035  GETTABLE  R5 = R5[K1('ItemDataModel')]
  0036  SELF      R6 = R5[K9('GetMaterials')] (self)
  0037  MOVE      R7 = R0
  0038  LOADBOOL  R8 = true
  0039  LOADBOOL  R9 = true
  0040  CALL      R5 = call(R5, 1 args, 4 rets)
  0041  GETTABUP  R6 = _ENV[K10('ipairs')]
  0042  TESTSET   if R1 then R7   -> -128467
  0043  JMP       (jump)   -> 45
  0044  NEWTABLE  R7 = {} (0 items)
  0045  CALL      R6 = call(R6, 3 args, 1 rets)
  0046  JMP       (jump)   -> 51
  0047  SELF      R12 = R0[K11('GetGemCostForItemType')] (self)
  0048  MOVE      R13 = R0
  0049  CALL      R11 = call(R11, 1 args, 2 rets)
  0050  ADD       R4 = R11 add R4
  0051  TFORCALL  tforcall R6
  0052  TFORLOOP  tforloop R8(sBx=-6)   -> 47
  0053  GETTABUP  R6 = _ENV[K12('math')]
  0054  GETTABLE  R6 = R6[K13('max')]
  0055  LOADK     R7 = K14 1
  0056  MOVE      R8 = R0
  0057  TAILCALL  tailcall(R6, 0)
  0058  RETURN    return R6..R5
  0059  GETTABUP  R4 = _ENV[K0('GM')]
  0060  GETTABLE  R4 = R4[K1('ItemDataModel')]
  0061  SELF      R5 = R4[K15('GetChainId')] (self)
  0062  MOVE      R6 = R0
  0063  CALL      R4 = call(R4, 1 args, 2 rets)
  0064  MOVE      R5 = R0
  0065  LOADK     R6 = K16 '_'
  0066  ADD       R7 = K14(1) add R2
  0067  CONCAT    R5 = concat(R5..R5)
  0068  GETTABUP  R6 = _ENV[K0('GM')]
  0069  GETTABLE  R6 = R6[K1('ItemDataModel')]
  0070  SELF      R7 = R6[K2('IsItemExist')] (self)
  0071  MOVE      R8 = R0
  0072  CALL      R6 = call(R6, 1 args, 2 rets)
  0073  TEST      if not R6 then   -> -130997
  0074  JMP       (jump)   -> 87
  0075  GETTABUP  R6 = _ENV[K12('math')]
  0076  GETTABLE  R6 = R6[K13('max')]
  0077  LOADK     R7 = K14 1
  0078  GETTABUP  R8 = _ENV[K12('math')]
  0079  GETTABLE  R8 = R8[K17('ceil')]
  0080  SELF      R10 = R0[K11('GetGemCostForItemType')] (self)
  0081  MOVE      R11 = R0
  0082  CALL      R9 = call(R9, 1 args, 2 rets)
  0083  DIV       R9 = K18(2) div R9
  0084  CALL      R8 = call(R8, -1 args, 1 rets)
  0085  TAILCALL  tailcall(R6, 0)
  0086  RETURN    return R6..R5
  0087  LOADK     R6 = K14 1
  0088  RETURN    return R6..R5
  0089  RETURN    return R0..R-1
