"Enable" 1080 1920 "0xEAE6E1" SoundVolume Var Timeout = 0 Var TelephoneNumber = TelephoneNumberX Var Seeker.TNumberTaobinMember = TelephoneNumber DEBUGVAR TelephoneNumber DEBUGVAR TelephoneNumberX Var DirImage = "ROOT/taobin_project/image/event/lent_day/" If show_eng = "true" Then Var IMG_CNT = "ROOT/taobin_project/image/page_doing/img2_eng.png" Else Var IMG_CNT = "ROOT/taobin_project/image/page_doing/img2.png" EndIf Var FullLentState = "Invisible" Var CurrentPriceTextState = "Invisible" Var GIFAnimationState = "Invisible" DEBUGVAR TotalPrice DEBUGVAR PayAmount Var TotalPriceAfterAdded = TotalPrice + PayAmount Var PriceToShow = "฿" + TotalPriceAfterAdded Var PriceToShow = PriceToShow + "->" Var LentMinY = 1740 Var LentMaxY = 1076 Var MaxPrice = 350 Var LentSize = LentMinY - LentMaxY Var StartPriceDy = TotalPrice * 100 Var StartPriceDy = StartPriceDy / MaxPrice Var PositionStart = StartPriceDy * LentSize Var PositionStart = PositionStart / 100 Var PositionStart = LentMinY - PositionStart If PositionStart < LentMaxY Then PositionStart = LentMaxY EndIf Var LentPositionY = PositionStart Var TargetPriceDy = TotalPriceAfterAdded * 100 Var TargetPriceDy = TargetPriceDy / MaxPrice Var PositionTarget = TargetPriceDy * LentSize Var PositionTarget = PositionTarget / 100 Var PositionTarget = LentMinY - PositionTarget If PositionTarget < LentMaxY Then PositionTarget = LentMaxY EndIf Var PositionDiff = PositionStart - PositionTarget Var TimeScopeSec = 0 Var AmountIncrease = 0 Var PourAnimationDelaySec = 0 If PositionDiff > 0 Then Var TimeScopeSec = 7 Var AmountIncrease = 0 - PositionDiff Var AmountIncrease = AmountIncrease / TimeScopeSec Var PourAnimationDelaySec = 1 Var GIFAnimationState = "Enable" EndIf Var MaxTimeout = TimeScopeSec + PourAnimationDelaySec Var MaxTimeout = MaxTimeout + 5 DEBUGVAR LentSize DEBUGVAR PositionStart DEBUGVAR PositionTarget DEBUGVAR AmountIncrease DEBUGVAR LentPositionY DEBUGVAR MaxTimeout Var val1 = "+" Var val2 = PayAmount Var val3 = "X" AddData 58 TelephoneNumber val1 val2 val3 1000 Var CountDownBrewing = BREW_CNT Var ShowCountDownBrewing = CountDownBrewing Var Timeout = Timeout + 1 If Timeout > MaxTimeout Then If TotalPriceAfterAdded >= 350 Then Open "ROOT/taobin_project/xml/event/lent_day/page_collect_lent_send_code.xml" EndIf If TotalPriceAfterAdded >= 175 Then Open "ROOT/taobin_project/xml/event/lent_day/page_collect_lent_redeem_or_continue.xml" EndIf If Seeker.CodeChannel = 1 Then If Seeker.CollectPointMain = 1 Then GETACCEXT Param1 23 Open "ROOT/taobin_project/xml/page_collect_point_2.xml" Else Open "ROOT/taobin_project/xml/page_lid_straw.xml" EndIf Else GETACCEXT Param1 23 Open "ROOT/taobin_project/xml/page_collect_point_2.xml" EndIf EndIf If PourAnimationDelaySec > 0 Then Var PourAnimationDelaySec = PourAnimationDelaySec - 1 Else If TimeScopeSec > 0 Then Var LentPositionY = LentPositionY + AmountIncrease DEBUGVAR LentPositionY Var TimeScopeSec = TimeScopeSec - 1 Else If TotalPriceAfterAdded >= 350 Then Var FullLentState = "Enable" Var CurrentPriceTextState = "Invisible" EndIf Var GIFAnimationState = "Invisible" EndIf EndIf Refresh TimerReset Open "/media/bt/xml/security_alarm.xml" If MachineStage = "drink-success" Then Var MachineState_Result = 1 EndIf If MachineStage = "drink-failed" Then Var MachineState_Result = 2 EndIf ;include="ROOT/taobin_project/inc/video.inc" 0 380 Var( DirImage + "/layer1.png" ) 90 760 800 333 GIFAnimationState ; "OneShot,StopFrame=182" Var( DirImage + "pour_animation.gif" ) 361 LentPositionY 340 714 Var( DirImage + "/layer2.png" ) 0 1076 Var( DirImage + "/layer3.png" ) 363 1076 Var( DirImage + "/layer4.png" ) 325 PositionTarget CurrentPriceTextState 150 32 KanitTTF 0x523D30 PriceToShow 363 821 FullLentState Var( DirImage + "/lent.png" ) 658 990 Var( DirImage + "/collecting_level.png" ) 751 413 IMG_CNT XPosiShowCountDownBrew 470 End 153 88 RobotoBold 0x513C2F ShowCountDownBrewing "Reload File" Var MaxTimeout = 5