# CoinRaceActivity_View_CoinRaceCompleteWindow_900.luac
; fn @CoinRaceCompleteWindow.lua  line 0-0 np=0 va=1 ms=3 code=20 consts=7 upvals=1 protos=2
;   K[0]='CoinRaceCompleteWindow'
;   K[1]='setmetatable'
;   K[2]='BaseWindow'
;   K[3]='__index'
;   K[4]='Init'
;   K[5]='CoinRaceMedal'
;   K[6]='Init'
;   upvals: _ENV
0000  GETTABUP  R0 = _ENV[K1('setmetatable')]
0001  NEWTABLE  R1 = {} (0 items)
0002  GETTABUP  R2 = _ENV[K2('BaseWindow')]
0003  CALL      R0 = call(R0, 1 args, 2 rets)
0004  SETTABUP  _ENV[K0('CoinRaceCompleteWindow')] = R0
0005  GETTABUP  R0 = _ENV[K0('CoinRaceCompleteWindow')]
0006  GETTABUP  R1 = _ENV[K0('CoinRaceCompleteWindow')]
0007  SETTABLE  R0[K3('__index')] = R1
0008  GETTABUP  R0 = _ENV[K0('CoinRaceCompleteWindow')]
0009  CLOSURE   R1 = closure proto0
0010  SETTABLE  R0[K4('Init')] = R1
0011  NEWTABLE  R0 = {} (0 items)
0012  SETTABUP  _ENV[K5('CoinRaceMedal')] = R0
0013  GETTABUP  R0 = _ENV[K5('CoinRaceMedal')]
0014  GETTABUP  R1 = _ENV[K5('CoinRaceMedal')]
0015  SETTABLE  R0[K3('__index')] = R1
0016  GETTABUP  R0 = _ENV[K5('CoinRaceMedal')]
0017  CLOSURE   R1 = closure proto1
0018  SETTABLE  R0[K6('Init')] = R1
0019  RETURN    return R0..R-1
; ---------- proto0 [Init] ----------
  ; fn ?  line 4-34 np=2 va=0 ms=16 code=94 consts=34 upvals=1 protos=0
  ;   K[0]='GM'
  ;   K[1]='ActivityManager'
  ;   K[2]='GetModel'
  ;   K[3]='SetWindowOpened'
  ;   K[4]='GetRoundCount'
  ;   K[5]=1
  ;   K[6]='GetRoundRanks'
  ;   K[7]=5
  ;   K[8]='table'
  ;   K[9]='insert'
  ;   K[10]='Table'
  ;   K[11]='IsEmpty'
  ;   K[12]='m_medalGo'
  ;   K[13]='SetActive'
  ;   K[14]='UIUtil'
  ;   K[15]='m_medalBgGo2'
  ;   K[16]=8
  ;   K[17]='ipairs'
  ;   K[18]='m_medal'
  ;   K[19]='GetLuaTable'
  ;   K[20]='Object'
  ;   K[21]='Instantiate'
  ;   K[22]='transform'
  ;   K[23]='m_medalBgGo'
  ;   K[24]='Init'
  ;   K[25]='LayoutRebuilder'
  ;   K[26]='ForceRebuildLayoutImmediate'
  ;   K[27]='m_medalBgTransf'
  ;   K[28]='LogWindowAction'
  ;   K[29]='EBIType'
  ;   K[30]='UIActionType'
  ;   K[31]='Open'
  ;   K[32]='EBIReferType'
  ;   K[33]='AutoPopup'
  ;   upvals: _ENV
  ;   locals: self(0-94), activityType(0-94), model(5-94), roundCnt(9-94), arrMedal(10-94), (for index)(13-27), (for limit)(13-27), (for step)(13-27), i(14-26), rank(17-26), bMedal(32-94), luaTable(48-84), (for generator)(51-80), (for state)(51-80), (for control)(51-80), index(52-78), value(52-78)
  0000  GETTABUP  R2 = _ENV[K0('GM')]
  0001  GETTABLE  R2 = R2[K1('ActivityManager')]
  0002  SELF      R3 = R2[K2('GetModel')] (self)
  0003  MOVE      R4 = R0
  0004  CALL      R2 = call(R2, 1 args, 2 rets)
  0005  SELF      R4 = R2[K3('SetWindowOpened')] (self)
  0006  CALL      R3 = call(R3, 0 args, 1 rets)
  0007  SELF      R4 = R2[K4('GetRoundCount')] (self)
  0008  CALL      R3 = call(R3, 1 args, 1 rets)
  0009  NEWTABLE  R4 = {} (0 items)
  0010  LOADK     R5 = K5 1
  0011  MOVE      R6 = R0
  0012  LOADK     R7 = K5 1
  0013  FORPREP   forprep R5(sBx=12)   -> 26
  0014  SELF      R10 = R2[K6('GetRoundRanks')] (self)
  0015  MOVE      R11 = R0
  0016  CALL      R9 = call(R9, 1 args, 2 rets)
  0017  TEST      if not R9 then   -> -131053
  0018  JMP       (jump)   -> 26
  0019  LE        if R0 le K7(5)   -> -126180
  0020  JMP       (jump)   -> 26
  0021  GETTABUP  R10 = _ENV[K8('table')]
  0022  GETTABLE  R10 = R10[K9('insert')]
  0023  MOVE      R11 = R0
  0024  MOVE      R12 = R0
  0025  CALL      R10 = call(R10, 0 args, 2 rets)
  0026  FORLOOP   forloop R5(sBx=-13)   -> 14
  0027  GETTABUP  R5 = _ENV[K10('Table')]
  0028  GETTABLE  R5 = R5[K11('IsEmpty')]
  0029  MOVE      R6 = R0
  0030  CALL      R5 = call(R5, 1 args, 1 rets)
  0031  NOT       R5 = not R0
  0032  GETTABLE  R6 = R0[K12('m_medalGo')]
  0033  SELF      R7 = R6[K13('SetActive')] (self)
  0034  MOVE      R8 = R0
  0035  CALL      R6 = call(R6, 0 args, 2 rets)
  0036  TEST      if not R5 then   -> -131034
  0037  JMP       (jump)   -> 84
  0038  GETTABUP  R6 = _ENV[K14('UIUtil')]
  0039  GETTABLE  R6 = R6[K13('SetActive')]
  0040  GETTABLE  R7 = R0[K15('m_medalBgGo2')]
  0041  LEN       R8 = len R0
  0042  LT        if R1 lt R8   -> 8244
  0043  JMP       (jump)   -> 45
  0044  LOADBOOL  R8 = false
  0045  LOADBOOL  R8 = true
  0046  CALL      R6 = call(R6, 0 args, 2 rets)
  0047  LOADNIL   R6..R6 = nil
  0048  GETTABUP  R7 = _ENV[K17('ipairs')]
  0049  MOVE      R8 = R0
  0050  CALL      R7 = call(R7, 3 args, 1 rets)
  0051  JMP       (jump)   -> 78
  0052  EQ        if R0 eq K5(1)   -> -125637
  0053  JMP       (jump)   -> 59
  0054  GETTABLE  R12 = R0[K18('m_medal')]
  0055  SELF      R13 = R12[K19('GetLuaTable')] (self)
  0056  CALL      R12 = call(R12, 1 args, 1 rets)
  0057  MOVE      R6 = R0
  0058  JMP       (jump)   -> 74
  0059  GETTABUP  R12 = _ENV[K20('Object')]
  0060  GETTABLE  R12 = R12[K21('Instantiate')]
  0061  GETTABLE  R13 = R0[K18('m_medal')]
  0062  LT        if R0 lt R10   -> 8266
  0063  JMP       (jump)   -> 68
  0064  GETTABLE  R14 = R0[K15('m_medalBgGo2')]
  0065  GETTABLE  R14 = R14[K22('transform')]
  0066  TEST      if not R14 then   -> -131003
  0067  JMP       (jump)   -> 70
  0068  GETTABLE  R14 = R0[K23('m_medalBgGo')]
  0069  GETTABLE  R14 = R14[K22('transform')]
  0070  CALL      R12 = call(R12, 1 args, 2 rets)
  0071  SELF      R13 = R12[K19('GetLuaTable')] (self)
  0072  CALL      R12 = call(R12, 1 args, 1 rets)
  0073  MOVE      R6 = R0
  0074  SELF      R13 = R6[K24('Init')] (self)
  0075  MOVE      R14 = R0
  0076  MOVE      R15 = R0
  0077  CALL      R12 = call(R12, 0 args, 3 rets)
  0078  TFORCALL  tforcall R7
  0079  TFORLOOP  tforloop R9(sBx=-28)   -> 52
  0080  GETTABUP  R7 = _ENV[K25('LayoutRebuilder')]
  0081  GETTABLE  R7 = R7[K26('ForceRebuildLayoutImmediate')]
  0082  GETTABLE  R8 = R0[K27('m_medalBgTransf')]
  0083  CALL      R7 = call(R7, 0 args, 1 rets)
  0084  SELF      R7 = R0[K28('LogWindowAction')] (self)
  0085  GETTABUP  R8 = _ENV[K29('EBIType')]
  0086  GETTABLE  R8 = R8[K30('UIActionType')]
  0087  GETTABLE  R8 = R8[K31('Open')]
  0088  NEWTABLE  R9 = {} (1 items)
  0089  GETTABUP  R10 = _ENV[K32('EBIReferType')]
  0090  GETTABLE  R10 = R10[K33('AutoPopup')]
  0091  SETLIST   setlist R9[B=1,C=1]
  0092  CALL      R6 = call(R6, 0 args, 3 rets)
  0093  RETURN    return R0..R-1
; ---------- proto1 [Init] ----------
  ; fn ?  line 40-45 np=3 va=0 ms=8 code=16 consts=7 upvals=1 protos=0
  ;   K[0]=0
  ;   K[1]=5
  ;   K[2]='CoinRaceActivityDefinition'
  ;   K[3]='CoinRaceBoardEntryRankImgPrefix'
  ;   K[4]='SpriteUtil'
  ;   K[5]='SetImage'
  ;   K[6]='m_medalImg'
  ;   upvals: _ENV
  ;   locals: self(0-16), rank(0-16), activityType(0-16), prefix(7-15)
  0000  LT        if R0 lt R1   -> 3
  0001  JMP       (jump)   -> 15
  0002  LE        if R0 le K1(5)   -> -130299
  0003  JMP       (jump)   -> 15
  0004  GETTABUP  R3 = _ENV[K2('CoinRaceActivityDefinition')]
  0005  GETTABLE  R3 = R3[R2]
  0006  GETTABLE  R3 = R3[K3('CoinRaceBoardEntryRankImgPrefix')]
  0007  GETTABUP  R4 = _ENV[K4('SpriteUtil')]
  0008  GETTABLE  R4 = R4[K5('SetImage')]
  0009  GETTABLE  R5 = R0[K6('m_medalImg')]
  0010  MOVE      R6 = R0
  0011  MOVE      R7 = R0
  0012  CONCAT    R6 = concat(R6..R6)
  0013  LOADBOOL  R7 = true
  0014  CALL      R4 = call(R4, 0 args, 3 rets)
  0015  RETURN    return R0..R-1
