# RecipeCollectActivity_View_RecipeCollectActivityFinalRewardWindowTray_1909.luac
; fn @RecipeCollectActivityFinalRewardWindowTray.lua  line 0-0 np=0 va=1 ms=2 code=30 consts=10 upvals=1 protos=8
;   K[0]='RecipeCollectActivityFinalRewardWindowTray'
;   K[1]='__index'
;   K[2]='Init'
;   K[3]='_GetNextRecipe'
;   K[4]='OnDish1Appear'
;   K[5]='OnDish2Appear'
;   K[6]='OnDish3Appear'
;   K[7]='OnDish4Appear'
;   K[8]='OnDish5Appear'
;   K[9]='OnDish6Appear'
;   upvals: _ENV
0000  NEWTABLE  R0 = {} (0 items)
0001  SETTABUP  _ENV[K0('RecipeCollectActivityFinalRewardWindowTray')] = R0
0002  GETTABUP  R0 = _ENV[K0('RecipeCollectActivityFinalRewardWindowTray')]
0003  GETTABUP  R1 = _ENV[K0('RecipeCollectActivityFinalRewardWindowTray')]
0004  SETTABLE  R0[K1('__index')] = R1
0005  GETTABUP  R0 = _ENV[K0('RecipeCollectActivityFinalRewardWindowTray')]
0006  CLOSURE   R1 = closure proto0
0007  SETTABLE  R0[K2('Init')] = R1
0008  GETTABUP  R0 = _ENV[K0('RecipeCollectActivityFinalRewardWindowTray')]
0009  CLOSURE   R1 = closure proto1
0010  SETTABLE  R0[K3('_GetNextRecipe')] = R1
0011  GETTABUP  R0 = _ENV[K0('RecipeCollectActivityFinalRewardWindowTray')]
0012  CLOSURE   R1 = closure proto2
0013  SETTABLE  R0[K4('OnDish1Appear')] = R1
0014  GETTABUP  R0 = _ENV[K0('RecipeCollectActivityFinalRewardWindowTray')]
0015  CLOSURE   R1 = closure proto3
0016  SETTABLE  R0[K5('OnDish2Appear')] = R1
0017  GETTABUP  R0 = _ENV[K0('RecipeCollectActivityFinalRewardWindowTray')]
0018  CLOSURE   R1 = closure proto4
0019  SETTABLE  R0[K6('OnDish3Appear')] = R1
0020  GETTABUP  R0 = _ENV[K0('RecipeCollectActivityFinalRewardWindowTray')]
0021  CLOSURE   R1 = closure proto5
0022  SETTABLE  R0[K7('OnDish4Appear')] = R1
0023  GETTABUP  R0 = _ENV[K0('RecipeCollectActivityFinalRewardWindowTray')]
0024  CLOSURE   R1 = closure proto6
0025  SETTABLE  R0[K8('OnDish5Appear')] = R1
0026  GETTABUP  R0 = _ENV[K0('RecipeCollectActivityFinalRewardWindowTray')]
0027  CLOSURE   R1 = closure proto7
0028  SETTABLE  R0[K9('OnDish6Appear')] = R1
0029  RETURN    return R0..R-1
; ---------- proto0 [Init] ----------
  ; fn ?  line 16-29 np=2 va=0 ms=14 code=43 consts=16 upvals=1 protos=0
  ;   K[0]='m_model'
  ;   K[1]='m_arrRecipe'
  ;   K[2]=1
  ;   K[3]='GetTotalStage'
  ;   K[4]='GetStageConfig'
  ;   K[5]='GetTrayCount'
  ;   K[6]='GetTrayContent'
  ;   K[7]='GM'
  ;   K[8]='ItemDataModel'
  ;   K[9]='IsDishes'
  ;   K[10]='table'
  ;   K[11]='insert'
  ;   K[12]='Table'
  ;   K[13]='ListRandomReorder'
  ;   K[14]='m_index'
  ;   K[15]=0
  ;   upvals: _ENV
  ;   locals: self(0-43), model(0-43), (for index)(8-37), (for limit)(8-37), (for step)(8-37), stage(9-36), (for index)(17-36), (for limit)(17-36), (for step)(17-36), tray(18-35), content(23-35)
  0000  SETTABLE  R0[K0('m_model')] = R1
  0001  NEWTABLE  R2 = {} (0 items)
  0002  SETTABLE  R0[K1('m_arrRecipe')] = R2
  0003  LOADK     R2 = K2 1
  0004  GETTABLE  R3 = R0[K0('m_model')]
  0005  SELF      R4 = R3[K3('GetTotalStage')] (self)
  0006  CALL      R3 = call(R3, 1 args, 1 rets)
  0007  LOADK     R4 = K2 1
  0008  FORPREP   forprep R2(sBx=27)   -> 36
  0009  LOADK     R6 = K2 1
  0010  GETTABLE  R7 = R0[K0('m_model')]
  0011  SELF      R8 = R7[K4('GetStageConfig')] (self)
  0012  MOVE      R9 = R0
  0013  CALL      R7 = call(R7, 1 args, 2 rets)
  0014  SELF      R8 = R7[K5('GetTrayCount')] (self)
  0015  CALL      R7 = call(R7, 1 args, 1 rets)
  0016  LOADK     R8 = K2 1
  0017  FORPREP   forprep R6(sBx=17)   -> 35
  0018  GETTABLE  R10 = R0[K0('m_model')]
  0019  SELF      R11 = R10[K6('GetTrayContent')] (self)
  0020  MOVE      R12 = R0
  0021  MOVE      R13 = R0
  0022  CALL      R10 = call(R10, 1 args, 3 rets)
  0023  GETTABUP  R11 = _ENV[K7('GM')]
  0024  GETTABLE  R11 = R11[K8('ItemDataModel')]
  0025  SELF      R12 = R11[K9('IsDishes')] (self)
  0026  MOVE      R13 = R0
  0027  CALL      R11 = call(R11, 1 args, 2 rets)
  0028  TEST      if not R11 then   -> -131042
  0029  JMP       (jump)   -> 35
  0030  GETTABUP  R11 = _ENV[K10('table')]
  0031  GETTABLE  R11 = R11[K11('insert')]
  0032  GETTABLE  R12 = R0[K1('m_arrRecipe')]
  0033  MOVE      R13 = R0
  0034  CALL      R11 = call(R11, 0 args, 2 rets)
  0035  FORLOOP   forloop R6(sBx=-18)   -> 18
  0036  FORLOOP   forloop R2(sBx=-28)   -> 9
  0037  GETTABUP  R2 = _ENV[K12('Table')]
  0038  GETTABLE  R2 = R2[K13('ListRandomReorder')]
  0039  GETTABLE  R3 = R0[K1('m_arrRecipe')]
  0040  CALL      R2 = call(R2, 0 args, 1 rets)
  0041  SETTABLE  R0[K14('m_index')] = K15(0)
  0042  RETURN    return R0..R-1
; ---------- proto1 [_GetNextRecipe] ----------
  ; fn ?  line 31-34 np=1 va=0 ms=3 code=11 consts=3 upvals=0 protos=0
  ;   K[0]='m_index'
  ;   K[1]='m_arrRecipe'
  ;   K[2]=1
  ;   locals: self(0-11)
  0000  GETTABLE  R1 = R0[K0('m_index')]
  0001  GETTABLE  R2 = R0[K1('m_arrRecipe')]
  0002  LEN       R2 = len R0
  0003  MOD       R1 = R2 mod R1
  0004  ADD       R1 = K2(1) add R1
  0005  SETTABLE  R0[K0('m_index')] = R1
  0006  GETTABLE  R1 = R0[K1('m_arrRecipe')]
  0007  GETTABLE  R2 = R0[K0('m_index')]
  0008  GETTABLE  R1 = R1[R2]
  0009  RETURN    return R1..R0
  0010  RETURN    return R0..R-1
; ---------- proto2 [OnDish1Appear] ----------
  ; fn ?  line 36-39 np=1 va=0 ms=5 code=10 consts=6 upvals=1 protos=0
  ;   K[0]='m_dish1Image'
  ;   K[1]='enabled'
  ;   K[2]=false
  ;   K[3]='SpriteUtil'
  ;   K[4]='SetImage'
  ;   K[5]='_GetNextRecipe'
  ;   upvals: _ENV
  ;   locals: self(0-10)
  0000  GETTABLE  R1 = R0[K0('m_dish1Image')]
  0001  SETTABLE  R1[K1('enabled')] = K2(false)
  0002  GETTABUP  R1 = _ENV[K3('SpriteUtil')]
  0003  GETTABLE  R1 = R1[K4('SetImage')]
  0004  GETTABLE  R2 = R0[K0('m_dish1Image')]
  0005  SELF      R4 = R0[K5('_GetNextRecipe')] (self)
  0006  CALL      R3 = call(R3, 1 args, 1 rets)
  0007  LOADBOOL  R4 = true
  0008  CALL      R1 = call(R1, 0 args, 3 rets)
  0009  RETURN    return R0..R-1
; ---------- proto3 [OnDish2Appear] ----------
  ; fn ?  line 41-44 np=1 va=0 ms=5 code=10 consts=6 upvals=1 protos=0
  ;   K[0]='m_dish2Image'
  ;   K[1]='enabled'
  ;   K[2]=false
  ;   K[3]='SpriteUtil'
  ;   K[4]='SetImage'
  ;   K[5]='_GetNextRecipe'
  ;   upvals: _ENV
  ;   locals: self(0-10)
  0000  GETTABLE  R1 = R0[K0('m_dish2Image')]
  0001  SETTABLE  R1[K1('enabled')] = K2(false)
  0002  GETTABUP  R1 = _ENV[K3('SpriteUtil')]
  0003  GETTABLE  R1 = R1[K4('SetImage')]
  0004  GETTABLE  R2 = R0[K0('m_dish2Image')]
  0005  SELF      R4 = R0[K5('_GetNextRecipe')] (self)
  0006  CALL      R3 = call(R3, 1 args, 1 rets)
  0007  LOADBOOL  R4 = true
  0008  CALL      R1 = call(R1, 0 args, 3 rets)
  0009  RETURN    return R0..R-1
; ---------- proto4 [OnDish3Appear] ----------
  ; fn ?  line 46-49 np=1 va=0 ms=5 code=10 consts=6 upvals=1 protos=0
  ;   K[0]='m_dish3Image'
  ;   K[1]='enabled'
  ;   K[2]=false
  ;   K[3]='SpriteUtil'
  ;   K[4]='SetImage'
  ;   K[5]='_GetNextRecipe'
  ;   upvals: _ENV
  ;   locals: self(0-10)
  0000  GETTABLE  R1 = R0[K0('m_dish3Image')]
  0001  SETTABLE  R1[K1('enabled')] = K2(false)
  0002  GETTABUP  R1 = _ENV[K3('SpriteUtil')]
  0003  GETTABLE  R1 = R1[K4('SetImage')]
  0004  GETTABLE  R2 = R0[K0('m_dish3Image')]
  0005  SELF      R4 = R0[K5('_GetNextRecipe')] (self)
  0006  CALL      R3 = call(R3, 1 args, 1 rets)
  0007  LOADBOOL  R4 = true
  0008  CALL      R1 = call(R1, 0 args, 3 rets)
  0009  RETURN    return R0..R-1
; ---------- proto5 [OnDish4Appear] ----------
  ; fn ?  line 51-54 np=1 va=0 ms=5 code=10 consts=6 upvals=1 protos=0
  ;   K[0]='m_dish4Image'
  ;   K[1]='enabled'
  ;   K[2]=false
  ;   K[3]='SpriteUtil'
  ;   K[4]='SetImage'
  ;   K[5]='_GetNextRecipe'
  ;   upvals: _ENV
  ;   locals: self(0-10)
  0000  GETTABLE  R1 = R0[K0('m_dish4Image')]
  0001  SETTABLE  R1[K1('enabled')] = K2(false)
  0002  GETTABUP  R1 = _ENV[K3('SpriteUtil')]
  0003  GETTABLE  R1 = R1[K4('SetImage')]
  0004  GETTABLE  R2 = R0[K0('m_dish4Image')]
  0005  SELF      R4 = R0[K5('_GetNextRecipe')] (self)
  0006  CALL      R3 = call(R3, 1 args, 1 rets)
  0007  LOADBOOL  R4 = true
  0008  CALL      R1 = call(R1, 0 args, 3 rets)
  0009  RETURN    return R0..R-1
; ---------- proto6 [OnDish5Appear] ----------
  ; fn ?  line 56-59 np=1 va=0 ms=5 code=10 consts=6 upvals=1 protos=0
  ;   K[0]='m_dish5Image'
  ;   K[1]='enabled'
  ;   K[2]=false
  ;   K[3]='SpriteUtil'
  ;   K[4]='SetImage'
  ;   K[5]='_GetNextRecipe'
  ;   upvals: _ENV
  ;   locals: self(0-10)
  0000  GETTABLE  R1 = R0[K0('m_dish5Image')]
  0001  SETTABLE  R1[K1('enabled')] = K2(false)
  0002  GETTABUP  R1 = _ENV[K3('SpriteUtil')]
  0003  GETTABLE  R1 = R1[K4('SetImage')]
  0004  GETTABLE  R2 = R0[K0('m_dish5Image')]
  0005  SELF      R4 = R0[K5('_GetNextRecipe')] (self)
  0006  CALL      R3 = call(R3, 1 args, 1 rets)
  0007  LOADBOOL  R4 = true
  0008  CALL      R1 = call(R1, 0 args, 3 rets)
  0009  RETURN    return R0..R-1
; ---------- proto7 [OnDish6Appear] ----------
  ; fn ?  line 61-64 np=1 va=0 ms=5 code=10 consts=6 upvals=1 protos=0
  ;   K[0]='m_dish6Image'
  ;   K[1]='enabled'
  ;   K[2]=false
  ;   K[3]='SpriteUtil'
  ;   K[4]='SetImage'
  ;   K[5]='_GetNextRecipe'
  ;   upvals: _ENV
  ;   locals: self(0-10)
  0000  GETTABLE  R1 = R0[K0('m_dish6Image')]
  0001  SETTABLE  R1[K1('enabled')] = K2(false)
  0002  GETTABUP  R1 = _ENV[K3('SpriteUtil')]
  0003  GETTABLE  R1 = R1[K4('SetImage')]
  0004  GETTABLE  R2 = R0[K0('m_dish6Image')]
  0005  SELF      R4 = R0[K5('_GetNextRecipe')] (self)
  0006  CALL      R3 = call(R3, 1 args, 1 rets)
  0007  LOADBOOL  R4 = true
  0008  CALL      R1 = call(R1, 0 args, 3 rets)
  0009  RETURN    return R0..R-1
