"Enable" 1080 1920 ; "0xeae6e1" SoundVolume OpenInst 1 "/mnt/sdcard/coffeevending/taobin_project/xml/page_advert.xml" If RedirectToNormalVersion = 1 Then RootLayoutVisible 3 "hide" ;include="ROOT/taobin_project/inter/tha/xml/multi/tab_menu_hide.lxml" EndIf Machine WakeUp ;for 3 langs If show_eng = "true" Then If LanguageShow = "MYANMAR" Then SetLanguage "MYANMAR" Else SetLanguage "ENG" EndIf Else SetLanguage "THAI" EndIf Var TextSelfTestCntColor = "0x746253" Var UserSeletedSugar = 0 SAVELOG "Event Open Select 8" If NoWaitMachineEnable = 1 Then Var ConfirmDrinkButtonState = "Enable" Else Var ConfirmDrinkButtonState = "Invisible" EndIf Var y_topping_bg = 912 Var CHECK_EventOpen_Double = CHECK_EventOpen_Double + 1 If CHECK_EventOpen_Double > 1 Then WRITE_FILE "/mnt/sdcard/xml_alert_bug" "double called" EndIf WEB "DISABLE" DEBUGVAR Seeker Var BGSugarNew = "Invisible" Var BGMilkNew = "Invisible" DEBUGVAR video_menu_0 DEBUGVAR SelectDrink DEBUGVAR PictureDrink Var DisableAllNotFreeTopping = 0 Var SaveProductCodeSelect = "-" Var UserSelectProductCode = "-" Var showText4 = "Invisible" Var showText7 = "Invisible" DEBUGVAR UserSelectProductCode Var blendedState = "Enable" Var DisableUsingCode = "false" Var ShowLidStraw = "Invisible" Var ShowLidOnly = "Invisible" Var ShowCollagenOnly = "Invisible" Var blendedStateShow = "Invisible" Var ShotCoffeeBG = "Invisible" Var showShotEnable = "Invisible" Var ShowLidStraw = "Invisible" Var ShowStrawOnly = "Invisible" Var ShowLidOnly = "Invisible" Var ShowNormalNextButton = "Enable" ; On open Var lidAndStrawOldPageIgnore = "true" Var SugarState1 = "Invisible" Var SugarState2 = "Invisible" Var SugarState3 = "Invisible" Var SugarState4 = "Invisible" Var SugarState5 = "Invisible" Var SugarState6 = "Invisible" Var AddShotEnable = "Invisible" Var BGSugar = "Invisible" Var ShotCoffeeBG = "Invisible" Var showShotEnable = "Invisible" Var ShotCoffeePremium = "Invisible" Var showCustomCoffee = "Invisible" Var showOvaltineEnable = "Invisible" Var showOreoAddEnable = "Invisible" Var showCocoaEnable = "Invisible" Var showJemilaEnable = "Invisible" Var showStrawberryEnable = "Invisible" Var showYuzuEnable = "Invisible" Var SpecialMix = "Invisible" Var CustomSyrup = "Invisible" ; Customer Coffee Var CustomCoffeeEnable = "False" Var EnableLightRoast = "Disable" Var showCoffeeWater = "Invisible" Var showSweetLevel = "Invisible" Var showCoffeeQuantity = "Invisible" Var showCoffeeLevel = "Invisible" Var showCoffeeTamping = "Invisible" ; States Var CustomCoffeeWaterState[0] = "Enable" Var CustomCoffeeWaterState[1] = "Enable" Var CustomCoffeeWaterState[2] = "Enable" Var CustomCoffeeWaterState[3] = "Enable" Var CustomCoffeeWaterState[4] = "Enable" Var CustomCoffeeQuantityState[0] = "Enable" Var CustomCoffeeQuantityState[1] = "Enable" Var CustomCoffeeQuantityState[2] = "Enable" Var CustomCoffeeLevelState[0] = "Enable" Var CustomCoffeeLevelState[1] = "Enable" Var CustomCoffeeLevelState[2] = "Enable" Var CustomCoffeeLevelState[3] = "Enable" Var CustomCoffeeTampingState[0] = "Enable" Var CustomCoffeeTampingState[1] = "Enable" Var CustomCoffeeTampingState[2] = "Enable" Var CustomSweetState[0] = "Invisible" Var CustomSweetState[1] = "Invisible" Var CustomSweetState[2] = "Invisible" Var CustomSweetState[3] = "Invisible" Var CustomSweetState[4] = "Invisible" Var CustomSweetState[5] = "Invisible" Var CustomEspressoState[0] = "Enable" Var CustomEspressoState[1] = "Enable" Var CustomEnaergyState[0] = "Enable" Var CustomEnaergyState[1] = "Enable" Var CustomCocoaState[0] = "Enable" Var CustomCocoaState[1] = "Enable" Var CustomCocoaState[2] = "Enable" Var CustomOvaltineState[0] = "Enable" Var CustomOvaltineState[1] = "Enable" Var CustomOvaltineState[2] = "Enable" Var CustomMilkState[0] = "Enable" Var CustomMilkState[1] = "Enable" Var CustomMilkState[2] = "Enable" ; Texts Var CustomCoffeeTextY = 47 Var CustomSweetTextY = 52 Var CustomSweetPercentTextY = 52 Var CustomEspressoTextY = 52 Var CustoppopupToppingY = 880 Var CustoppopupToppingNextY = 180 Var CustomOreoState = "Invisible" Var CustomOvaltineState = "Invisible" Var CustomCocoaState = "Invisible" Var CustomCollagenState = "Invisible" Var CustomOreoCheckState = "Invisible" Var CustomOvaltineCheckState = "Invisible" Var CustomCocoaCheckState = "Invisible" Var PopupToppingSelect = "Invisible" Var custom_coffee_offset_text_x = 0 Var CustomCoffeeWaterText[0] = "20ml" Var CustomCoffeeWaterText[1] = "30ml" Var CustomCoffeeWaterText[2] = "40ml" Var CustomCoffeeWaterText[3] = "50ml" Var CustomCoffeeWaterText[4] = "60ml" Var CustomCoffeeQuantityText[0] = "10g" Var CustomCoffeeQuantityText[1] = "13g" Var CustomCoffeeQuantityText[2] = "16g" Var CustomSweetrPercent[0] = "(0%)" Var CustomSweetrPercent[1] = "(30%)" Var CustomSweetrPercent[2] = "(60%)" Var CustomSweetrPercent[3] = "(100%)" Var CustomSweetrPercent[4] = "(120%)" Var CustomSweetrPercent[5] = "(140%)" ; End Customer Coffee Var BGSugarHotHealthy = "Invisible" Var BGSugarColdHealthy = "Invisible" Var showText8 = "Invisible" ;Var showShotEnable = "Enable" ;Var ShotCoffeePremium = "Enable" ;Var showOreoAddEnable = "Enable" ;Var showCustomCoffee = "Enable" Var CerealMilkToppingEnable = "Invisible" Var ExtraTopping = "Invisible" ; On open Var LidState = Lid1Status ;SAVELOG PreviseXMLFileName2 Var MenuReady = "-" Var topping1 = "1" Var topping2 = "31" Var topping3 = "31" Var BugFlag = 0 Var DirImageInter = "ROOT/taobin_project/image/topping_revamp_inter" If show_eng = "true" Then Var DirImage = "ROOT/taobin_project/image/topping2_en" Var show_btp = "ROOT/taobin_project/image/bn_thai_lang_press.png" Var show_btn = "ROOT/taobin_project/image/bn_thai_lang.png" Var showname = NameDrink Var showdesc = DrinkDescription Var bnAccept = "ROOT/taobin_project/image/topping2_en/topping_revamp/bn_accept2.png" Var bpAccept = "ROOT/taobin_project/image/topping2_en/topping_revamp/bp_accept2.png" Var bnAcceptX = 360 Var text_show_thai = "Invisible" Var text_show_eng = "Enable" Var topping_shot_price_x = 630 Var text_x_add_oreo_price = 430 Var text_show_normal_x = 408 Var text_x_free_adjust = 100 Var text_milk_choice_price_x = 255 If PromotionOreoToppingFreeEnable = 0 Then Var text_x_free_adjust = text_x_free_adjust + 5 EndIf Var CustomCoffeeLevelText[0] = "Medium" Var CustomCoffeeLevelText[1] = "Just Right" Var CustomCoffeeLevelText[2] = "Dark" Var CustomCoffeeLevelText[3] = "Darker" Var CustomCoffeeTampingText[0] = "Light" Var CustomCoffeeTampingText[1] = "Medium" Var CustomCoffeeTampingText[2] = "Hight" Var CustomSweetrText[0] = "Not sweet" Var CustomSweetrText[1] = "Little" Var CustomSweetrText[2] = "Less" Var CustomSweetrText[3] = "Perfect" Var CustomSweetrText[4] = "Extra" Var CustomSweetrText[5] = "Sweetest" Var CustomEspressoText[0] = "1 Shot" Var CustomEspressoText[1] = "2 Shot" Var CustomEspressoText[2] = "3 Shot" Var CustomCocoaText[0] = "Cocoa X2" Var CustomCocoaText[1] = "Cocoa X3" Var CustomCocoaText[2] = "Cocoa X10" Var CustomOvaltineText[0] = "Ovaltine X2" Var CustomOvaltineText[1] = "Ovaltine X3" Var CustomOvaltineText[2] = "Ovaltine X10" Var CustomMilkText[0] = "Light" Var CustomMilkText[1] = "Normal" Var CustomMilkText[2] = "Rich" Var custom_coffee_level_medium_text_x = 540 Var custom_coffee_level_medium_price_x = 600 Var custom_coffee_level_darker_text_x = 880 Var custom_coffee_level_dark_text_x = 785 Var SugarZeroCalPrice_X = 540 Var CustomSweetNotTextX = 310 Var CustomSweetNotPercentTextX = 388 Var CustomSweetLittleTextX = 442 Var CustomSweetLittlePercentTextX = 488 Var CustomSweetLessTextX = 553 Var CustomSweetLessPercentTextX = 595 Var CustomSweetPerfectTextX = 660 Var CustomSweetPerfectPercentTextX = 715 Var CustomSweetExtraTextX = 775 Var CustomSweetExtraPercentTextX = 815 Var CustomSweetestTextX = 865 Var CustomSweetestPercentTextX = 935 Else Var DirImage = "ROOT/taobin_project/image/topping2" Var show_btp = "ROOT/taobin_project/image/bn_eng_lang_press.png" Var show_btn = "ROOT/taobin_project/image/bn_eng_lang.png" Var showname = NameDrinkTH Var showdesc = DrinkDescriptionTH Var bnAccept = "ROOT/taobin_project/image/topping2/topping_revamp/bn_accept2.png" Var bpAccept = "ROOT/taobin_project/image/topping2/topping_revamp/bp_accept2.png" Var bnAcceptX = 360 Var text_show_thai = "Enable" Var text_show_eng = "Invisible" Var topping_shot_price_x = 600 Var text_x_add_oreo_price = 420 Var text_show_normal_x = 386 Var text_x_free_adjust = 70 Var text_milk_choice_price_x = 237 If PromotionOreoToppingFreeEnable = 0 Then Var text_x_free_adjust = text_x_free_adjust + 30 EndIf Var CustomCoffeeLevelText[0] = "กลาง" Var CustomCoffeeLevelText[1] = "กำลังพอดี" Var CustomCoffeeLevelText[2] = "เข้ม" Var CustomCoffeeLevelText[3] = "เข้มกว่า" Var CustomCoffeeTampingText[0] = "เบา" Var CustomCoffeeTampingText[1] = "ปานกลาง" Var CustomCoffeeTampingText[2] = "เน้น" Var CustomSweetrText[0] = "ไม่หวาน" Var CustomSweetrText[1] = "จุบจิบ" Var CustomSweetrText[2] = "น้อย" Var CustomSweetrText[3] = "พอดี" Var CustomSweetrText[4] = "จึ้ง" Var CustomSweetrText[5] = "สุขิต" Var CustomEspressoText[0] = "1 ช็อต" Var CustomEspressoText[1] = "2 ช็อต" Var CustomEspressoText[2] = "3 ช็อต" Var CustomCocoaText[0] = "โกโก้ X2" Var CustomCocoaText[1] = "โกโก้ X3" Var CustomCocoaText[2] = "โกโก้ X10" Var CustomOvaltineText[0] = "โอวัลติน X2" Var CustomOvaltineText[1] = "โอวัลติน X3" Var CustomOvaltineText[2] = "โอวัลติน X10" Var CustomMilkText[0] = "ไลท์" Var CustomMilkText[1] = "ปกติ" Var CustomMilkText[2] = "ข้นมัน" Var custom_coffee_level_medium_text_x = 560 Var custom_coffee_level_medium_price_x = 600 Var custom_coffee_level_darker_text_x = 880 Var custom_coffee_level_dark_text_x = 790 Var SugarZeroCalPrice_X = 482 Var CustomSweetNotTextX = 331 Var CustomSweetNotPercentTextX = 388 Var CustomSweetLittleTextX = 445 Var CustomSweetLittlePercentTextX = 488 Var CustomSweetLessTextX = 560 Var CustomSweetLessPercentTextX = 595 Var CustomSweetPerfectTextX = 675 Var CustomSweetPerfectPercentTextX = 710 Var CustomSweetExtraTextX = 795 Var CustomSweetExtraPercentTextX = 820 Var CustomSweetestTextX = 900 Var CustomSweetestPercentTextX = 935 EndIf Var text_x_free_topping = text_x_add_oreo_price + text_x_free_adjust Var bg_strawlid = DirImage + "/topping_revamp/bg_strawlid.png" Var bg_straw_only = DirImage + "/bg_straw_only.png" Var bg_lid_only = DirImage + "/bg_lid_only.png" Var backGroundAddExtra = DirImage + "/bg_add_shot_coffee_only.png" Var backGroundAddExtra2 = DirImage + "/bg_add_shot_coffee_only.png" Var backGroundAddShotPremium = DirImage + "/bg_add_shot_coffee2_only.png" Var backGroundAddShotPremiumWith = DirImage + "/bg_add_shot_coffee_only.png" ;Var blendedState = "Enable" ;Var ShotCoffeeBG = "Enable" ;Var showShotEnable = "Enable" ;Var ShowLidStraw = "Enable" ;Var ShowStrawOnly = "Enable" ;Var ShowLidOnly = "Enable" Var ShiftSugarStep = 1 CRLFToSpace showname CRLFToSpace showdesc ;- Begin Var PriceDrinkNoTop = PriceDrink Var PriceDrinkTmp = PriceDrink Var PriceDrinkTmpShow = charOfBaht + PriceDrinkTmp Var Timeout = 0 ;SAVELOG PriceDrinkTmp ;- End If RoadShow = "true" Then Var PriceDrinkTmp = "Free" Var SaveSelectDrinkRoadShow = SelectDrink EndIf DEBUGVAR SaveSelectDrinkRoadShow If ShowPrice = "Invisible" Then Var PriceDrinkTmpShow = "Free" EndIf Var StateImgKeto = "Invisible" Var ToppingGotoPayment = "true" DEBUGVAR backGroundAddExtra DEBUGVAR backGroundAddShotPremium DEBUGVAR MultiPayEnable DEBUGVAR CART_COUNT Var btnAddCart = "Invisible" If MultiPayEnable = "true" Then Var btnAddCart = "Enable" If CART_COUNT = 3 Then Var btnAddCart = "Invisible" EndIf EndIf Var LidDeactiveButton = "Invisible" Var StrawDeactiveButton = "Invisible" Machine DoorClose Machine DoorLidClose Var ButtonNext = "false" Var NEW_MULTI = "Invisible" Var high_light_drink_type = "Invisible" Var toppingSelectState = "Invisible" Var SelectToppingType = 0 Var SelectedToppingCount = 0 Var SelectSyrupType = 0 Var text_hot_color = "0x84776F" Var text_cold_color = "0x84776F" Var text_blender_color = "0x84776F" If new_layout = "true" Then Var PriceDrinkTmpShow = "---" Var show_select_type = "Enable" Var hot_button_state = PD_STAGE_1 Var cold_button_state = PD_STAGE_2 Var blend_button_state = PD_STAGE_3 ; Protect have product-code but menu disable or invalid. If hot_button_state = "Invisible" Then Var hot_button_state = "Disable2" EndIf If cold_button_state = "Invisible" Then Var cold_button_state = "Disable2" EndIf If blend_button_state = "Invisible" Then Var blend_button_state = "Disable2" EndIf Function 2 Else Var show_select_type = "Invisible" ; assume auto select Var SelectDrinkType = 1 EndIf DEBUGVAR show_select_type DEBUGVAR PriceD1 DEBUGVAR PriceD2 DEBUGVAR PriceD3 If From15THBPro = 1 Then If PriceD1 > 0 Then Var OriginalPriceD1 = PriceD1 Var PriceD1 = 15 EndIf If PriceD2 > 0 Then Var OriginalPriceD2 = PriceD2 Var PriceD2 = 15 EndIf If PriceD3 > 0 Then Var OriginalPriceD3 = PriceD3 Var PriceD3 = 15 EndIf EndIf If hot_button_state = "Disable2" Then Var text_price_d1 = "" Else Var text_price_d1 !assigned StringFmt( PriceD1 , DisplayFormat, PreScaleConvertShow) EndIf If cold_button_state = "Disable2" Then Var text_price_d2 = "" Else Var text_price_d2 !assigned StringFmt( PriceD2 , DisplayFormat, PreScaleConvertShow) EndIf If blend_button_state = "Disable2" Then Var text_price_d3 = "" Else Var text_price_d3 !assigned StringFmt( PriceD3 , DisplayFormat, PreScaleConvertShow) EndIf DEBUGVAR PD_CODE1 DEBUGVAR PD_CODE2 DEBUGVAR PD_CODE3 DEBUGVAR PD_STAGE_1 DEBUGVAR PD_STAGE_2 DEBUGVAR PD_STAGE_3 Var img_cold = "/bt_cold_no.png" Var img_cold_sel = "/bt_cold_selected_no.png" Var img_cold_dis = "/bt_cold_disable_no.png" Var img_cold_dis2 = "/bt_cold_disable2_no.png" If PD_CODE2 = "12-05-02-0016" Then Var img_cold = "/bt_normal_no.png" Var img_cold_sel = "/bt_normal_selected_no.png" Var img_cold_dis = "/bt_cold_disable_no.png" Var img_cold_dis2 = "/bt_cold_disable2_no.png" EndIf Var img_smth = "/bt_smoothie_no.png" Var img_smth_sel = "/bt_smoothie_selected_no.png" Var img_smth_dis = "/bt_smoothie_disable_no.png" Var img_smth_dis2 = "/bt_smoothie_disable2_no.png" If MilkChoiceVeganEnable = 1 Then Var OatMilkToppingBg = DirImage + "/bg_milk_choice_j.png" Else Var OatMilkToppingBg = DirImage + "/bg_milk_choice.png" EndIf Var OatMilkToppingEnable = "Invisible" Var OatMilkEnable = "Invisible" Var CerealMilkEnable = "Enable" Var topping_price_refresh = 1 Var StrawState = "Enable" Var LidState = "Enable" Var MAT_ID_9701 = StrawState Var SubMenuGroupIDSlot6_1 = 0 Var bg_lidProblem_ST = "Invisible" Var GetLidButtonState = "Invisible" Var PromotionIDCurrentOrder = 0 DEBUGVAR PromotionIDCurrentOrder Var DiscountWithIdentifyState = "Invisible" Var WelcomeDrinkButtonState = "Invisible" DEBUGVAR Price5Active DEBUGVAR EnableLiveness DEBUGVAR DiscountWithIdentifyState DEBUGVAR WelcomeDrinkEnable If OreoWelcomeDrinkFromClick = 1 Then Var OreoWelcomeDrinkFromClick = 0 Var WelcomeDrinkButtonState = "Enable" EndIf DEBUGVAR WelcomeDrinkButtonState If EnableLiveness = "true" Then If CameraCount = 1 Then ; echo -n true > /mnt/sdcard/enable_discount_price5 READ_FILE "/mnt/sdcard/enable_discount_price5" EnableDiscountPrice5 DEBUGVAR EnableDiscountPrice5 If EnableDiscountPrice5 = "true" Then Var EnableDiscountWithIdentify = 1 Var DiscountWithIdentifyState = "Enable" EndIf EndIf EndIf If show_eng = "true" Then Var OatMilkX = 400 Else Var OatMilkX = 270 EndIf TRY "/mnt/sdcard/coffeevending/taobin_project/flash_deal/topping_page.ev" Var MenuReason = "" If SugarZeroCalEnable = "false" Then Var SugarZeroCalOption = "Invisible" EndIf If MAT_ID_1215 = "Disable" Then ; Disable2 away Var SugarZeroCalCheck = "Disable2" EndIf If MAT_ID_1215 = "Enable" Then Var SugarZeroCalCheck = "Enable" EndIf If FromCoffeeDrink1BathPro = 1 Then Var DisableAllNotFreeTopping = 1 EndIf Var ShowSpecialButton = "Invisible" Var TextShowSpecialButton = "" Var OverridePrice = 100 Var SpecialButtonOpenFileXML = "ROOT/taobin_project/xml/page_payment.xml" TRY "ROOT/taobin_project/speical/call_from_topping.ev" DEBUGVAR $12-02-03-0043.Name DEBUGVAR $12-02-03-0043.NameE If show_eng = "true" Then Var showname = NameDrink Var showdesc = DrinkDescription Else Var showname = NameDrinkTH Var showdesc = DrinkDescriptionTH EndIf BackslashNToEnter showname BackslashNToEnter showdesc CRLFToSpace showname CRLFToSpace showdesc DEBUGVAR showname DEBUGVAR showdesc Strlen showname show_name_len If show_eng = "true" Then If show_name_len > 24 Then Var showname = showname + "###size=54" EndIf Else If show_name_len > 0 Then Var showname = showname + "###size=68" EndIf EndIf Var MenuReasonStage = "Invisible" Var AdvertOpened = "false" 1000 DEBUGVAR Timeout DEBUGVAR MenuReady DEBUGVAR CupRemain DEBUGVAR FreePowerup DEBUGVAR showSweetLevel If CLOSE_ORDER_NOW = "true" Then ;include="ROOT/taobin_project/inc/return_condition.ev" EndIf If NoWaitMachineEnable = 1 Then DEBUGVAR MachineStage DEBUGVAR ConfirmDrinkButtonState If MachineStage = "close-maintenance" Then Var ConfirmDrinkButtonState = "Enable" If stop_now = "true" Then SAVELOG "stop_now is true page_topping_select7.xml" ;include="ROOT/taobin_project/inc/return_condition.ev" EndIf Else Var ConfirmDrinkButtonState = "Invisible" EndIf EndIf If CLOSE_ORDER_NOW = "true" Then SAVELOG "DEACTIVE in page_topping_select7.xml" ;include="ROOT/taobin_project/inc/return_condition.ev" EndIf If SELLSTATUS = "DEACTIVE" Then SAVELOG "DEACTIVE in page_topping_select7.xml" ;include="ROOT/taobin_project/inc/return_condition.ev" EndIf DEBUGVAR SelectDrinkType DEBUGVAR Seeker If SelectDrinkType = 1 Then If MenuReady = "YES" Then DEBUGVAR ToppingDetail DEBUGVAR SelectToppingType ; echo -n true > /mnt/sdcard/coffeevending/menu_blend_free READ_FILE "/mnt/sdcard/coffeevending/menu_blend_free" menu_blend_free DEBUGVAR menu_blend_free DEBUGVAR blend_button_state DEBUGVAR DoorCupPosition DEBUGVAR show_eng If menu_blend_free = "true" Then If blend_button_state = "PressForever" Then Var PriceDrinkNoTop = 0 Var PriceDrink = 0 Var PriceDrinkTmpShow = "Free" EndIf EndIf If Seeker = "next" Then If CupRemain > 0 Then If Only18 = "true" Then DEBUGVAR SelectDrink MenuProfile SelectDrink "IsMenuInProfile" ; disable old verification Var AdultState1 = "Invisible" DEBUGVAR IsMenuInProfile If IsMenuInProfile = "true" Then If EnableLiveness = "true" Then DEBUGVAR EnableLiveness If AdvertOpened = "true" Then Else OpenInst 1 "/mnt/sdcard/coffeevending/taobin_project/xml/page_advert.xml" Var AdvertOpened = "true" EndIf ; full Open "ROOT/taobin_project/xml/page_identity_verification.xml" Else If AdvertOpened = "true" Then Else OpenInst 1 "/mnt/sdcard/coffeevending/taobin_project/xml/page_advert.xml" Var AdvertOpened = "true" EndIf ; Only IDCard Open "ROOT/taobin_project/xml/page_identity18_verification.xml" EndIf Else If SelectToppingType = 1 Then If AdvertOpened = "true" Then Else OpenInst 1 "/mnt/sdcard/coffeevending/taobin_project/xml/page_advert.xml" Var AdvertOpened = "true" EndIf Open "ROOT/taobin_project/xml/page_payment.xml" Else Var toppingSelectState = "Enable" EndIf EndIf Else If SelectToppingType = 1 Then If AdvertOpened = "true" Then Else OpenInst 1 "/mnt/sdcard/coffeevending/taobin_project/xml/page_advert.xml" Var AdvertOpened = "true" EndIf Open "ROOT/taobin_project/xml/page_payment.xml" Else Var toppingSelectState = "Enable" EndIf EndIf EndIf Else If DoorCupPosition = "bottom" Then If AdvertOpened = "true" Then Else OpenInst 1 "/mnt/sdcard/coffeevending/taobin_project/xml/page_advert.xml" Var AdvertOpened = "true" EndIf If FromEnergyDrink1BathPro = 1 Then Open "ROOT/taobin_project/xml/event/energy_drink_1_bath/page_energy_drink_1_bath_consent.xml" EndIf If Only18 = "true" Then DEBUGVAR SelectDrink MenuProfile SelectDrink "IsMenuInProfile" ; disable old verification Var AdultState1 = "Invisible" DEBUGVAR IsMenuInProfile If IsMenuInProfile = "true" Then ; Check profile If EnableLiveness = "true" Then DEBUGVAR EnableLiveness If AdvertOpened = "true" Then Else OpenInst 1 "/mnt/sdcard/coffeevending/taobin_project/xml/page_advert.xml" Var AdvertOpened = "true" EndIf ; full Open "ROOT/taobin_project/xml/page_identity_verification.xml" Else If AdvertOpened = "true" Then Else OpenInst 1 "/mnt/sdcard/coffeevending/taobin_project/xml/page_advert.xml" Var AdvertOpened = "true" EndIf ; Only IDCard Open "ROOT/taobin_project/xml/page_identity18_verification.xml" EndIf Else If SelectToppingType = 1 Then If AdvertOpened = "true" Then Else OpenInst 1 "/mnt/sdcard/coffeevending/taobin_project/xml/page_advert.xml" Var AdvertOpened = "true" EndIf Open "ROOT/taobin_project/xml/page_payment.xml" EndIf EndIf Else If SelectToppingType = 1 Then If AdvertOpened = "true" Then Else OpenInst 1 "/mnt/sdcard/coffeevending/taobin_project/xml/page_advert.xml" Var AdvertOpened = "true" EndIf Open "ROOT/taobin_project/xml/page_payment.xml" EndIf EndIf EndIf EndIf EndIf EndIf Var Timeout = Timeout + 1 If Timeout > 40 Then Var Timeout = 0 If Seeker = "next" Then If ChildrenFree = 1 Then Var ChildrenFree = 0 Var Cid = 33 Var PointCrm = "0" Var GetScore = "1" AddData Cid TelNumPromotion IDNum PointCrm GetScore EndIf ;OpenInst 1 "/mnt/sdcard/coffeevending/taobin_project/xml/page_blank.xml" Open "ROOT/taobin_project/xml/page_brewing3Conti.xml" Else If ChildrenFree = 1 Then Var ChildrenFree = 0 Var Cid = 33 Var PointCrm = "0" Var GetScore = "1" AddData Cid TelNumPromotion IDNum PointCrm GetScore EndIf OpenInst 1 "/mnt/sdcard/coffeevending/taobin_project/xml/page_advert.xml" Open "ROOT/taobin_project/xml/page_catalog.xml" EndIf EndIf If MultiPayEnable = "true" Then If NEW_MULTI = "Invisible" Then Var NEW_MULTI = "Enable" Else Var NEW_MULTI = "Invisible" EndIf EndIf If Seeker = "curr" Then If DoorCupPosition = "bottom" Then ; It normal Var EmergencyStop = "false" Else Var EmergencyStop = "true" EndIf EndIf DEBUGVAR NoWaitMachineEnable If NoWaitMachineEnable = 1 Then DEBUGVAR MachineStage DEBUGVAR ConfirmDrinkButtonState If MachineStage = "close-maintenance" Then Var ConfirmDrinkButtonState = "Enable" If stop_now = "true" Then Open "ROOT/taobin_project/xml/page_back_to_error.xml" EndIf Else Var ConfirmDrinkButtonState = "Invisible" EndIf Else EndIf DEBUGVAR bnAccept If show_eng = "true" Then If MACHINE_SELF_TEST_COUNT_DOWN > 0 Then Var ShowTextSelfTestCountDown = "Please wait a moment (" + MACHINE_SELF_TEST_COUNT_DOWN Var ShowTextSelfTestCountDown = ShowTextSelfTestCountDown + ")" Else Var ShowTextSelfTestCountDown = "Please wait a moment" EndIf Else If MACHINE_SELF_TEST_COUNT_DOWN > 0 Then Var ShowTextSelfTestCountDown ="กรุณารอสักครู่ (" + MACHINE_SELF_TEST_COUNT_DOWN Var ShowTextSelfTestCountDown = ShowTextSelfTestCountDown + ")" Else Var ShowTextSelfTestCountDown ="กรุณารอสักครู่" EndIf EndIf If Seeker = "curr" Then If MenuReason = "arm-not-ready" Then SAVELOG "goto mode arm-not-ready" DEBUGVAR DoorCupPosition If DoorCupPosition = "bottom" Then Machine RemoveCup Machine DoorLidOpen Else Var TextSelfTestCntColor = "0x513C2F" Var ConfirmDrinkButtonState = "Enable" If show_eng = "true" Then Var ShowTextSelfTestCountDown = "Please take out the glass." Else Var ShowTextSelfTestCountDown = "กรุณานําแก้วออก" EndIf EndIf EndIf EndIf If MenuReason = "brew-stg" Then Var ConfirmDrinkButtonState = "Enable" If Timeout > 15 Then Var MenuReason = "-" Var Timeout = 0 Var ConfirmDrinkButtonState = "Invisible" EndIf EndIf If MenuReason = "-" Then Else Var MenuReasonString = MenuReason Var MenuReasonStage = "Enable" EndIf Var oreo_y = 1060 Var oreo_button_y = 1070 Var oreo_text_y = 1085 Var ovaltine_y = 1060 Var ovaltine_button_y = 1070 Var ovaltine_text_y = 1085 Var cocoa_y = 1060 Var cocoa_button_y = 1070 Var cocoa_text_y = 1085 Var bottom_y = 1060 Var accept_y = 1075 Var offset_total = 0 If CustomOreoState = "Enable" Then Var offset_total = 72 EndIf Var ovaltine_offset = offset_total If CustomOvaltineState = "Enable" Then Var offset_total = offset_total + 72 EndIf Var cocoa_offset = offset_total If CustomCocoaState = "Enable" Then Var offset_total = offset_total + 72 EndIf Var bottom_offset = offset_total Var ovaltine_y = 1060 + ovaltine_offset Var ovaltine_button_y = 1070 + ovaltine_offset Var ovaltine_text_y = 1085 + ovaltine_offset Var cocoa_y = 1060 + cocoa_offset Var cocoa_button_y = 1070 + cocoa_offset Var cocoa_text_y = 1085 + cocoa_offset Var bottom_y = 1060 + bottom_offset Var accept_y = 1075 + bottom_offset Refresh TimerReset DEBUGVAR LanguageShow DEBUGVAR InternationalEnable SAVELOG "EventLanguageOnChange menu -list" If InternationalEnable = 1 Then If CountryName = "Thailand" Then Var show_eng_button_stage = "Invisible" Var LanguageButtonEnable = "Enable" EndIf Else Var LanguageButtonEnable = "Invisible" Var show_eng_button_stage = "Enable" EndIf DEBUGVAR LanguageButtonEnable DEBUGVAR show_eng_button_stage OpenInst 3 "ROOT/taobin_project/xml/topview2.xml" RefreshAll 0 380 1080 1540 "0xeae6e1" ;include="ROOT/taobin_project/inc/video.inc" DEBUGVAR MAT_ID_9701 DEBUGVAR MAT_ID_9601 DEBUGVAR MAT_ID_1215 DEBUGVAR SubMenuProductCode1 DEBUGVAR SubMenuName11 DEBUGVAR SubMenuPrice1 DEBUGVAR SubMenuProductCode2 DEBUGVAR SubMenuName12 DEBUGVAR TOPPING1 DEBUGVAR TOPPING1_EXT_2 DEBUGVAR TOPPING2 DEBUGVAR TOPPING3 DEBUGVAR TOPPING4 DEBUGVAR TOPPING5 DEBUGVAR TOPPING6 DEBUGVAR TOPPING7 DEBUGVAR TOPPING8 DEBUGVAR TOPPING9 DEBUGVAR TOPPING10 DEBUGVAR TOPPING11 DEBUGVAR toppingID1index1 DEBUGVAR toppingID1index2 DEBUGVAR toppingID1index3 DEBUGVAR toppingID1index4 DEBUGVAR toppingID1index5 DEBUGVAR toppingID1index6 DEBUGVAR toppingID1index7 DEBUGVAR toppingID1index8 DEBUGVAR toppingID1index9 DEBUGVAR toppingID2index1 DEBUGVAR toppingID2index2 DEBUGVAR toppingID2index3 DEBUGVAR toppingID2index4 DEBUGVAR toppingID2index5 DEBUGVAR toppingID6index1 DEBUGVAR toppingID6index2 DEBUGVAR toppingID6index3 DEBUGVAR toppingID6index4 DEBUGVAR toppingID6index5 DEBUGVAR toppingID6index6 DEBUGVAR toppingID6index1Status DEBUGVAR toppingID6index2Status DEBUGVAR toppingID6index3Status DEBUGVAR toppingID6index4Status DEBUGVAR toppingID6index5Status DEBUGVAR toppingID6index6Status DEBUGVAR toppingID7index1 DEBUGVAR toppingID7index2 DEBUGVAR toppingID7index3 DEBUGVAR toppingID7index4 DEBUGVAR toppingID7index5 DEBUGVAR toppingID8index1 DEBUGVAR toppingID8index2 DEBUGVAR toppingID8index3 DEBUGVAR toppingID9index1 DEBUGVAR toppingID9index2 DEBUGVAR toppingID9index3 DEBUGVAR toppingID9index4 DEBUGVAR toppingID10index1 DEBUGVAR toppingID10index2 DEBUGVAR toppingID10index3 DEBUGVAR toppingID11index1 DEBUGVAR toppingID11index2 DEBUGVAR toppingID11index3 If toppingID1index5 > 0 Then SAVELOG "toppingID1index5 not set" EndIf DEBUGVAR toppingID1Default DEBUGVAR toppingID2Default DEBUGVAR toppingID3Default DEBUGVAR toppingID7Default DEBUGVAR toppingID8Default DEBUGVAR toppingID9Default DEBUGVAR toppingID10Default DEBUGVAR MenuCodeName1 DEBUGVAR MenuCodeName2 DEBUGVAR SubMenuOnTop1 DEBUGVAR SubMenuOnTop2 DEBUGVAR SubMenuOnTop3 DEBUGVAR SubMenuProductCode1 DEBUGVAR SubMenuProductCode2 DEBUGVAR SubMenuProductCode3 DEBUGVAR toppingID2price1 DEBUGVAR toppingID2price2 DEBUGVAR toppingID2price3 DEBUGVAR toppingID2price4 DEBUGVAR toppingID3price2 DEBUGVAR toppingID6price2 DEBUGVAR toppingID8price1 DEBUGVAR toppingID8price2 DEBUGVAR toppingID8price3 DEBUGVAR toppingID9price1 DEBUGVAR toppingID9price2 DEBUGVAR toppingID9price3 DEBUGVAR toppingID9price4 DEBUGVAR BrewParam DEBUGVAR UserSeletedSugar DEBUGVAR showOvaltineEnable If BugFlag = 1 Then Else If TOPPING6 = "Topping-Volcano" Then Var SelectToppingType = 1 Var text_color_6 = "0x84776F" If toppingID6price2 > 0 Then DEBUGVAR toppingID6price2 DEBUGVAR DisplayFormat Var toppingID6price2Conv !assigned StringFmt( toppingID6price2 , DisplayFormat, PreScaleConvertShow) DEBUGVAR toppingID6price2Conv Var text_price_6 = "" Var text_price_6 = toppingID6price2Conv + ")" Var text_price_6 = "(+" + text_price_6 DEBUGVAR text_price_6 DEBUGVAR text_color_6 Else Var text_price_6 = "" EndIf Var CustomSyrup = "Invisible" Var showOvaltineEnable = "Invisible" Var showCocoaEnable = "Invisible" If blend_button_state = "PressForever" Then Var SpecialMix = "Enable" Var showOreoAddEnable = "Enable" Var showText8 = "Invisible" Else Var showOreoAddEnable = "Disable" Var showText8 = "Enable" EndIf Var ExtraTopping = "Enable" If blend_button_state = "Disable2" Then If hot_button_state = "Disable2" Then If cold_button_state = "PressForever" Then Var showOreoAddEnable = "Enable" Var showText8 = "Invisible" EndIf EndIf EndIf EndIf If TOPPING11 = "milk-level" Then ;for some menu that not have sugar-level channel from json If TOPPING1 = "" Then Var BGMilkNew = "Enable" Var BGSugarNew = "Invisible" Var SugarZeroCalOption = "Invisible" EndIf Var CustomMilkState[0] = "Enable" Var CustomMilkState[1] = "Enable" Var CustomMilkState[2] = "Enable" Else Var CustomMilkState[0] = "Disable" Var CustomMilkState[1] = "Disable" Var CustomMilkState[2] = "Disable" EndIf If TOPPING6 = "all-volcano" Then Var SelectToppingType = 0 Var SelectedToppingCount = 0 If toppingID6price2 > 0 Then DEBUGVAR toppingID6price2 DEBUGVAR DisplayFormat Var toppingID6price2Conv !assigned StringFmt( toppingID6price2 , DisplayFormat, PreScaleConvertShow) DEBUGVAR toppingID6price2Conv Var text_price_6 = "" Var text_price_6 = toppingID6price2Conv + ")" Var text_price_6 = "(+" + text_price_6 DEBUGVAR text_price_6 Else Var text_price_6 = "" EndIf If cold_button_state = "PressForever" Then Var SpecialMix = "Enable" Var CustomSyrup = "Enable" Var showOreoAddEnable = "Disable" Var showOvaltineEnable = "Disable" Var showCocoaEnable = "Disable" Var showStrawberryEnable = "Disable" Var showYuzuEnable = "Disable" EndIf If hot_button_state = "PressForever" Then Var SpecialMix = "Enable" Var CustomSyrup = "Enable" Var showOreoAddEnable = "Disable" Var showOvaltineEnable = "Disable" Var showCocoaEnable = "Disable" Var showStrawberryEnable = "Disable" Var showYuzuEnable = "Disable" EndIf If blend_button_state = "PressForever" Then Var SpecialMix = "Enable" Var CustomSyrup = "Enable" If toppingID6index2 = 321 Then Var showOreoAddEnable = "Enable" EndIf If toppingID6index3 = 322 Then Var showCocoaEnable = "Enable" EndIf If toppingID6index4 = 323 Then Var showOvaltineEnable = "Enable" EndIf If toppingID6index5 = 324 Then Var showStrawberryEnable = "Enable" EndIf If toppingID6index6 = 325 Then Var showYuzuEnable = "Enable" EndIf Var showText8 = "Invisible" ; Var showCustomCoffee = "Enable" ; Var showCoffeeWater = "Enable" ; Var showCoffeeQuantity = "Enable" ; Var showCoffeeLevel = "Enable" ; Var showCoffeeTamping = "Enable" DEBUGVAR toppingSelectState If toppingSelectState = "Enable" Then Var CustomOreoState = "Enable" Var CustomOvaltineState = "Enable" Var CustomCocoaState = "Enable" Var CustomCollagenState = "Enable" Var PopupToppingSelect = "Enable" Var CustomOreoCheckState = "Enable" Var CustomOvaltineCheckState = "Enable" Var CustomCocoaCheckState = "Enable" EndIf Else Var SpecialMix = "Enable" Var CustomSyrup = "Enable" Var showOreoAddEnable = "Disable" Var showOvaltineEnable = "Disable" Var showCocoaEnable = "Disable" If toppingSelectState = "Enable" Then Var CustomCocoaCheckState = "Disable" Var CustomOreoCheckState = "Disable" Var CustomOvaltineCheckState = "Disable" EndIf Var showStrawberryEnable = "Disable" Var showYuzuEnable = "Disable" Var showText8 = "Enable" ; Var showCustomCoffee = "Invisible" ; Var showCoffeeWater = "Invisible" ; Var showCoffeeQuantity = "Invisible" ; Var showCoffeeLevel = "Invisible" ; Var showCoffeeTamping = "Invisible" EndIf If toppingID6index2Status = "" Then Var showOreoAddEnable = "Invisible" EndIf If toppingID6index3Status = "" Then Var showCocoaEnable = "Invisible" EndIf If toppingID6index4Status = "" Then Var showOvaltineEnable = "Invisible" EndIf If toppingID6index5Status = "" Then Var showStrawberryEnable = "Invisible" EndIf If toppingID6index6Status = "" Then Var showYuzuEnable = "Invisible" EndIf If toppingID6index2Status = "Disable" Then Var showOreoAddEnable = "Disable" EndIf If toppingID6index3Status = "Disable" Then Var showCocoaEnable = "Disable" EndIf If toppingID6index4Status = "Disable" Then Var showOvaltineEnable = "Disable" EndIf If toppingID6index5Status = "Disable" Then Var showStrawberryEnable = "Disable" EndIf If toppingID6index6Status = "Disable" Then Var showYuzuEnable = "Disable" EndIf Var ExtraTopping = "Enable" If blend_button_state = "Disable2" Then If hot_button_state = "Disable2" Then If cold_button_state = "PressForever" Then Var showOreoAddEnable = "Enable" Var showOvaltineEnable = "Enable" Var showCocoaEnable = "Enable" Var showText8 = "Invisible" EndIf EndIf EndIf Else If blend_button_state = "PressForever" Then Var SelectToppingType = 1 EndIf EndIf DEBUGVAR SubMenuGroupIDSlot6_1 DEBUGVAR TOPPING3 If TOPPING3 = "Collagen(mix)" Then If JemilaToppingFlag = 1 Then If hot_button_state = "PressForever" Then Var CollagenState = "Disable" EndIf If cold_button_state = "PressForever" Then If CollagenState = "Invisible" Then Var CollagenState = "Enable" EndIf If CollagenState = "Disable" Then Var CollagenState = "Enable" EndIf EndIf If blend_button_state = "PressForever" Then If CollagenState = "Invisible" Then Var CollagenState = "Enable" EndIf If CollagenState = "Disable" Then Var CollagenState = "Enable" EndIf EndIf Var CollagenState = "Enable" If JemilaToppingFreeFlag = 1 Then Var CollagenToppingBg = "/bg_top_jemila_free.png" Var CollagenToppingPrice = 0 Else Var CollagenToppingBg = "/bg_top_jemila.png" Var CollagenToppingPrice = 5 EndIf Else Var CollagenState = "Invisible" EndIf Else If CollagenState != "Invisible" Then Var CollagenState = "Disable" Else Var CollagenState = "Invisible" Var ShowCollagenOnly = "Invisible" EndIf EndIf DEBUGVAR CollagenState If CollagenState = "Enable" Then Var ExtraTopping = "Enable" EndIf Var PriceCustomCoffeeFormat = "%.0f฿" If TOPPING7 = "water-level" Then Var CustomCoffeeEnable = "True" Var showCustomCoffee = "Enable" Var showCoffeeWater = "Enable" If toppingID7Default = "" Then Var CustomCoffeeWaterState[0] = "PressForever" Else If toppingID7index1 = toppingID7Default Then Var CurrentCoffeeWaterId = toppingID7index1 Var CustomCoffeeWaterState[0] = "PressForever" Var CustomCoffeeWaterState[1] = "Enable" Var CustomCoffeeWaterState[2] = "Enable" Var CustomCoffeeWaterState[3] = "Enable" Var CustomCoffeeWaterState[4] = "Enable" EndIf If toppingID7index2 = toppingID7Default Then Var CurrentCoffeeWaterId = toppingID7index2 Var CustomCoffeeWaterState[0] = "Enable" Var CustomCoffeeWaterState[1] = "PressForever" Var CustomCoffeeWaterState[2] = "Enable" Var CustomCoffeeWaterState[3] = "Enable" Var CustomCoffeeWaterState[4] = "Enable" EndIf If toppingID7index3 = toppingID7Default Then Var CurrentCoffeeWaterId = toppingID7index3 Var CustomCoffeeWaterState[0] = "Enable" Var CustomCoffeeWaterState[1] = "Enable" Var CustomCoffeeWaterState[2] = "PressForever" Var CustomCoffeeWaterState[3] = "Enable" Var CustomCoffeeWaterState[4] = "Enable" EndIf If toppingID7index4 = toppingID7Default Then Var CurrentCoffeeWaterId = toppingID7index4 Var CustomCoffeeWaterState[0] = "Enable" Var CustomCoffeeWaterState[1] = "Enable" Var CustomCoffeeWaterState[2] = "Enable" Var CustomCoffeeWaterState[3] = "PressForever" Var CustomCoffeeWaterState[4] = "Enable" EndIf If toppingID7index5 = toppingID7Default Then Var CurrentCoffeeWaterId = toppingID7index5 Var CustomCoffeeWaterState[0] = "Enable" Var CustomCoffeeWaterState[1] = "Enable" Var CustomCoffeeWaterState[2] = "Enable" Var CustomCoffeeWaterState[3] = "Enable" Var CustomCoffeeWaterState[4] = "PressForever" EndIf EndIf EndIf If TOPPING9 = "single-shot-espv2" Then Var CustomCoffeeEnable = "True" Var showCustomCoffee = "Enable" var showCoffeeLevel = "Enable" If toppingID9Default = "" Then Var CustomCoffeeLevelState[1] = "PressForever" Else If toppingID9index1 = toppingID9Default Then Var CurrentCoffeeLevelId = toppingID9index1 Var CustomCoffeeLevelState[0] = "PressForever" Var CustomCoffeeLevelState[1] = "Enable" Var CustomCoffeeLevelState[2] = "Enable" Var CustomCoffeeLevelState[3] = "Enable" EndIf If toppingID9index2 = toppingID9Default Then Var CurrentCoffeeLevelId = toppingID9index2 Var CustomCoffeeLevelState[0] = "Enable" Var CustomCoffeeLevelState[1] = "PressForever" Var CustomCoffeeLevelState[2] = "Enable" Var CustomCoffeeLevelState[3] = "Enable" EndIf If toppingID9index3 = toppingID9Default Then Var CurrentCoffeeLevelId = toppingID9index3 Var CustomCoffeeLevelState[0] = "Enable" Var CustomCoffeeLevelState[1] = "Enable" Var CustomCoffeeLevelState[2] = "PressForever" Var CustomCoffeeLevelState[3] = "Enable" EndIf If toppingID9index4 = toppingID9Default Then Var CurrentCoffeeLevelId = toppingID9index4 Var CustomCoffeeLevelState[0] = "Enable" Var CustomCoffeeLevelState[1] = "Enable" Var CustomCoffeeLevelState[2] = "Enable" Var CustomCoffeeLevelState[3] = "PressForever" EndIf EndIf If toppingID9price1 > 0 Then Var priceFormated !assigned StringFmt( toppingID9price1 , PriceCustomCoffeeFormat, PreScaleConvertShow) Var CustomCoffeeLevelAdditionalPrice[0] = "(+" + priceFormated Var CustomCoffeeLevelAdditionalPrice[0] = CustomCoffeeLevelAdditionalPrice[0] + ")" Else Var CustomCoffeeLevelAdditionalPrice[0] = "" EndIf If toppingID9price2 > 0 Then Var priceFormated !assigned StringFmt( toppingID9price2 , PriceCustomCoffeeFormat, PreScaleConvertShow) Var CustomCoffeeLevelAdditionalPrice[1] = "(+" + priceFormated Var CustomCoffeeLevelAdditionalPrice[1] = CustomCoffeeLevelAdditionalPrice[1] + ")" Else Var CustomCoffeeLevelAdditionalPrice[1] = "" EndIf If toppingID9price3 > 0 Then Var priceFormated !assigned StringFmt( toppingID9price3 , PriceCustomCoffeeFormat, PreScaleConvertShow) Var CustomCoffeeLevelAdditionalPrice[2] = "(+" + priceFormated Var CustomCoffeeLevelAdditionalPrice[2] = CustomCoffeeLevelAdditionalPrice[2] + ")" Else Var CustomCoffeeLevelAdditionalPrice[2] = "" EndIf If toppingID9price4 > 0 Then Var priceFormated !assigned StringFmt( toppingID9price4 , PriceCustomCoffeeFormat, PreScaleConvertShow) Var CustomCoffeeLevelAdditionalPrice[3] = "(+" + priceFormated Var CustomCoffeeLevelAdditionalPrice[3] = CustomCoffeeLevelAdditionalPrice[3] + ")" Else Var CustomCoffeeLevelAdditionalPrice[3] = "" EndIf EndIf If TOPPING9 = "double-shot-espv2" Then Var CustomCoffeeEnable = "True" Var showCustomCoffee = "Enable" var showCoffeeLevel = "Enable" If toppingID9Default = "" Then Var CustomCoffeeLevelState[1] = "PressForever" Else If toppingID9index1 = toppingID9Default Then Var CurrentCoffeeLevelId = toppingID9index1 Var CustomCoffeeLevelState[0] = "PressForever" Var CustomCoffeeLevelState[1] = "Enable" Var CustomCoffeeLevelState[2] = "Enable" Var CustomCoffeeLevelState[3] = "Enable" EndIf If toppingID9index2 = toppingID9Default Then Var CurrentCoffeeLevelId = toppingID9index2 Var CustomCoffeeLevelState[0] = "Enable" Var CustomCoffeeLevelState[1] = "PressForever" Var CustomCoffeeLevelState[2] = "Enable" Var CustomCoffeeLevelState[3] = "Enable" EndIf If toppingID9index3 = toppingID9Default Then Var CurrentCoffeeLevelId = toppingID9index3 Var CustomCoffeeLevelState[0] = "Enable" Var CustomCoffeeLevelState[1] = "Enable" Var CustomCoffeeLevelState[2] = "PressForever" Var CustomCoffeeLevelState[3] = "Enable" EndIf If toppingID9index4 = toppingID9Default Then Var CurrentCoffeeLevelId = toppingID9index4 Var CustomCoffeeLevelState[0] = "Enable" Var CustomCoffeeLevelState[1] = "Enable" Var CustomCoffeeLevelState[2] = "Enable" Var CustomCoffeeLevelState[3] = "PressForever" EndIf EndIf If toppingID9price1 > 0 Then Var priceFormated !assigned StringFmt( toppingID9price1 , PriceCustomCoffeeFormat, PreScaleConvertShow) Var CustomCoffeeLevelAdditionalPrice[0] = "(+" + priceFormated Var CustomCoffeeLevelAdditionalPrice[0] = CustomCoffeeLevelAdditionalPrice[0] + ")" Else Var CustomCoffeeLevelAdditionalPrice[0] = "" EndIf If toppingID9price2 > 0 Then Var priceFormated !assigned StringFmt( toppingID9price2 , PriceCustomCoffeeFormat, PreScaleConvertShow) Var CustomCoffeeLevelAdditionalPrice[1] = "(+" + priceFormated Var CustomCoffeeLevelAdditionalPrice[1] = CustomCoffeeLevelAdditionalPrice[1] + ")" Else Var CustomCoffeeLevelAdditionalPrice[1] = "" EndIf If toppingID9price3 > 0 Then Var priceFormated !assigned StringFmt( toppingID9price3 , PriceCustomCoffeeFormat, PreScaleConvertShow) Var CustomCoffeeLevelAdditionalPrice[2] = "(+" + priceFormated Var CustomCoffeeLevelAdditionalPrice[2] = CustomCoffeeLevelAdditionalPrice[2] + ")" Else Var CustomCoffeeLevelAdditionalPrice[2] = "" EndIf If toppingID9price4 > 0 Then Var priceFormated !assigned StringFmt( toppingID9price4 , PriceCustomCoffeeFormat, PreScaleConvertShow) Var CustomCoffeeLevelAdditionalPrice[3] = "(+" + priceFormated Var CustomCoffeeLevelAdditionalPrice[3] = CustomCoffeeLevelAdditionalPrice[3] + ")" Else Var CustomCoffeeLevelAdditionalPrice[3] = "" EndIf EndIf If TOPPING8 = "tampping-espv2" Then Var CustomCoffeeEnable = "True" Var showCustomCoffee = "Enable" var showCoffeeTamping = "Enable" If toppingID8Default = "" Then Var CustomCoffeeTampingState[1] = "PressForever" Else If toppingID8index1 = toppingID8Default Then Var CurrentCoffeeTampingId = toppingID8index1 Var CustomCoffeeTampingState[0] = "PressForever" Var CustomCoffeeTampingState[1] = "Enable" Var CustomCoffeeTampingState[2] = "Enable" EndIf If toppingID8index2 = toppingID8Default Then Var CurrentCoffeeTampingId = toppingID8index2 Var CustomCoffeeTampingState[0] = "Enable" Var CustomCoffeeTampingState[1] = "PressForever" Var CustomCoffeeTampingState[2] = "Enable" EndIf If toppingID8index3 = toppingID8Default Then Var CurrentCoffeeTampingId = toppingID8index3 Var CustomCoffeeTampingState[0] = "Enable" Var CustomCoffeeTampingState[1] = "Enable" Var CustomCoffeeTampingState[2] = "PressForever" EndIf EndIf EndIf If cold_button_state = "PressForever" Then If toppingID6index5 = 324 Then Var showStrawberryEnable = "Enable" EndIf If toppingID6index6 = 325 Then Var showYuzuEnable = "Enable" EndIf EndIf ; i f Hot menu disable away If hot_button_state = "PressForever" Then If showOreoAddEnable = "Enable" Then Var showOreoAddEnable = "Disable" EndIf If showOreoAddEnable = "Press" Then Var showOreoAddEnable = "Disable" EndIf If showOvaltineEnable = "Enable" Then Var showOvaltineEnable = "Disable" EndIf If showOvaltineEnable = "Press" Then Var showOvaltineEnable = "Disable" EndIf If showCocoaEnable = "Enable" Then Var showCocoaEnable = "Disable" EndIf If showCocoaEnable = "Press" Then Var showCocoaEnable = "Disable" EndIf If showStrawberryEnable = "Enable" Then Var showStrawberryEnable = "Disable" EndIf If showStrawberryEnable = "Press" Then Var showStrawberryEnable = "Disable" EndIf If showYuzuEnable = "Enable" Then Var showYuzuEnable = "Disable" EndIf If showYuzuEnable = "Press" Then Var showYuzuEnable = "Disable" EndIf If TOPPING11 = "milk-level" Then If CustomMilkState[0] = "Disable" Then Var CustomMilkState[0] = "Enable" EndIf If CustomMilkState[1] = "Disable" Then Var CustomMilkState[1] = "Enable" EndIf If CustomMilkState[2] = "Disable" Then Var CustomMilkState[2] = "Enable" EndIf If CustomMilkState[0] = "Enable" Then If CustomMilkState[1] = "Enable" Then If CustomMilkState[2] = "Enable" Then Var CustomMilkState[1] = "PressForever" Then EndIf EndIf EndIf Else Var CustomMilkState[0] = "Disable" Var CustomMilkState[1] = "Disable" Var CustomMilkState[2] = "Disable" EndIf Var SelectToppingType = 1 EndIf ; i f cold menu disable away If cold_button_state = "PressForever" Then If showOreoAddEnable = "Enable" Then Var showOreoAddEnable = "Disable" EndIf If showOreoAddEnable = "Press" Then Var showOreoAddEnable = "Disable" EndIf If showOvaltineEnable = "Enable" Then Var showOvaltineEnable = "Disable" EndIf If showOvaltineEnable = "Press" Then Var showOvaltineEnable = "Disable" EndIf If showCocoaEnable = "Enable" Then Var showCocoaEnable = "Disable" EndIf If showCocoaEnable = "Press" Then Var showCocoaEnable = "Disable" EndIf If showStrawberryEnable = "Enable" Then Var showStrawberryEnable = "Disable" EndIf If showStrawberryEnable = "Press" Then Var showStrawberryEnable = "Disable" EndIf If showYuzuEnable = "Enable" Then Var showYuzuEnable = "Disable" EndIf If showYuzuEnable = "Press" Then Var showYuzuEnable = "Disable" EndIf If CustomMilkState[0] = "Enable" Then Var CustomMilkState[0] = "Disable" EndIf If CustomMilkState[1] = "Enable" Then Var CustomMilkState[1] = "Disable" EndIf If CustomMilkState[2] = "Enable" Then Var CustomMilkState[2] = "Disable" EndIf If CustomMilkState[0] = "PressForever" Then Var CustomMilkState[0] = "Disable" EndIf If CustomMilkState[1] = "PressForever" Then Var CustomMilkState[1] = "Disable" EndIf If CustomMilkState[2] = "PressForever" Then Var CustomMilkState[2] = "Disable" EndIf If CustomMilkState[0] = "Enable" Then If CustomMilkState[1] = "Enable" Then If CustomMilkState[2] = "Enable" Then Var CustomMilkState[1] = "PressForever" Then EndIf EndIf EndIf Var SelectToppingType = 1 EndIf ; first time. If blend_button_state = "PressForever" Then If TOPPING11 = "milk-level" Then If CustomMilkState[0] = "Disable" Then Var CustomMilkState[0] = "Enable" EndIf If CustomMilkState[1] = "Disable" Then Var CustomMilkState[1] = "Enable" EndIf If CustomMilkState[2] = "Disable" Then Var CustomMilkState[2] = "Enable" EndIf If CustomMilkState[0] = "Enable" Then If CustomMilkState[1] = "Enable" Then If CustomMilkState[2] = "Enable" Then Var CustomMilkState[1] = "PressForever" Then EndIf EndIf EndIf Else Var CustomMilkState[0] = "Disable" Var CustomMilkState[1] = "Disable" Var CustomMilkState[2] = "Disable" EndIf ;Var SelectToppingType = 0 ;Var SelectedToppingCount = 0 Else If SubMenuGroupIDSlot6_1 = 300 Then If TOPPING6 = "all-volcano" Then Var showOreoAddEnable = "Disable" Var showOvaltineEnable = "Disable" Var showCocoaEnable = "Disable" Var showYuzuEnable = "Disable" Var showStrawberryEnable = "Disable" Var showText8 = "Enable" EndIf If TOPPING6 = "Topping-Volcano" Then Var showOreoAddEnable = "Disable" Var showOvaltineEnable = "Invisible" Var showCocoaEnable = "Invisible" EndIf Var ExtraTopping = "Enable" EndIf EndIf STRCONTAIN "9701" BrewParam IgnoreLidStraw DEBUGVAR BrewParam DEBUGVAR IgnoreLidStraw Var h_block_of_sugar = 210 If IgnoreLidStraw = "true" Then Var IgnoreLidStraw = "false" Var ShowLidStraw = "Invisible" Var ShowLidOnly = "Invisible" Var ShowStrawOnly = "Invisible" Else Var ShowLidStraw = "Enable" If StrawState = "Enable" Then If MAT_ID_9701 = "Enable" Then Var StrawState = MAT_ID_9701 Else Var StrawState = MAT_ID_9701 EndIf EndIf DEBUGVAR MAT_ID_9701 DEBUGVAR StrawState If StrawState = "Press" Then Var Seeker.thankStrawFlag = 1 Else Var Seeker.thankStrawFlag = 0 EndIf If LidState = "Enable" Then If MAT_ID_9601 = "Enable" Then Var LidState = "Enable" Else Var LidState = "Disable" EndIf EndIf EndIf ; Override all If Service_LidStraw = "Disable" Then Var ShowLidStraw = "Enable" ;Var ShowLidOnly = "Invisible" ;Var ShowStawOnly = "Invisible" ;Var StrawState = "Disable" ;Var LidState = "Disable" EndIf If StrawState = "Enable" Then Var StrawDeactiveButton = "Invisible" Else If StrawState = "Press" Then Var StrawDeactiveButton = "Invisible" Else Var StrawDeactiveButton = "Enable" EndIf EndIf If LidState = "Enable" Then Var LidDeactiveButton = "Invisible" Else If LidState = "Press" Then Var LidDeactiveButton = "Invisible" Else Var LidDeactiveButton = "Enable" EndIf EndIf If UserSeletedSugar = 0 Then If SugarModeUpdateWhenChangeDrinkType = 1 Then Var SugarModeUpdateWhenChangeDrinkType = 0 RefreshAll Else Var CustomSweetState[0] = "Enable" Var CustomSweetState[1] = "Enable" Var CustomSweetState[2] = "Enable" Var CustomSweetState[3] = "Enable" Var CustomSweetState[4] = "Enable" Var CustomSweetState[5] = "Enable" EndIf Var sugar_default_flag = 0 ; Suger 4 step cold If TOPPING1 = "Suger 4 step cold" Then Var SugarZeroCalOption = "Enable" Var BGSugar = "Invisible" Var ShiftSugarStep = 1 Var CustomSweetState[0] = "Enable" Var CustomSweetState[1] = "Enable" Var CustomSweetState[2] = "Enable" Var CustomSweetState[3] = "Enable" If toppingID1index1 = toppingID1Default Then Var CustomSweetState[0] = "PressForever" Var sugar_default_flag = 1 ; select no sugar Var SugarZeroCalCheck = "Disable" EndIf If toppingID1index2 = toppingID1Default Then Var CustomSweetState[1] = "PressForever" Var sugar_default_flag = 1 EndIf If toppingID1index3 = toppingID1Default Then Var CustomSweetState[2] = "PressForever" Var sugar_default_flag = 1 EndIf If toppingID1index4 = toppingID1Default Then Var CustomSweetState[3] = "PressForever" Var sugar_default_flag = 1 EndIf ; No 2 right steps ;If NoSugarStepRight2 = "true" Then ; Var CustomSweetState[4] = "Disable" ; Var CustomSweetState[5] = "Disable" ;EndIf If sugar_default_flag = 0 Then Var CustomSweetState[0] = "PressForever" ; select no sugar Var SugarZeroCalCheck = "Disable" EndIf EndIf ; Suger 4 step hot If TOPPING1 = "Suger 4 step hot" Then Var SugarZeroCalOption = "Enable" Var BGSugar = "Invisible" Var ShiftSugarStep = 1 Var CustomSweetState[0] = "Enable" Var CustomSweetState[1] = "Enable" Var CustomSweetState[2] = "Enable" Var CustomSweetState[3] = "Enable" If toppingID1index1 = toppingID1Default Then Var CustomSweetState[0] = "PressForever" Var sugar_default_flag = 1 ; select no sugar Var SugarZeroCalCheck = "Disable" EndIf If toppingID1index2 = toppingID1Default Then Var CustomSweetState[1] = "PressForever" Var sugar_default_flag = 1 EndIf If toppingID1index3 = toppingID1Default Then Var CustomSweetState[2] = "PressForever" Var sugar_default_flag = 1 EndIf If toppingID1index4 = toppingID1Default Then Var CustomSweetState[3] = "PressForever" Var sugar_default_flag = 1 EndIf ; No 2 right steps ;If NoSugarStepRight2 = "true" Then ; Var CustomSweetState[4] = "Disable" ; Var CustomSweetState[5] = "Disable" ;EndIf If sugar_default_flag = 0 Then Var CustomSweetState[0] = "PressForever" ; select no sugar Var SugarZeroCalCheck = "Disable" EndIf EndIf DEBUGVAR RecipeTag2 ; If TOPPING1 = "Sugar" Then Var SugarZeroCalOption = "Enable" If RecipeTag2 = "Topping6Step" Then Var BGSugar = "Invisible" Var BGSugarNew = "Enable" Else Var BGSugar = "Enable" EndIf Var ShiftSugarStep = 1 Var CustomSweetState[0] = "Enable" Var CustomSweetState[1] = "Enable" Var CustomSweetState[2] = "Enable" Var CustomSweetState[3] = "Enable" Var CustomSweetState[4] = "Enable" If toppingID1index1 = toppingID1Default Then Var CustomSweetState[0] = "PressForever" Var sugar_default_flag = 1 EndIf If toppingID1index2 = toppingID1Default Then Var CustomSweetState[1] = "PressForever" Var sugar_default_flag = 1 EndIf If toppingID1index3 = toppingID1Default Then Var CustomSweetState[2] = "PressForever" Var sugar_default_flag = 1 EndIf If toppingID1index4 = toppingID1Default Then Var CustomSweetState[3] = "PressForever" Var sugar_default_flag = 1 EndIf If toppingID1index5 = toppingID1Default Then Var CustomSweetState[4] = "PressForever" Var sugar_default_flag = 1 EndIf ; No 2 right steps If NoSugarStepRight2 = "true" Then If RecipeTag2 = "Topping6Step" Then Var CustomSweetState[4] = "Disable" Var CustomSweetState[5] = "Disable" Else Var CustomSweetState[4] = "Disable" EndIf EndIf If sugar_default_flag = 0 Then Var CustomSweetState[0] = "PressForever" EndIf EndIf If TOPPING1 = "Powder Sugar for Hot" Then Var SugarZeroCalOption = "Enable" If RecipeTag2 = "Topping6Step" Then Var BGSugar = "Invisible" Var BGSugarNew = "Enable" Else Var BGSugar = "Enable" EndIf Var ShiftSugarStep = 1 Var CustomSweetState[0] = "Enable" Var CustomSweetState[1] = "Enable" Var CustomSweetState[2] = "Enable" Var CustomSweetState[3] = "Enable" Var CustomSweetState[4] = "Enable" If toppingID1index1 = toppingID1Default Then Var CustomSweetState[0] = "PressForever" Var sugar_default_flag = 1 EndIf If toppingID1index2 = toppingID1Default Then Var CustomSweetState[1] = "PressForever" Var sugar_default_flag = 1 EndIf If toppingID1index3 = toppingID1Default Then Var CustomSweetState[2] = "PressForever" Var sugar_default_flag = 1 EndIf If toppingID1index4 = toppingID1Default Then Var CustomSweetState[3] = "PressForever" Var sugar_default_flag = 1 EndIf If toppingID1index5 = toppingID1Default Then Var CustomSweetState[4] = "PressForever" Var sugar_default_flag = 1 EndIf ; No 2 right steps If NoSugarStepRight2 = "true" Then If RecipeTag2 = "Topping6Step" Then Var CustomSweetState[4] = "Disable" Var CustomSweetState[5] = "Disable" Else Var CustomSweetState[4] = "Disable" EndIf EndIf If sugar_default_flag = 0 Then Var CustomSweetState[0] = "PressForever" EndIf EndIf If TOPPING1 = "Powder Sugar" Then Var SugarZeroCalOption = "Enable" If RecipeTag2 = "Topping6Step" Then Var BGSugar = "Invisible" Var BGSugarNew = "Enable" Else Var BGSugar = "Enable" EndIf Var ShiftSugarStep = 1 Var CustomSweetState[0] = "Enable" Var CustomSweetState[1] = "Enable" Var CustomSweetState[2] = "Enable" Var CustomSweetState[3] = "Enable" Var CustomSweetState[4] = "Enable" Var CustomSweetState[5] = "Enable" DEBUGVAR "set default Powder Sugar" If toppingID1index1 = toppingID1Default Then Var CustomSweetState[0] = "PressForever" Var sugar_default_flag = 1 EndIf If toppingID1index2 = toppingID1Default Then Var CustomSweetState[1] = "PressForever" Var sugar_default_flag = 1 EndIf If toppingID1index3 = toppingID1Default Then Var CustomSweetState[2] = "PressForever" Var sugar_default_flag = 1 EndIf If toppingID1index4 = toppingID1Default Then Var CustomSweetState[3] = "PressForever" Var sugar_default_flag = 1 EndIf If toppingID1index5 = toppingID1Default Then Var CustomSweetState[4] = "PressForever" Var sugar_default_flag = 1 EndIf ; No 2 right steps If NoSugarStepRight2 = "true" Then If RecipeTag2 = "Topping6Step" Then Var CustomSweetState[4] = "Disable" Var CustomSweetState[5] = "Disable" Else Var CustomSweetState[4] = "Disable" EndIf EndIf If sugar_default_flag = 0 Then Var CustomSweetState[0] = "PressForever" EndIf DEBUGVAR toppingID1Default DEBUGVAR CustomSweetState[0] EndIf If TOPPING1 = "Sugar Premix 25" Then Var SugarZeroCalOption = "Enable" If RecipeTag2 = "Topping6Step" Then Var BGSugar = "Invisible" Var BGSugarNew = "Enable" Else Var BGSugar = "Enable" EndIf Var ShiftSugarStep = 2 Var CustomSweetState[0] = "Disable" Var CustomSweetState[1] = "Enable" Var CustomSweetState[2] = "Enable" Var CustomSweetState[3] = "Enable" Var CustomSweetState[4] = "Enable" Var CustomSweetState[5] = "Enable" If toppingID1index1 = toppingID1Default Then Var CustomSweetState[1] = "PressForever" Var sugar_default_flag = 1 EndIf If toppingID1index2 = toppingID1Default Then Var CustomSweetState[2] = "PressForever" Var sugar_default_flag = 1 ; select no sugar Var SugarZeroCalCheck = "Disable" EndIf If toppingID1index3 = toppingID1Default Then Var CustomSweetState[3] = "PressForever" Var sugar_default_flag = 1 EndIf If toppingID1index4 = toppingID1Default Then Var CustomSweetState[4] = "PressForever" Var sugar_default_flag = 1 EndIf ; No 2 right steps If NoSugarStepRight2 = "true" Then Var CustomSweetState[4] = "Disable" Var CustomSweetState[5] = "Disable" EndIf If sugar_default_flag = 0 Then Var CustomSweetState[1] = "PressForever" EndIf EndIf If TOPPING1 = "Powder Sugar Premix 50" Then Var SugarZeroCalOption = "Enable" If RecipeTag2 = "Topping6Step" Then Var BGSugar = "Invisible" Var BGSugarNew = "Enable" Else Var BGSugar = "Enable" EndIf Var ShiftSugarStep = 3 Var CustomSweetState[0] = "Disable" Var CustomSweetState[1] = "Disable" If RecipeTag2 = "Topping6Step" Then Var CustomSweetState[2] = "Disable" Else Var CustomSweetState[2] = "Enable" EndIf Var CustomSweetState[3] = "Enable" Var CustomSweetState[4] = "Enable" Var CustomSweetState[5] = "Enable" If toppingID1index1 = toppingID1Default Then Var CustomSweetState[2] = "PressForever" Var sugar_default_flag = 1 EndIf If toppingID1index2 = toppingID1Default Then Var CustomSweetState[3] = "PressForever" Var sugar_default_flag = 1 ; select no sugar If SugarZeroCalCheck = "Disable2" Then Else Var SugarZeroCalCheck = "Disable" EndIf EndIf If toppingID1index3 = toppingID1Default Then Var CustomSweetState[4] = "PressForever" Var sugar_default_flag = 1 If SugarZeroCalCheck = "Disable2" Then Else Var SugarZeroCalCheck = "Disable" EndIf EndIf ; No 2 right steps If NoSugarStepRight2 = "true" Then If RecipeTag2 = "Topping6Step" Then Var CustomSweetState[4] = "Disable" Var CustomSweetState[5] = "Disable" Else Var CustomSweetState[4] = "Disable" EndIf EndIf If sugar_default_flag = 0 Then Var CustomSweetState[2] = "PressForever" EndIf EndIf If TOPPING1 = "Powder Sugar Premix 25" Then Var SugarZeroCalOption = "Enable" If RecipeTag2 = "Topping6Step" Then Var BGSugar = "Invisible" Var BGSugarNew = "Enable" Else Var BGSugar = "Enable" EndIf Var ShiftSugarStep = 2 Var CustomSweetState[1] = "Enable" Var CustomSweetState[2] = "Enable" Var CustomSweetState[3] = "Enable" Var CustomSweetState[4] = "Enable" If toppingID1index1 = toppingID1Default Then Var CustomSweetState[1] = "PressForever" Var sugar_default_flag = 1 EndIf If toppingID1index2 = toppingID1Default Then Var CustomSweetState[2] = "PressForever" Var sugar_default_flag = 1 ; select no sugar Var SugarZeroCalCheck = "Disable" EndIf If toppingID1index3 = toppingID1Default Then Var CustomSweetState[3] = "PressForever" Var sugar_default_flag = 1 EndIf If toppingID1index4 = toppingID1Default Then Var CustomSweetState[4] = "PressForever" Var sugar_default_flag = 1 EndIf ; No 2 right steps If NoSugarStepRight2 = "true" Then If RecipeTag2 = "Topping6Step" Then Var CustomSweetState[4] = "Disable" Var CustomSweetState[5] = "Disable" Else Var CustomSweetState[4] = "Disable" EndIf EndIf If sugar_default_flag = 0 Then Var CustomSweetState[1] = "PressForever" EndIf EndIf Var SugarModeUpdateWhenChangeDrinkType = 0 If TOPPING1 = "Suger 4 step cold" Then Var BGSugarColdHealthy = "Enable" Var BGSugarHotHealthy = "Invisible" Var ShiftSugarStep = 1 Var SugarModeUpdateWhenChangeDrinkType = 1 If MAT_ID_1215 = "Disable" Then Var SugarZeroCalCheck = "Disable2" EndIf EndIf If TOPPING1 = "Suger 4 step hot" Then Var BGSugarHotHealthy = "Enable" Var BGSugarColdHealthy = "Invisible" Var ShiftSugarStep = 1 Var SugarModeUpdateWhenChangeDrinkType = 1 If MAT_ID_1215 = "Disable" Then Var SugarZeroCalCheck = "Disable2" EndIf EndIf ; Sugar Zero Cal DEBUGVAR SugarZeroCalEnable DEBUGVAR SugarZeroCalCheck If SugarZeroCalEnable = "true" Then Var SugarZeroCalPrice = 10 Var priceFormat = "(+฿%.0f)" Var SugarZeroCalState = "Invisible" Var SugarZeroCalFreeState = "Invisible" If SugarZeroCalFreeFlag = 1 Then Var SugarZeroCalFreeState = "Enable" Var SugarZeroCalPrice = 0 Else Var SugarZeroCalState = "Enable" Var SugarZeroCalPriceStr !assigned StringFmt( SugarZeroCalPrice , priceFormat, PreScaleConvertShow) EndIf Var SugarNormalCheck = "PressForever" Else Var SugarZeroCalOption = "Invisible" EndIf Var ShowCollagenOnly = "Enable" Var BugFlag = 1 Var topping1 = toppingID1Default Var ToppingGotoPayment = "false" Var SugarSoundFlag = 0 If BGSugarNew = "Enable" Then Var SugarSoundFlag = 1 EndIf If BGSugar = "Enable" Then Var SugarSoundFlag = 1 EndIf If SugarSoundFlag = 1 Then If SelectDrinkType = 1 Then If show_eng = "true" Then Play "/mnt/sdcard/coffeevending/taobin_project/sound_eng/Sweet.mp3" Else Var PlaySoundLag = "/mnt/sdcard/coffeevending/taobin_project/sound_thai/select_level.mp3" ; Play Sound #zone If LipitPro = 1 Then Var PlaySoundLag = "/mnt/sdcard/coffeevending/taobin_project/sound_thai/lipit/select_level.wav" EndIf Play PlaySoundLag EndIf EndIf EndIf DEBUGVAR SelectDrinkType If SelectDrinkType = 0 Then Var CustomSweetState[0] = "Enable" Var CustomSweetState[1] = "Enable" Var CustomSweetState[2] = "Enable" Var CustomSweetState[3] = "Enable" Var CustomSweetState[4] = "Enable" EndIf Else EndIf ; End of UserSeletedSugar = 0 Refresh Var collagenShow = "true" ;-BEGIN shot layout If topping_price_refresh = 1 Then Var topping_price_refresh = 0 Var topping3 = toppingID3Default Var shot_h_layout = 218 If TOPPING2 = "shot coffee" Then Var ShotCoffeeBG = "Enable" Var showShotEnable = "Enable" Var ExtraTopping = "Enable" Var toppingID2price2Conv !assigned StringFmt( toppingID2price2 , DisplayFormat, PreScaleConvertShow) DEBUGVAR toppingID2price2Conv Var text_shot_normal_add = toppingID2price2Conv + ")" Var text_shot_normal_add = "(+" + text_shot_normal_add Refresh EndIf If TOPPING2 = "shot coffee termtem" Then Var ShotCoffeeBG = "Enable" Var showShotEnable = "Enable" Var ExtraTopping = "Enable" DEBUGVAR TOPPING2 Refresh EndIf If TOPPING2 = "shot coffee 1003" Then If toppingID2index3 = "" Then Var ShotCoffeePremium = "Enable" Var showShotEnable = "Invisible" Var ExtraTopping = "Enable" Else Var EnableLightRoast = "Enable" EndIf DEBUGVAR TOPPING2 Refresh EndIf If TOPPING2 = "shot coffee 1007" Then If toppingID2index3 = "" Then Var ShotCoffeePremium = "Enable" Var showShotEnable = "Invisible" Var ExtraTopping = "Enable" Else Var EnableLightRoast = "Enable" EndIf DEBUGVAR TOPPING2 Refresh EndIf If TOPPING2 = "shot coffee 1008" Then If toppingID2index3 = "" Then Var ShotCoffeePremium = "Enable" Var showShotEnable = "Invisible" Var ExtraTopping = "Enable" Else Var EnableLightRoast = "Enable" EndIf DEBUGVAR TOPPING2 Refresh EndIf If TOPPING2 = "add-show-1009" Then If toppingID2index3 = "" Then Var ShotCoffeePremium = "Enable" Var showShotEnable = "Invisible" Var ExtraTopping = "Enable" Else Var EnableLightRoast = "Enable" EndIf DEBUGVAR TOPPING2 Refresh EndIf If TOPPING2 = "add-show-1101" Then If toppingID2index3 = "" Then Var ShotCoffeePremium = "Enable" Var showShotEnable = "Invisible" Var ExtraTopping = "Enable" Else Var EnableLightRoast = "Enable" EndIf DEBUGVAR TOPPING2 Refresh EndIf If TOPPING2 = "add-show-1102" Then If toppingID2index3 = "" Then Var ShotCoffeePremium = "Enable" Var showShotEnable = "Invisible" Var ExtraTopping = "Enable" Else Var EnableLightRoast = "Enable" EndIf DEBUGVAR TOPPING2 Refresh EndIf If TOPPING2 = "add-show-1103" Then If toppingID2index3 = "" Then Var ShotCoffeePremium = "Enable" Var showShotEnable = "Invisible" Var ExtraTopping = "Enable" Else Var EnableLightRoast = "Enable" EndIf DEBUGVAR TOPPING2 Refresh EndIf If TOPPING2 = "add-show-1104" Then If toppingID2index3 = "" Then Var ShotCoffeePremium = "Enable" Var showShotEnable = "Invisible" Var ExtraTopping = "Enable" Else Var EnableLightRoast = "Enable" EndIf DEBUGVAR TOPPING2 Refresh EndIf If TOPPING2 = "add-show-1105" Then If toppingID2index3 = "" Then Var ShotCoffeePremium = "Enable" Var showShotEnable = "Invisible" Var ExtraTopping = "Enable" Else Var EnableLightRoast = "Enable" EndIf DEBUGVAR TOPPING2 Refresh EndIf If TOPPING2 = "add-show-1106" Then If toppingID2index3 = "" Then Var ShotCoffeePremium = "Enable" Var showShotEnable = "Invisible" Var ExtraTopping = "Enable" Else Var EnableLightRoast = "Enable" EndIf DEBUGVAR TOPPING2 Refresh EndIf If TOPPING2 = "add-show-1107" Then If toppingID2index3 = "" Then Var ShotCoffeePremium = "Enable" Var showShotEnable = "Invisible" Var ExtraTopping = "Enable" Else Var EnableLightRoast = "Enable" EndIf DEBUGVAR TOPPING2 Refresh EndIf If TOPPING2 = "add-show-1108" Then If toppingID2index3 = "" Then Var ShotCoffeePremium = "Enable" Var showShotEnable = "Invisible" Var ExtraTopping = "Enable" Else Var EnableLightRoast = "Enable" EndIf DEBUGVAR TOPPING2 Refresh EndIf If ShotCoffeePremium = "Enable" Then Var toppingID2price2Conv !assigned StringFmt( toppingID2price2 , DisplayFormat, PreScaleConvertShow) DEBUGVAR toppingID2price2Conv Var text_price_topping = toppingID2price2Conv + ")" Var text_price_topping = "(+" + text_price_topping EndIf If EnableLightRoast = "Enable" Then Var CustomCoffeeEnable = "True" Var showCustomCoffee = "Enable" var showCoffeeQuantity = "Enable" If toppingID2Default = "" Then Var CustomCoffeeQuantityState[1] = "PressForever" Else If toppingID2index1 = toppingID2Default Then Var CurrentCoffeeLevelId = toppingID2index1 Var CustomCoffeeQuantityState[0] = "PressForever" Var CustomCoffeeQuantityState[1] = "Enable" Var CustomCoffeeQuantityState[2] = "Enable" EndIf If toppingID2index2 = toppingID2Default Then Var CurrentCoffeeLevelId = toppingID2index2 Var CustomCoffeeQuantityState[0] = "Enable" Var CustomCoffeeQuantityState[1] = "PressForever" Var CustomCoffeeQuantityState[2] = "Enable" EndIf If toppingID2index3 = toppingID2Default Then Var CurrentCoffeeLevelId = toppingID2index3 Var CustomCoffeeQuantityState[0] = "Enable" Var CustomCoffeeQuantityState[1] = "Enable" Var CustomCoffeeQuantityState[2] = "PressForever" EndIf EndIf If toppingID2price1 > 0 Then Var priceFormated !assigned StringFmt( toppingID2price1 , PriceCustomCoffeeFormat, PreScaleConvertShow) Var CustomCoffeeQuantityAdditionalPrice[0] = "(+" + priceFormated Var CustomCoffeeQuantityAdditionalPrice[0] = CustomCoffeeQuantityAdditionalPrice[0] + ")" Else Var CustomCoffeeQuantityAdditionalPrice[0] = "" EndIf If toppingID2price2 > 0 Then Var priceFormated !assigned StringFmt( toppingID2price2 , PriceCustomCoffeeFormat, PreScaleConvertShow) Var CustomCoffeeQuantityAdditionalPrice[1] = "(+" + priceFormated Var CustomCoffeeQuantityAdditionalPrice[1] = CustomCoffeeQuantityAdditionalPrice[1] + ")" Else Var CustomCoffeeQuantityAdditionalPrice[1] = "" EndIf If toppingID2price3 > 0 Then Var priceFormated !assigned StringFmt( toppingID2price3 , PriceCustomCoffeeFormat, PreScaleConvertShow) Var CustomCoffeeQuantityAdditionalPrice[2] = "(+" + priceFormated Var CustomCoffeeQuantityAdditionalPrice[2] = CustomCoffeeQuantityAdditionalPrice[2] + ")" Else Var CustomCoffeeQuantityAdditionalPrice[2] = "" EndIf EndIf ;-END EndIf ;topping_price_refresh = 0 If MenuCodeName1 = "OatMilk" Then Var OatMilkToppingEnable = "Enable" ;SubMenuPrice1 ignore. Fix by xml Var OatMilkPrice = "(+5)" If MenuCodeName1_State = "Enable" Then Var OatMilkEnable = "Enable" EndIf EndIf SAVELOG ToppingGotoPayment If ToppingGotoPayment = "true" Then Topping "Select" SelectDrink ; Pack Topping "Pack" ExtendDataCurr Var Seeker.ExtendDataCurr = ExtendDataCurr If RestrictedDrink = "true" Then DEBUGVAR RestrictedDrink ;OpenInst 1 "/mnt/sdcard/coffeevending/taobin_project/xml/page_blank.xml" Open "ROOT/taobin_project/xml/page_identity_verification.xml" Else ;OpenInst 1 "/mnt/sdcard/coffeevending/taobin_project/xml/page_blank.xml" Open "ROOT/taobin_project/xml/ .xml" EndIf EndIf If RoadShow = "true" Then Var PriceShowValue = "Free" Var ModeFreeEnable = 1 Else Var ModeFreeEnable = 0 EndIf If DisableAllNotFreeTopping = 1 Then Var SugarZeroCalOption = "Invisible" Var showCustomCoffee = "Invisible" Var CustomCoffeeEnable = "False" Var ExtraTopping = "Invisible" EndIf DEBUGVAR showShotEnable DEBUGVAR showOreoAddEnable DEBUGVAR ShotCoffeePremium DEBUGVAR toppingID2price1 DEBUGVAR toppingID2price2 DEBUGVAR toppingID2price3 DEBUGVAR toppingID9price1 DEBUGVAR toppingID9price2 DEBUGVAR toppingID9price3 DEBUGVAR toppingID9price4 DEBUGVAR ShiftSugarStep Var CustomCoffeeQuantityAdditionalPrice = "(25฿)" TRY "/mnt/sdcard/coffeevending/taobin_project/flash_deal/topping_page.ev" Function 2 EndIf DEBUGVAR ExtraTopping ;Var BugFlag = 1 If CartUpdate = "true" Then Var CartUpdate = "-" If CART_COUNT = 3 Then OpenInst 1 "/mnt/sdcard/coffeevending/taobin_project/xml/page_blank.xml" Open "ROOT/taobin_project/xml/page_payment_multi.xml" Else If ButtonNext = "true" Then OpenInst 1 "/mnt/sdcard/coffeevending/taobin_project/xml/page_blank.xml" Open "ROOT/taobin_project/xml/page_payment_multi.xml" Else OpenInst 1 "/mnt/sdcard/coffeevending/taobin_project/xml/page_advert.xml" Open "ROOT/taobin_project/xml/page_catalog.xml" EndIf EndIf EndIf ; same 45 402 291 396 PictureDrink ; back 374 422 eval( If IsSmoRet = "true" Then Var return = "Enable" Else Var return = "Invisible" EndIf ) "ROOT/taobin_project/image/topping2/blender_icon.png" ; same 330 470 344 50 Auto 2 KanitMediumTTF 0x513C2F showname 330 CustomShowDescTextY 344 24 KanitLightTTF 0x6F5F51 showdesc ; ; ; ; ; ; ; ; ; ; ;-BEGIN ; ;-BEGIN Lid straw 690 460 350 195 Var( DirImage + "/topping_revamp/bg_strawlid.png" ) ; straw left ; LID left LidDeactiveButton 665 480 Var( DirImage + "/text21.png" ) StrawDeactiveButton 665 563 Var( DirImage + "/text20.png" ) ;-END ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ;- FRAME SCORELLL ; zone scroll 52 680 1080 1080 1080 "Vertical" 1 ; show_select_type 988 162 20 show_select_type Var( DirImage + "/drink_select_type.png" ) 552 85 KanitRegularTTF 23 text_hot_color text_price_d1 710 85 KanitRegularTTF 23 text_cold_color text_price_d2 852 85 KanitRegularTTF 23 text_show_thai text_blender_color text_price_d3 872 85 KanitRegularTTF text_show_eng 23 text_blender_color text_price_d3 ;-END ; ; ; ; ; ; ; ; TEST - BEGIN Custom recipe "Enable" 1080 "auto" 20 986 "auto" "vertical" "Enable" ; ; ; ; ; 986 64 "Enable" Var( DirImage + "/topping_revamp/bg_top_custom_recipe.png" ) ; ; ;- Begin topping1 986 "auto" BGSugar 0 0 ExtraTopping Var( DirImage + "/topping_revamp/bg_custom_sweet_level.png" ) ; sugar1 ; sugar2 ; sugar3 ; sugar4 ; sugar5 ; sugar6 CustomSweetNotTextX CustomSweetTextY KanitRegularTTF CustomSweetState[0] 16 0x513C2F CustomSweetrText[0] CustomSweetNotPercentTextX CustomSweetPercentTextY KanitRegularTTF CustomSweetState[0] 14 0x84776F CustomSweetrPercent[0] CustomSweetLittleTextX CustomSweetTextY KanitRegularTTF CustomSweetState[1] 16 0x513C2F CustomSweetrText[1] CustomSweetLittlePercentTextX CustomSweetPercentTextY KanitRegularTTF CustomSweetState[1] 14 0x84776F CustomSweetrPercent[1] CustomSweetLessTextX CustomSweetTextY KanitRegularTTF CustomSweetState[2] 16 0x513C2F CustomSweetrText[2] CustomSweetLessPercentTextX CustomSweetPercentTextY KanitRegularTTF CustomSweetState[2] 14 0x84776F CustomSweetrPercent[2] CustomSweetPerfectTextX CustomSweetPercentTextY KanitRegularTTF CustomSweetState[3] 16 0x513C2F CustomSweetrText[3] CustomSweetPerfectPercentTextX CustomSweetPercentTextY KanitRegularTTF CustomSweetState[3] 14 0x84776F CustomSweetrPercent[3] CustomSweetExtraTextX CustomSweetTextY KanitRegularTTF CustomSweetState[4] 16 0x513C2F CustomSweetrText[4] CustomSweetExtraPercentTextX CustomSweetPercentTextY KanitRegularTTF CustomSweetState[4] 14 0x84776F CustomSweetrPercent[4] CustomSweetestTextX CustomSweetTextY KanitRegularTTF CustomSweetState[5] 16 0x513C2F CustomSweetrText[5] CustomSweetestPercentTextX CustomSweetPercentTextY KanitRegularTTF CustomSweetState[5] 14 0x84776F CustomSweetrPercent[5] ; Sugar zero cal in new topping for BGSugarNew and BGMilkNew 986 "auto" eval( If SugarZeroCalOption = "Enable" Then If BGSugarNew = "Enable" Then Var return = "Enable" Else If BGMilkNew = "Enable" Then Var return = "Enable" Else Var return = "Invisible" EndIf EndIf Else Var return = "Invisible" EndIf ) 0 0 "Enable" Var( DirImageInter + "/bg_custom_sweet_level_zero_cal.png" ) 130 15 500 46 002029 ; Normal Sugar ; Sugar Zero Cal 800 50 250 20 002056 800 67 15 50 20 KanitRegularTTF 0x84776F "(Free)" 890 50 250 20 002057 905 67 15 50 20 KanitRegularTTF 0x84776F SugarZeroCalPriceStr ;- Begin topping new without sugar zero cal 986 "auto" eval( If SugarZeroCalOption = "Enable" Then Var return = "Invisible" Else If BGSugarNew = "Enable" Then Var return = "Enable" Else Var return = "Invisible" EndIf EndIf ) 0 0 "Enable" Var( DirImage + "/topping_revamp/bg_custom_sweet_level.png" ) ; sugar1 ; sugar2 ; sugar3 ; sugar4 ; sugar5 ; sugar6 CustomSweetNotTextX CustomSweetTextY KanitRegularTTF CustomSweetState[0] 16 0x513C2F CustomSweetrText[0] CustomSweetNotPercentTextX CustomSweetPercentTextY KanitRegularTTF CustomSweetState[0] 14 0x84776F CustomSweetrPercent[0] CustomSweetLittleTextX CustomSweetTextY KanitRegularTTF CustomSweetState[1] 16 0x513C2F CustomSweetrText[1] CustomSweetLittlePercentTextX CustomSweetPercentTextY KanitRegularTTF CustomSweetState[1] 14 0x84776F CustomSweetrPercent[1] CustomSweetLessTextX CustomSweetTextY KanitRegularTTF CustomSweetState[2] 16 0x513C2F CustomSweetrText[2] CustomSweetLessPercentTextX CustomSweetPercentTextY KanitRegularTTF CustomSweetState[2] 14 0x84776F CustomSweetrPercent[2] CustomSweetPerfectTextX CustomSweetPercentTextY KanitRegularTTF CustomSweetState[3] 16 0x513C2F CustomSweetrText[3] CustomSweetPerfectPercentTextX CustomSweetPercentTextY KanitRegularTTF CustomSweetState[3] 14 0x84776F CustomSweetrPercent[3] CustomSweetExtraTextX CustomSweetTextY KanitRegularTTF CustomSweetState[4] 16 0x513C2F CustomSweetrText[4] CustomSweetExtraPercentTextX CustomSweetPercentTextY KanitRegularTTF CustomSweetState[4] 14 0x84776F CustomSweetrPercent[4] CustomSweetestTextX CustomSweetTextY KanitRegularTTF CustomSweetState[5] 16 0x513C2F CustomSweetrText[5] CustomSweetestPercentTextX CustomSweetPercentTextY KanitRegularTTF CustomSweetState[5] 14 0x84776F CustomSweetrPercent[5] ;- Begin topping new withsugar zero cal 986 "auto" eval( If SugarZeroCalOption = "Enable" Then If BGSugarNew = "Enable" Then Var return = "Enable" Else Var return = "Invisible" EndIf Else Var return = "Invisible" EndIf ) 0 0 "Enable" Var( DirImage + "/topping_revamp/bg_custom_sweet_level.png" ) ; sugar1 ; sugar2 ; sugar3 ; sugar4 ; sugar5 ; sugar6 CustomSweetNotTextX CustomSweetTextY KanitRegularTTF CustomSweetState[0] 16 0x513C2F CustomSweetrText[0] CustomSweetNotPercentTextX CustomSweetPercentTextY KanitRegularTTF CustomSweetState[0] 14 0x84776F CustomSweetrPercent[0] CustomSweetLittleTextX CustomSweetTextY KanitRegularTTF CustomSweetState[1] 16 0x513C2F CustomSweetrText[1] CustomSweetLittlePercentTextX CustomSweetPercentTextY KanitRegularTTF CustomSweetState[1] 14 0x84776F CustomSweetrPercent[1] CustomSweetLessTextX CustomSweetTextY KanitRegularTTF CustomSweetState[2] 16 0x513C2F CustomSweetrText[2] CustomSweetLessPercentTextX CustomSweetPercentTextY KanitRegularTTF CustomSweetState[2] 14 0x84776F CustomSweetrPercent[2] CustomSweetPerfectTextX CustomSweetPercentTextY KanitRegularTTF CustomSweetState[3] 16 0x513C2F CustomSweetrText[3] CustomSweetPerfectPercentTextX CustomSweetPercentTextY KanitRegularTTF CustomSweetState[3] 14 0x84776F CustomSweetrPercent[3] CustomSweetExtraTextX CustomSweetTextY KanitRegularTTF CustomSweetState[4] 16 0x513C2F CustomSweetrText[4] CustomSweetExtraPercentTextX CustomSweetPercentTextY KanitRegularTTF CustomSweetState[4] 14 0x84776F CustomSweetrPercent[4] CustomSweetestTextX CustomSweetTextY KanitRegularTTF CustomSweetState[5] 16 0x513C2F CustomSweetrText[5] CustomSweetestPercentTextX CustomSweetPercentTextY KanitRegularTTF CustomSweetState[5] 14 0x84776F CustomSweetrPercent[5] ; Sugar zero cal recipe for healthy 986 "auto" eval( If SugarZeroCalOption = "Enable" Then If BGSugarColdHealthy = "Enable" Then Var return = "Enable" Else If BGSugarHotHealthy = "Enable" Then Var return = "Enable" Else Var return = "Invisible" EndIf EndIf Else Var return = "Invisible" EndIf ) 0 0 "Enable" Var( DirImageInter + "/bg_custom_sweet_level_healthy_zero_cal.png" ) 130 15 500 46 002029 ; Normal Sugar ; Sugar Zero Cal 680 50 250 20 002056 "(Free)" 0x84776F 810 50 250 20 002057 SugarZeroCalPriceStr 0x84776F ; Sugar zero cal, Hot healthy, Then SugarZeroCalOption not enable 986 "auto" eval( If SugarZeroCalOption = "Enable" Then Var return = "Invisible" Else If BGSugarHotHealthy = "Enable" Then Var return = "Enable" Else Var return = "Invisible" EndIf EndIf ) 0 0 "Enable" Var( DirImageInter + "/bg_custom_sweet_level_healthy.png" ) 130 15 500 46 002030 ; sugar1 ; sugar2 ; sugar3 ; sugar4 380 50 250 20 002048 300 65 250 20 002052 530 50 250 20 0 0 002049 450 65 250 20 002053 670 50 250 20 0 0 002050 600 65 250 20 002054 840 50 250 20 0 0 002051 770 65 250 20 002055 986 "auto" BGSugarNew 0 0 Var( DirImage + "/topping_revamp/bg_custom_milk.png" ) 694 CustomEspressoTextY KanitRegularTTF CustomMilkState[0] 16 0x513C2F CustomMilkText[0] 804 CustomEspressoTextY KanitRegularTTF CustomMilkState[1] 16 0x513C2F CustomMilkText[1] 893 CustomEspressoTextY KanitRegularTTF CustomMilkState[2] 16 0x513C2F CustomMilkText[2] ; Additional Price 935 CustomEspressoTextY KanitRegularTTF CustomMilkState[2] 16 0x84776F MilkIncreasePriceText ; Sugar zero cal, Hot healthy, Then SugarZeroCalOption enable 986 "auto" eval( If SugarZeroCalOption = "Enable" Then If BGSugarHotHealthy = "Enable" Then Var return = "Enable" Else Var return = "Invisible" EndIf Else Var return = "Invisible" EndIf ) 0 0 "Enable" Var( DirImageInter + "/bg_custom_sweet_level_healthy.png" ) 130 15 500 46 002030 ; sugar1 ; sugar2 ; sugar3 ; sugar4 380 50 250 20 002048 300 65 250 20 002052 530 50 250 20 0 0 002049 450 65 250 20 002053 670 50 250 20 0 0 002050 600 65 250 20 002054 840 50 250 20 0 0 002051 770 65 250 20 002055 ; Sugar zero cal, Hot healthy, Then SugarZeroCalOption not enable 986 "auto" eval( If SugarZeroCalOption = "Enable" Then Var return = "Invisible" Else If BGSugarColdHealthy = "Enable" Then Var return = "Enable" Else Var return = "Invisible" EndIf EndIf ) 0 0 "Enable" Var( DirImageInter + "/bg_custom_sweet_level_healthy.png" ) 130 15 500 46 002030 ; sugar1 ; sugar2 ; sugar3 ; sugar4 380 50 250 20 002048 300 65 250 20 002052 530 50 250 20 0 0 002049 450 65 250 20 002053 670 50 250 20 0 0 002050 600 65 250 20 002054 840 50 250 20 0 0 002051 770 65 250 20 002055 ; Sugar zero cal, Hot healthy, Then SugarZeroCalOption enable 986 "auto" eval( If SugarZeroCalOption = "Enable" Then If BGSugarColdHealthy = "Enable" Then Var return = "Enable" Else Var return = "Invisible" EndIf Else Var return = "Invisible" EndIf ) 0 0 "Enable" Var( DirImageInter + "/bg_custom_sweet_level_healthy.png" ) 130 15 500 46 002030 ; sugar1 ; sugar2 ; sugar3 ; sugar4 380 50 250 20 002048 300 65 250 20 002052 530 50 250 20 0 0 002049 450 65 250 20 002053 670 50 250 20 0 0 002050 600 65 250 20 002054 840 50 250 20 0 0 002051 770 65 250 20 002055 986 "auto" showShotEnable 0 0 Var( DirImage + "/topping_revamp/bg_custom_espesso_level.png" ) 784 CustomEspressoTextY KanitRegularTTF showEspressoLevel 16 0x513C2F CustomEspressoText[1] 892 CustomEspressoTextY KanitRegularTTF showEspressoLevel 16 0x513C2F CustomEspressoText[2] ; Additional Price 830 CustomEspressoTextY KanitRegularTTF showEspressoLevel 16 0x84776F CoffeeTextLevel1 940 CustomEspressoTextY KanitRegularTTF showEspressoLevel 16 0x84776F CoffeeTextLevel2 986 "auto" showShotEnable 0 0 Var( DirImage + "/topping_revamp/bg_custom_energy_level.png" ) 784 CustomEspressoTextY KanitRegularTTF showEspressoLevel 16 0x513C2F CustomEspressoText[0] 892 CustomEspressoTextY KanitRegularTTF showEspressoLevel 16 0x513C2F CustomEspressoText[1] ; Additional Price 830 CustomEspressoTextY KanitRegularTTF showEspressoLevel 16 0x84776F EnergyTextLevel1 940 CustomEspressoTextY KanitRegularTTF showEspressoLevel 16 0x84776F EnergyTextLevel2 986 "auto" "Invisible" 0 0 Var( DirImage + "/topping_revamp/bg_custom_cocoa_level.png" ) 684 CustomEspressoTextY KanitRegularTTF showEspressoLevel 16 0x513C2F CustomCocoaText[0] 794 CustomEspressoTextY KanitRegularTTF showEspressoLevel 16 0x513C2F CustomCocoaText[1] 903 CustomEspressoTextY KanitRegularTTF showEspressoLevel 16 0x513C2F CustomCocoaText[2] 986 "auto" "Invisible" 0 0 Var( DirImage + "/topping_revamp/bg_custom_ovaltine.png" ) 674 CustomEspressoTextY KanitRegularTTF showEspressoLevel 16 0x513C2F CustomOvaltineText[0] 784 CustomEspressoTextY KanitRegularTTF showEspressoLevel 16 0x513C2F CustomOvaltineText[1] 893 CustomEspressoTextY KanitRegularTTF showEspressoLevel 16 0x513C2F CustomOvaltineText[2] ;for only milk in new topping 986 "auto" BGMilkNew 0 0 Var( DirImage + "/topping_revamp/bg_custom_milk.png" ) 694 CustomEspressoTextY KanitRegularTTF CustomMilkState[0] 16 0x513C2F CustomMilkText[0] 804 CustomEspressoTextY KanitRegularTTF CustomMilkState[1] 16 0x513C2F CustomMilkText[1] 893 CustomEspressoTextY KanitRegularTTF CustomMilkState[2] 16 0x513C2F CustomMilkText[2] ; Additional Price 935 CustomEspressoTextY KanitRegularTTF CustomMilkState[2] 16 0x84776F MilkIncreasePriceText ; ; ; "Enable" 986 27 -5 "Enable" "ROOT/taobin_project/image/topping2/bg_bottom.png" ; ; ; ; ; ; ; ; TEST - BEGIN Custom coffee showCustomCoffee 1080 "auto" 20 986 "auto" "vertical" showCustomCoffee ; ; ; ; ; 986 64 showCustomCoffee "ROOT/taobin_project/image/topping_mmr/bg_top_custom_coffee.png" 40 10 500 72 000103 ; ; ; Customer Coffee Water Level 986 "auto" showCoffeeWater 0 0 Var( DirImage + "/bg_custom_coffee_water_level.png" ) 472 CustomCoffeeTextY KanitRegularTTF showCoffeeWater 16 0x513C2F CustomCoffeeWaterText[0] 583 CustomCoffeeTextY KanitRegularTTF showCoffeeWater 16 0x513C2F CustomCoffeeWaterText[1] 694 CustomCoffeeTextY KanitRegularTTF showCoffeeWater 16 0x513C2F CustomCoffeeWaterText[2] 805 CustomCoffeeTextY KanitRegularTTF showCoffeeWater 16 0x513C2F CustomCoffeeWaterText[3] 916 CustomCoffeeTextY KanitRegularTTF showCoffeeWater 16 0x513C2F CustomCoffeeWaterText[4] 986 "auto" showCoffeeQuantity 0 0 Var( DirImage + "/bg_custom_coffee_bean_quantity.png" ) 694 CustomCoffeeTextY KanitRegularTTF showCoffeeQuantity 16 0x513C2F CustomCoffeeQuantityText[0] 784 CustomCoffeeTextY KanitRegularTTF showCoffeeQuantity 16 0x513C2F CustomCoffeeQuantityText[1] 892 CustomCoffeeTextY KanitRegularTTF showCoffeeQuantity 16 0x513C2F CustomCoffeeQuantityText[2] ; Additional Price 810 CustomCoffeeTextY KanitRegularTTF showCoffeeQuantity 16 0x84776F CustomCoffeeQuantityAdditionalPrice[1] 918 CustomCoffeeTextY KanitRegularTTF showCoffeeQuantity 16 0x84776F CustomCoffeeQuantityAdditionalPrice[2] 986 "auto" showCoffeeLevel 0 0 Var( DirImage + "/bg_custom_coffee_level.png" ) custom_coffee_level_medium_text_x CustomCoffeeTextY KanitRegularTTF showCoffeeLevel 16 0x513C2F CustomCoffeeLevelText[0] 676 CustomCoffeeTextY KanitRegularTTF showCoffeeLevel 16 0x513C2F CustomCoffeeLevelText[1] custom_coffee_level_dark_text_x CustomCoffeeTextY KanitRegularTTF showCoffeeLevel 16 0x513C2F CustomCoffeeLevelText[2] custom_coffee_level_darker_text_x CustomCoffeeTextY KanitRegularTTF showCoffeeLevel 16 0x513C2F CustomCoffeeLevelText[3] ; Additional Price custom_coffee_level_medium_price_x CustomCoffeeTextY KanitRegularTTF showCoffeeLevel 16 0x84776F CustomCoffeeLevelAdditionalPrice[0] 720 CustomCoffeeTextY KanitRegularTTF showCoffeeLevel 16 0x84776F CustomCoffeeLevelAdditionalPrice[1] 820 CustomCoffeeTextY KanitRegularTTF showCoffeeLevel 16 0x84776F CustomCoffeeLevelAdditionalPrice[2] 930 CustomCoffeeTextY KanitRegularTTF showCoffeeLevel 16 0x84776F CustomCoffeeLevelAdditionalPrice[3] 986 "auto" showCoffeeTamping 0 0 Var( DirImage + "/bg_custom_coffee_tamping_pressure.png" ) 696 CustomCoffeeTextY KanitRegularTTF showCoffeeTamping 16 0x513C2F CustomCoffeeTampingText[0] 790 CustomCoffeeTextY KanitRegularTTF showCoffeeTamping 16 0x513C2F CustomCoffeeTampingText[1] 920 CustomCoffeeTextY KanitRegularTTF showCoffeeTamping 16 0x513C2F CustomCoffeeTampingText[2] ; ; ; showCustomCoffee 986 27 -5 showCustomCoffee "ROOT/taobin_project/image/topping2/bg_bottom.png" ; ; ; ; ; ; ; ; ; Extra topping. ; ; ; ; ; ; ;-BEGIN shot layout SpecialMix 1080 "auto" 20 986 "auto" "vertical" SpecialMix ; 986 72 SpecialMix Var( DirImage + "/topping_revamp/bg_top_special_mix.png" ) ; ; ; 986 "auto" showOvaltineEnable ; 0 0 Var( DirImage + "/topping_revamp/bg_special_ovaltine.png") ; 833 26 KanitRegularTTF showOvaltineEnable 16 0x84776F OvaltinePriceText ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; 986 "auto" showOreoAddEnable ; 0 0 Var( DirImage + "/topping_revamp/bg_special_oreo.png") ; ; 833 26 KanitRegularTTF showOreoAddEnable 16 0x84776F OreoPriceText ; ; ; ; ; 986 "auto" showCocoaEnable ; 0 0 Var( DirImage + "/topping_revamp/bg_special_cocoa.png") ; 833 26 KanitRegularTTF showCocoaEnable 16 0x84776F CocoaPriceText ; ; ; ; ; ; 986 "auto" CollagenState ; 0 0 Var( DirImage + "/topping_revamp/bg_top_jemila_free.png") ; ; 833 26 KanitRegularTTF CollagenState 16 0x92D955 CollagenPriceText ; ; ; ; ; ; "Enable" 986 27 -5 ExtraTopping "ROOT/taobin_project/image/topping2/bg_bottom.png" ; ; ; ; ; ; ; ; ; Custom Syrup ; ; ; ; ; ; CustomSyrup 1080 "auto" 20 986 "auto" "vertical" CustomSyrup ; 986 72 CustomSyrup Var( DirImage + "/topping_revamp/bg_top_custom_syrup.png" ) ; ; ; ; ; 986 "auto" showStrawberryEnable ; 0 0 Var( DirImage + "/topping_revamp/bg_syrup_straberry.png") ; 833 26 KanitRegularTTF "Enable" 16 0x84776F StrawberryPriceText ; ; ; ; ; ; ; ; ; 986 "auto" showYuzuEnable ; 0 0 Var( DirImage + "/topping_revamp/bg_syrup_yuzu.png") ; ; 833 26 KanitRegularTTF "Enable" 16 0x84776F YuzuPriceText ; ; ; ; ; ; "Enable" 986 27 -5 ExtraTopping "ROOT/taobin_project/image/topping2/bg_bottom.png" ; ; ; ; ; ; ; Open "/media/bt/xml/security_alarm.xml" ; back ; next Var fun = "function2" DEBUGVAR fun Var img_cold_no_flag = 0 Var img_smth_no_flag = 0 If hot_button_state = "Disable2" Then If blend_button_state = "Disable2" Then Var img_cold_no_flag = 1 Else Var img_cold_no_flag = 1 Var img_smth_no_flag = 2 EndIf EndIf If PriceD1 = PriceD2 Then Var img_cold_no_flag = 1 EndIf If hot_button_state = "Disable2" Then If cold_button_state = "Disable2" Then Var img_smth_no_flag = 1 EndIf EndIf If img_cold_no_flag = 1 Then SAVELOG "Cold Image change." Var img_cold = "/bt_cold_no.png" Var img_cold_sel = "/bt_cold_selected_no.png" Var img_cold_dis = "/bt_cold_disable_no.png" Var img_cold_dis2 = "/bt_cold_disable2_no.png" If PD_CODE2 = "12-05-02-0016" Then Var img_cold = "/bt_normal_no.png" Var img_cold_sel = "/bt_normal_selected_no.png" Var img_cold_dis = "/bt_cold_disable_no.png" Var img_cold_dis2 = "/bt_cold_disable2_no.png" EndIf Else Var img_cold = "/bt_cold.png" Var img_cold_sel = "/bt_cold_selected.png" Var img_cold_dis = "/bt_cold_disable.png" Var img_cold_dis2 = "/bt_cold_disable2.png" EndIf If img_smth_no_flag = 1 Then SAVELOG "Smoothies change img. 1" Var img_smth = "/bt_smoothie_no.png" Var img_smth_sel = "/bt_smoothie_selected_no.png" Var img_smth_dis = "/bt_smoothie_disable_no.png" Var img_smth_dis2 = "/bt_smoothie_disable2_no.png" Else If img_smth_no_flag = 2 Then SAVELOG "Smoothies change img. 2" Var img_smth = "/bt_smoothie_sub2.png" Var img_smth_sel = "/bt_smoothie_selected_sub2.png" Var img_smth_dis = "/bt_smoothie_disable_sub2.png" Var img_smth_dis2 = "/bt_smoothie_disable2_sub2.png" Else Var img_smth = "/bt_smoothie.png" Var img_smth_sel = "/bt_smoothie_selected.png" Var img_smth_dis = "/bt_smoothie_disable.png" Var img_smth_dis2 = "/bt_smoothie_disable2.png" EndIf EndIf Var img_cold = "/bt_cold_no.png" Var img_cold_sel = "/bt_cold_selected_no.png" Var img_cold_dis = "/bt_cold_disable_no.png" Var img_cold_dis2 = "/bt_cold_disable2_no.png" If PD_CODE2 = "12-05-02-0016" Then Var img_cold = "/bt_normal_no.png" Var img_cold_sel = "/bt_normal_selected_no.png" Var img_cold_dis = "/bt_cold_disable_no.png" Var img_cold_dis2 = "/bt_cold_disable2_no.png" EndIf Var img_smth = "/bt_smoothie_no.png" Var img_smth_sel = "/bt_smoothie_selected_no.png" Var img_smth_dis = "/bt_smoothie_disable_no.png" Var img_smth_dis2 = "/bt_smoothie_disable2_no.png" DEBUGVAR menu_name_thai_cold SAVELOG "FUNCTION2" Var TOPPING_PRICE = 0 Var SelectDrinkType = 0 ; Set default If SelectCountDrinkType = 1 Then If DefaultDrinkType = 1 Then Var hot_button_state = "PressForever" EndIf If DefaultDrinkType = 2 Then Var cold_button_state = "PressForever" EndIf If DefaultDrinkType = 3 Then Var blend_button_state = "PressForever" EndIf EndIf If hot_button_state = "PressForever" Then Var PriceDrinkNoTop = PriceD1 Var UserSelectProductCode = PD_CODE1 If showShotEnable = "Disable" Then If CustomCoffeeEnable = "False" Then Var showShotEnable = "Enable" EndIf EndIf If showCustomCoffee = "Invisible" Then If CustomCoffeeEnable = "True" Then Var showCustomCoffee = "Enable" EndIf EndIf Var showText4 = "Invisible" If show_eng = "true" Then Var showname = menu_name_eng_hot Var showdesc = menu_desc_eng_hot Else Var showname = menu_name_thai_hot Var showdesc = menu_desc_thai_hot EndIf Var Seeker.NameDrinkEN = menu_name_eng_hot Var Seeker.NameDrinkTH = menu_name_thai_hot Var text_hot_color = "0xFFFFFF" Var text_cold_color = "0x84776F" Var text_blender_color = "0x84776F" Var SelectDrinkType = 1 Machine PreparCup EndIf If cold_button_state = "PressForever" Then Var PriceDrinkNoTop = PriceD2 Var OriginalPrice = OriginalPriceD2 Var UserSelectProductCode = PD_CODE2 If showShotEnable = "Disable" Then If CustomCoffeeEnable = "False" Then Var showShotEnable = "Enable" EndIf EndIf If showCustomCoffee = "Invisible" Then If CustomCoffeeEnable = "True" Then Var showCustomCoffee = "Enable" EndIf EndIf Var showText4 = "Invisible" If show_eng = "true" Then Var showname = menu_name_eng_cold Var showdesc = menu_desc_eng_cold Else Var showname = menu_name_thai_cold Var showdesc = menu_desc_thai_cold EndIf Var Seeker.NameDrinkEN = menu_name_eng_cold Var Seeker.NameDrinkTH = menu_name_thai_cold Var text_hot_color = "0x84776F" Var text_cold_color = "0xFFFFFF" Var text_blender_color = "0x84776F" Var SelectDrinkType = 1 Machine PreparCup EndIf If blend_button_state = "PressForever" Then Var PriceDrinkNoTop = PriceD3 Var OriginalPrice = OriginalPriceD3 Var UserSelectProductCode = PD_CODE3 If showShotEnable = "Invisible" Then Else Var showShotEnable = "Disable" EndIf If CustomCoffeeEnable = "True" Then Var showCustomCoffee = "Enable" Var showCoffeeWater = "Invisible" Var CurrentCoffeeWaterId = toppingID7Default Var CustomCoffeeWaterState[0] = "Enable" Var CustomCoffeeWaterState[1] = "PressForever" Var CustomCoffeeWaterState[2] = "Enable" Var CustomCoffeeWaterState[3] = "Enable" Var CustomCoffeeWaterState[4] = "Enable" EndIf Var showText4 = "Enable" If show_eng = "true" Then Var showname = menu_name_eng_blender Var showdesc = menu_desc_eng_blender Else Var showname = menu_name_thai_blender Var showdesc = menu_desc_thai_blender EndIf Var Seeker.NameDrinkEN = menu_name_eng_blender Var Seeker.NameDrinkTH = menu_name_thai_blender Var text_hot_color = "0x84776F" Var text_cold_color = "0x84776F" Var text_blender_color = "0xFFFFFF" Var SelectDrinkType = 1 Machine PreparCup EndIf Var OatMilkAddAmount = 5 Var CerealMilkPrice = "(+฿5)" Var OreoPrice = 10 Var CocoaPrice = 10 Var OvaltinePrice = 10 Var StrawberryPrice = 5 Var YuzuPrice = 5 Var MilkIncreasePrice = 5 Var EnergyPriceLevel1 = 5 Var EnergyPriceLevel2 = 10 Var CoffeePriceLevel1 = 15 Var CoffeePriceLevel2 = 25 Var OreoPriceText = "(+10)" Var CocoaPriceText = "(+10)" Var OvaltinePriceText = "(+10)" Var StrawberryPriceText = "(+5)" Var YuzuPriceText = "(+5)" Var MilkIncreasePriceText = "(+5)" Var CollagenPriceText = "(Free)" Var EnergyTextLevel1 = "(+5)" Var EnergyTextLevel2 = "(+10)" Var CoffeeTextLevel1 = "(+15)" Var CoffeeTextLevel2 = "(+25)" Var CerealMilkAddAmount = SubMenuPrice1 - PriceDrinkNoTop If CerealMilkAddAmount = 0 Then Var CerealMilkPrice = "(+฿10)" Else Var CerealMilkPrice = "(+฿" + CerealMilkAddAmount Var CerealMilkPrice = CerealMilkPrice + ")" Var CerealMilkPrice = "(+฿10)" EndIf DEBUGVAR SubMenuPrice1 DEBUGVAR CerealMilkAddAmount DEBUGVAR PriceDrinkNoTop DEBUGVAR PriceDiff DEBUGVAR showShotEnable Var TOPPING_PRICE = 0 If ShotCoffeePremium = "Press" Then If blendedState = "Press" Then Var PriceDrinkTmp = PriceDrinkNoTop EndIf Var blendedState = "Disable" Var TOPPING_PRICE = 0 Var TOPPING_PRICE = TOPPING_PRICE + toppingID2price2 Var topping2 = toppingID2index2 Var DisableUsingCode = "true" Var showText7 = "Enable" SAVELOG "Select premi normal shot" Else If showShotEnable = "Press" Then If blendedState = "Press" Then Var PriceDrinkTmp = PriceDrinkNoTop EndIf Var blendedState = "Disable" Var TOPPING_PRICE = 0 ;Var PriceDrinkTmp = PriceDrinkNoTop + toppingID2price2 Var TOPPING_PRICE = TOPPING_PRICE + toppingID2price2 Var topping2 = toppingID2index2 Var DisableUsingCode = "true" Var showText7 = "Enable" SAVELOG "Select add normal shot" Else If blendedState = "Disable" Then Var blendedState = "Enable" EndIf Var PriceDrinkTmp = PriceDrinkNoTop Var topping2 = toppingID2index1 Var DisableUsingCode = "false" SAVELOG "Deselect add normal shot" Var showText7 = "Invisible" EndIf EndIf ; Post Topping If SugarZeroCalEnable = "true" Then Var sugarToppingID = 1000 If SugarZeroCalCheck = "PressForever" Then Var sugarToppingID = 1001 Else Var sugarToppingID = 1000 EndIf EndIf If SugarZeroCalEnable = "true" Then If SugarZeroCalOption = "Enable" Then If SugarZeroCalCheck = "PressForever" Then Var TOPPING_PRICE = TOPPING_PRICE + SugarZeroCalPrice Var Seeker.UseFreeSugarZeroCalTopping = 1 Else Var Seeker.UseFreeSugarZeroCalTopping = 0 EndIf EndIf EndIf DEBUGVAR showOreoAddEnable DEBUGVAR TOPPING_PRICE ; Oreo Var strMulti6_1 = "TPID:321+multiply:0" ; Ovaltine Var strMulti6_2 = "TPID:323+multiply:0" ; Coaco Var strMulti6_3 = "TPID:322+multiply:0" If showOreoAddEnable = "Press" Then Var TOPPING_PRICE = TOPPING_PRICE + OreoPrice Var strMulti6_1 = "TPID=321,multiply=1" Var DisableUsingCode = "true" DEBUGVAR DisableUsingCode Else ;Var PriceDrinkTmp = PriceDrinkNoTop Var strMulti6_1 = "TPID=320,multiply=0" Var DisableUsingCode = "false" DEBUGVAR DisableUsingCode EndIf If showOvaltineEnable = "Press" Then Var TOPPING_PRICE = TOPPING_PRICE + OvaltinePrice ;Var topping6 = toppingID6index5 Var strMulti6_2 = "TPID=323,multiply=1" Var DisableUsingCode = "true" DEBUGVAR DisableUsingCode Else ;Var PriceDrinkTmp = PriceDrinkNoTop Var strMulti6_2 = "TPID=320,multiply=0" Var DisableUsingCode = "false" DEBUGVAR DisableUsingCode EndIf If showCocoaEnable = "Press" Then Var TOPPING_PRICE = TOPPING_PRICE + CocoaPrice ;Var topping6 = toppingID6index3 Var strMulti6_3 = "TPID=322,multiply=1" Var DisableUsingCode = "true" DEBUGVAR DisableUsingCode Else ;Var PriceDrinkTmp = PriceDrinkNoTop Var strMulti6_3 = "TPID=320,multiply=0" Var DisableUsingCode = "false" DEBUGVAR DisableUsingCode EndIf If CustomMilkState[2] = "PressForever" Then Var TOPPING_PRICE = TOPPING_PRICE + MilkIncreasePrice EndIf If CustomEnaergyState[0] = "Press" Then Var TOPPING_PRICE = TOPPING_PRICE + EnergyPriceLevel1 EndIf If CustomEnaergyState[1] = "Press" Then Var TOPPING_PRICE = TOPPING_PRICE + EnergyPriceLevel2 EndIf If CustomEspressoState[0] = "Press" Then Var TOPPING_PRICE = TOPPING_PRICE + CoffeePriceLevel1 EndIf If CustomEspressoState[1] = "Press" Then Var TOPPING_PRICE = TOPPING_PRICE + CoffeePriceLevel2 EndIf If CollagenState = "Press" Then Var TOPPING_PRICE = TOPPING_PRICE + CollagenToppingPrice Var topping3 = toppingID3index2 Var Seeker.UseFreeCollagenTopping = 1 Else Var topping3 = toppingID3index1 Var Seeker.UseFreeCollagenTopping = 0 EndIf If CerealMilkEnable = "Press" Then If MenuCodeName1 = "Cereal-Milk" Then Var TOPPING_PRICE = TOPPING_PRICE + CerealMilkAddAmount Var DisableUsingCode = "true" Var UserSelectProductCode = SubMenuProductCode1 EndIf Else EndIf If showStrawberryEnable = "Press" Then Var TOPPING_PRICE = TOPPING_PRICE + StrawberryPrice Var strMulti6_5 = "TPID=324,multiply=1" Var DisableUsingCode = "true" Else Var strMulti6_5 = "TPID=320,multiply=0" Var DisableUsingCode = "false" DEBUGVAR DisableUsingCode EndIf If showYuzuEnable = "Press" Then Var TOPPING_PRICE = TOPPING_PRICE + YuzuPrice Var strMulti6_6 = "TPID=325,multiply=1" Var DisableUsingCode = "true" Else Var strMulti6_6 = "TPID=320,multiply=0" Var DisableUsingCode = "false" DEBUGVAR DisableUsingCode EndIf Var CustomCoffeeDefault = "true" DEBUGVAR showCustomCoffee DEBUGVAR CustomCoffeeDefault If showShotEnable = "Press" Then ; Invisible showCustomCoffee Var showCustomCoffee = "Invisible" Else If CustomCoffeeEnable = "True" Then Var showCustomCoffee = "Enable" EndIf EndIf If showCustomCoffee = "Enable" Then If showCoffeeWater = "Enable" Then If CurrentCoffeeWaterId = toppingID7Default Then Else Var CustomCoffeeDefault = "false" EndIf EndIf If showCoffeeQuantity = "Enable" Then If CurrentCoffeeQuantityId = toppingID2Default Then Else Var CustomCoffeeDefault = "false" EndIf EndIf If showCoffeeLevel = "Enable" Then If CurrentCoffeeLevelId = toppingID9Default Then Else Var CustomCoffeeDefault = "false" EndIf EndIf If showCoffeeTamping = "Enable" Then If CurrentCoffeeTampingId = toppingID8Default Then Else Var CustomCoffeeDefault = "false" EndIf EndIf DEBUGVAR CustomCoffeeDefault If CustomCoffeeDefault = "false" Then If showShotEnable = "Enable" Then ;Var showShotEnable = "Disable" EndIf Else If showShotEnable = "Invisible" Then Else If blend_button_state = "PressForever" Then Else Var showShotEnable = "Enable" EndIf EndIf EndIf If CustomCoffeeQuantityState[0] = "PressForever" Then Var TOPPING_PRICE = TOPPING_PRICE + toppingID2price1 EndIf If CustomCoffeeQuantityState[1] = "PressForever" Then Var TOPPING_PRICE = TOPPING_PRICE + toppingID2price2 EndIf If CustomCoffeeQuantityState[2] = "PressForever" Then Var TOPPING_PRICE = TOPPING_PRICE + toppingID2price3 EndIf If CustomCoffeeLevelState[0] = "PressForever" Then Var TOPPING_PRICE = TOPPING_PRICE + toppingID9price1 EndIf If CustomCoffeeLevelState[1] = "PressForever" Then Var TOPPING_PRICE = TOPPING_PRICE + toppingID9price2 EndIf If CustomCoffeeLevelState[2] = "PressForever" Then Var TOPPING_PRICE = TOPPING_PRICE + toppingID9price3 EndIf If CustomCoffeeLevelState[3] = "PressForever" Then Var TOPPING_PRICE = TOPPING_PRICE + toppingID9price4 EndIf EndIf DEBUGVAR SelectDrinkType DEBUGVAR showShotEnable DEBUGVAR PriceDrinkTmpShow If Price5Active = 1 Then Var PriceDrinkNoTop = 5 If blend_button_state = "PressForever" Then Var PriceDrinkNoTop = 10 EndIf EndIf Var PriceDrinkTmp = PriceDrinkNoTop + TOPPING_PRICE Var PriceDrinkTmpShow = charOfBaht + PriceDrinkTmp If SelectDrinkType = 0 Then Var PriceDrinkTmpShow = "---" Else Var PriceDrinkTmpShow !assigned StringFmt( PriceDrinkTmp , DisplayFormat, PreScaleConvertShow) EndIf SAVELOG PriceDrinkTmp If RoadShow = "true" Then Var PriceDrinkTmpShow = "Free" DEBUGVAR SelectDrink2 DEBUGVAR PriceDrinkTmpShow EndIf ; echo -n true > /mnt/sdcard/coffeevending/menu_blend_free READ_FILE "/mnt/sdcard/coffeevending/menu_blend_free" menu_blend_free DEBUGVAR menu_blend_free DEBUGVAR blend_button_state If menu_blend_free = "true" Then If blend_button_state = "PressForever" Then Var PriceDrinkNoTop = 0 Var PriceDrinkTmpShow = "Free" EndIf EndIf If SugarZeroCalCheck = "PressForever" Then If SugarNormalCheck = "PressForever" Then Var SugarZeroCalCheck = "Enable" EndIf EndIf If SelectDrinkType = 0 Then If show_eng = "true" Then Var showname = NameDrink Var showdesc = DrinkDescription Else Var showname = NameDrinkTH Var showdesc = DrinkDescriptionTH EndIf EndIf BackslashNToEnter showname BackslashNToEnter showdesc CRLFToSpace showname CRLFToSpace showdesc DEBUGVAR showname DEBUGVAR showdesc Strlen showname show_name_len Var hasPress = "false" If CustomOreoState = "Enable" Then If CustomOreoCheckState = "Press" Then Var hasPress = "true" EndIf EndIf If CustomOvaltineState = "Enable" Then If CustomOvaltineCheckState = "Press" Then Var hasPress = "true" EndIf EndIf If CustomCocoaState = "Enable" Then If CustomCocoaCheckState = "Press" Then Var hasPress = "true" EndIf EndIf If hasPress = "true" Then Var PopupToppingSelect = "Press" If show_eng = "true" Then Var bnAccept = "ROOT/taobin_project/image/topping2_en/topping_revamp/bn_accept.png" Var bpAccept = "ROOT/taobin_project/image/topping2_en/topping_revamp/bp_accept.png" Else Var bnAccept = "ROOT/taobin_project/image/topping2/topping_revamp/bn_accept.png" Var bpAccept = "ROOT/taobin_project/image/topping2/topping_revamp/bp_accept.png" EndIf Var bnAcceptX = 445 Else Var PopupToppingSelect = "Enable" If show_eng = "true" Then Var bnAccept = "ROOT/taobin_project/image/topping2_en/topping_revamp/bn_accept2.png" Var bpAccept = "ROOT/taobin_project/image/topping2_en/topping_revamp/bp_accept2.png" Else Var bnAccept = "ROOT/taobin_project/image/topping2/topping_revamp/bn_accept2.png" Var bpAccept = "ROOT/taobin_project/image/topping2/topping_revamp/bp_accept2.png" EndIf Var bnAcceptX = 360 EndIf Var Timeout = 0 RefreshAll ;for test Var showShotEnable = "Invisible" 924 1804 KanitTTF 36 1080 0xFFFFFF "OnValueChange" PriceDrinkTmpShow ; next2 button Protect ; zone 0 380 1080 1540 toppingSelectState "ROOT/taobin_project/image/topping2/topping_revamp/alpha.png" 240 880 641 180 toppingSelectState Var( DirImage + "/topping_revamp/bg_top_popup.png" ) 240 oreo_y 641 72 CustomOreoState Var( DirImage + "/topping_revamp/bg_top_oreo.png" ) 240 ovaltine_y 641 72 CustomOvaltineState Var( DirImage + "/topping_revamp/bg_top_ovaltine.png" ) 240 cocoa_y 641 72 CustomCocoaState Var( DirImage + "/topping_revamp/bg_top_cocoa.png" ) 240 bottom_y 641 120 toppingSelectState "ROOT/taobin_project/image/topping2/topping_revamp/bg_bottom.png" 820 900 34 34 toppingSelectState "ROOT/taobin_project/image/topping2/topping_revamp/bg_exit.png" Var MenuReady = "-" Var toppingSelectState = "Invisible" Var CustomOreoState = "Invisible" Var CustomOvaltineState = "Invisible" Var CustomCocoaState = "Invisible" Var CustomCollagenState = "Invisible" Var CustomOreoCheckState = "Invisible" Var CustomOvaltineCheckState = "Invisible" Var CustomCocoaCheckState = "Invisible" 0 380 1080 1540 high_light_drink_type "ROOT/taobin_project/image/topping2/topping_revamp/high_light_drink_type.png" 543 715 high_light_drink_type KanitTTF 36 1080 0xFF0000 eval( If show_eng = "true" Then Var return = "Please choose drink type" Else Var return ="โปรดเลือกประเภทเครื่องดื่ม" EndIf ) 1 1 KanitTTF 22 1080 end 0xFF0000 "V1.0" ; Var PromotionOreoToppingFreeEnable = 1 DEBUGVAR PromotionOreoToppingFreeEnable Var PromotionOreoToppingFreeEnable = 0 DEBUGVAR PromotionOreoToppingFreeEnable Topping "Select" UserSelectProductCode DEBUGVAR UserSelectProductCode ; Set option toppinng and pack Topping "Select1-ID" topping1 Topping "Select2-ID" topping2 Topping "Select3-ID" topping3 Topping "Select6-ID" topping6 Topping "Select7-ID" topping7 Topping "Select8-ID" topping8 Topping "Select9-ID" topping9 Topping "Select10-ID" topping10 Topping "ClearMultiTopping" "Test 4" Var strMulti6_1 = "TPID=313,multiply=2" Var strMulti6_2 = "TPID=302,multiply=1" ;Var strMulti6_3 = "TPID=82,multiply=1" Topping "Multiply6-ID" strMulti6_1 Topping "Multiply6-ID" strMulti6_2 ;Topping "Multiply6-ID" strMulti6_3 Topping "Pack" ExtendDataCurr