taobin_project/xml/page_pepween_random.xml
2023-09-26 16:31:42 +07:00

171 lines
No EOL
4.5 KiB
XML

<Popup>
<Cache> "Enable" </Cache>
<Width> 1080 </Width>
<Height> 1920 </Height>
<Volume> SoundVolume </Volume>
;<Background> "0xeae6e1" </Background>
<EventOpen>
Var randResult = 0
Var isCoffinPress = "Enable"
; list of random items
Var dis30 = "Discount30"
Var dis50 = "Discount50"
Var dis100 = "Free1Drink"
; rate 40%
Var couponList[0] = dis30
Var couponList[1] = dis30
Var couponList[2] = dis30
Var couponList[3] = dis30
Var couponList[4] = dis50
Var couponList[5] = dis50
Var couponList[6] = dis50
Var couponList[7] = dis50
; rate 20%
Var couponList[8] = dis100
Var couponList[9] = dis100
; Coffin btn
Var CoffinBtnDir = "ROOT/taobin_project/image/event/pepween/bn_pepween_"
DEBUGVAR CoffinBtnDir
</EventOpen>
; background
<Image>
<X> 0 </X>
<Y> 380 </Y>
<Width> 1080 </Width>
<Height> 1540 </Height>
<Filename> "ROOT/taobin_project/image/event/pepween/bg_pepween_random.png" </Filename>
</Image>
; back --- debug
;
; disable this later
<Button>
<X> 19 </X>
<Y> 381 </Y>
<Filename> "ROOT/taobin_project/image/page2/bn_back_arrow_2.png" </Filename>
<FilenamePress> "ROOT/taobin_project/image/page2/bn_back_arrow_2.png" </FilenamePress>
<Sound> "/mnt/sdcard/coffeevending/wav/click.wav" </Sound>
<Volume> SoundVolume </Volume>
<EventClick>
If SpiralOnline = "true" Then
If Seeker = "curr" Then
Open "ROOT/taobin_project/xml/page_catalog_with_vending.xml"
Else
Open "ROOT/taobin_project/xml/page_catalog.xml"
EndIf
Else
Open "ROOT/taobin_project/xml/page_catalog.xml"
EndIf
</EventClick>
</Button>
<Image>
<X> 373 </X>
<Y> 444 </Y>
<Width> 334 </Width>
<Height> 75 </Height>
<Filename> "ROOT/taobin_project/image/event/pepween/let_ghost_show_u.png" </Filename>
</Image>
<Image>
<X> 79 </X>
<Y> 526 </Y>
<Width> 923 </Width>
<Height> 67 </Height>
<Filename> "ROOT/taobin_project/image/event/pepween/choose_your_ghost.png" </Filename>
</Image>
; Button top left - Caroline
<Button>
<X> 25 </X>
<Y> 857 </Y>
<State> isCoffinPress </State>
<Filename> Var( CoffinBtnDir + "top_left.png" ) </Filename>
<EventOnClick>
; Random coupon
Random2 0 10 randResult
DEBUGVAR randResult
DEBUGVAR couponList[randResult]
</EventOnClick>
</Button>
; Button top mid - Jeremy
<Button>
<X> 386 </X>
<Y> 926 </Y>
<State> isCoffinPress </State>
<Filename> Var( CoffinBtnDir + "top_mid.png" ) </Filename>
<EventOnClick>
; Random coupon
Random2 0 10 randResult
DEBUGVAR randResult
DEBUGVAR couponList[randResult]
</EventOnClick>
</Button>
; Button top right - Rosalie
<Button>
<X> 722 </X>
<Y> 855 </Y>
<State> isCoffinPress </State>
<Filename> Var( CoffinBtnDir + "top_right.png" ) </Filename>
<EventOnClick>
; Random coupon
Random2 0 10 randResult
DEBUGVAR randResult
DEBUGVAR couponList[randResult]
</EventOnClick>
</Button>
; Button bottom left - Arnold
<Button>
<X> 140 </X>
<Y> 1317 </Y>
<State> isCoffinPress </State>
<Filename> Var( CoffinBtnDir + "bottom_left.png" ) </Filename>
<EventOnClick>
; Random coupon
Random2 0 10 randResult
DEBUGVAR randResult
DEBUGVAR couponList[randResult]
</EventOnClick>
</Button>
; Button bottom right - Alnwick
<Button>
<X> 605 </X>
<Y> 1317 </Y>
<State> isCoffinPress </State>
<Filename> Var( CoffinBtnDir + "bottom_right.png" ) </Filename>
<EventOnClick>
; Random coupon
Random2 0 10 randResult
DEBUGVAR randResult
DEBUGVAR couponList[randResult]
</EventOnClick>
</Button>
; accept button
<Button>
<X> 408 </X>
<Y> 1406 </Y>
<Filename> "ROOT/taobin_project/image/page_payment/bn_drink.png" </Filename>
<EventOnClick>
; TODO: implement something
</EventOnClick>
</Button>
</Popup>