-
Notifications
You must be signed in to change notification settings - Fork 0
/
main.blocks
16 lines (16 loc) · 24.5 KB
/
main.blocks
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
<xml xmlns="https://developers.google.com/blockly/xml"><variables><variable id="@r5Gd:yL!b-ihV!=+2CL">Hand</variable><variable id="?WWco)#Wi+{T]e;}MrGO">MatchResult</variable><variable id="C^HOdD]X9WNK.DM+o#]7">Ready</variable><variable id="8d*K^9H0![V*Kbq/}lJ]">Opponent</variable><variable id="EG^/:LbHx/r4#(9V!+0.">RadioGroup</variable><variable id="QIaRB[7t)u)gY8|9gdg8">PlayerHealth</variable><variable id="XS*hJ9Ot=r+;F+F#J_Xy">OpponentHealth</variable><variable id="kb;{qbqSwGkJEnLZ}Jhf">TotalWins</variable></variables><block type="function_definition" id="P!2-s6[q[F%9*7}DFW^k" x="-467" y="5"><mutation name="HomeScreen" functionid="MSukxV,e9(d7x%N3.Pw}"></mutation><field name="function_name">HomeScreen</field><statement name="STACK"><block type="device_show_leds" id="EegEZ{QBNfRD|qS/8IgG"><field name="LEDS">`
# . # . #
. # . # .
. # # # .
# # . # #
. # # # .
`</field><comment pinned="true" h="78" w="154">Draw your monster here!</comment><next><block type="device_while" id=",Zk@]J^WD#5wCs}pr7Nr"><value name="COND"><shadow type="logic_boolean" id="@Bh)nd?OQ/MPJLUhn9q1"><field name="BOOL">TRUE</field></shadow></value><statement name="DO"><block type="controls_if" id=".#,-TL*@7w%YBWQjkzAm"><value name="IF0"><shadow type="logic_boolean"><field name="BOOL">TRUE</field></shadow><block type="device_get_button2" id="[Me{^aourRZ0n(2jz$`~"><field name="NAME">Button.A</field></block></value><statement name="DO0"><block type="break_keyword" id="hi%,T?Rmu`lbzU.`(g,H"></block></statement><next><block type="controls_if" id="?{](~#0Nz_GYG1t=:HXF"><value name="IF0"><shadow type="logic_boolean"><field name="BOOL">TRUE</field></shadow><block type="device_get_button2" id="wM,Ru2EeCU8;fRokNAHg"><field name="NAME">Button.B</field></block></value><statement name="DO0"><block type="device_print_message" id="4n%|||01CD7#!d*.5Zn."><value name="text"><shadow type="text" id="d=vZ_/*@oiv29]0Nl(1C"><field name="TEXT">Wins:</field></shadow></value><next><block type="device_show_number" id="#YbTzG0Zxmr2fA2#k^K("><value name="number"><shadow type="math_number"><field name="NUM">0</field></shadow><block type="variables_get" id="M=57)Y!mYwG}0I~B)_@t"><field name="VAR" id="kb;{qbqSwGkJEnLZ}Jhf">TotalWins</field></block></value><next><block type="device_pause" id="1dQ;7KVDG4DR_Sh2GV9A"><value name="pause"><shadow type="timePicker" id="M,D]D-(?b8)4eNxnt8$x"><field name="ms">2000</field></shadow></value><next><block type="function_call" id="3I)nfD=%GOQ%(20u5eL+"><mutation name="HomeScreen" functionid="MSukxV,e9(d7x%N3.Pw}"></mutation></block></next></block></next></block></next></block></statement></block></next></block></statement><next><block type="function_call" id="tN3H*ZPPM_he+lcAK/l?"><mutation name="SetRadioGroup" functionid="oYR~3[^`O96%Up*:CIxg"></mutation></block></next></block></next></block></statement></block><block type="function_definition" id="w]m*gr1Be=NfDpG0/kdk" x="0" y="0"><mutation name="SetRadioGroup" functionid="oYR~3[^`O96%Up*:CIxg"></mutation><field name="function_name">SetRadioGroup</field><statement name="STACK"><block type="device_show_number" id="R;Y%3~5sa`W`QUDhH:rk"><value name="number"><shadow type="math_number"><field name="NUM">0</field></shadow><block type="variables_get" id="SSFEjFc;`C;N}}x-j0=H"><field name="VAR" id="EG^/:LbHx/r4#(9V!+0.">RadioGroup</field></block></value><next><block type="device_while" id=",:.:GfE1M_3;mI#fj7/u"><value name="COND"><shadow type="logic_boolean" id="i8qi]e5ND:d^9/eHE]%{"><field name="BOOL">TRUE</field></shadow></value><statement name="DO"><block type="controls_if" id="!Z+^IQJO2_#,K2L%W3Uz"><value name="IF0"><shadow type="logic_boolean" disabled="true"><field name="BOOL">TRUE</field></shadow><block type="deviceisgesture" id="JTW~hE|k/%:rL^y(r7}-"><field name="gesture">Gesture.Shake</field></block></value><statement name="DO0"><block type="variables_set" id="dC]?hlpa2;U|N)uiz.3h"><field name="VAR" id="EG^/:LbHx/r4#(9V!+0.">RadioGroup</field><value name="VALUE"><shadow type="math_number"><field name="NUM">0</field></shadow><block type="math_modulo" id=")X(py2Oaw|}@EDJ^l^M/"><value name="DIVIDEND"><shadow type="math_number"><field name="NUM">0</field></shadow><block type="math_arithmetic" id="GByMA%F{7@X/]I=tV.~d"><field name="OP">ADD</field><value name="A"><shadow type="math_number"><field name="NUM">0</field></shadow><block type="variables_get" id="%DT(ID!t6]J])_uBTp%r"><field name="VAR" id="EG^/:LbHx/r4#(9V!+0.">RadioGroup</field></block></value><value name="B"><shadow type="math_number" id="Dp;`^_GpDdfd;[$o/Qhn"><field name="NUM">1</field></shadow></value></block></value><value name="DIVISOR"><shadow type="math_number" id="udXU|()m=DL^|v,6Qz:["><field name="NUM">10</field></shadow></value></block></value><next><block type="device_show_number" id="xpE1T=W$I$Y)Rkv+dP^+"><value name="number"><shadow type="math_number"><field name="NUM">0</field></shadow><block type="variables_get" id=".xcZ?43H2znxV#6w(QNn"><field name="VAR" id="EG^/:LbHx/r4#(9V!+0.">RadioGroup</field></block></value></block></next></block></statement><next><block type="controls_if" id="]iJyG^8)7=ES=),UQ;;Y"><value name="IF0"><shadow type="logic_boolean"><field name="BOOL">TRUE</field></shadow><block type="device_get_button2" id="Qi!#]KapJ?9D!BdW~9R!"><field name="NAME">Button.A</field></block></value><statement name="DO0"><block type="break_keyword" id="S*w?N,c[xNT6DGzl4:F6"></block></statement></block></next></block></statement><next><block type="device_clear_display" id="(IyBcx/fk01m(q@/_rwx"><next><block type="device_show_number" id="w`OcQ`#J8]5upmqCnhD7"><value name="number"><shadow type="math_number"><field name="NUM">0</field></shadow><block type="variables_get" id=":_t!x;8d7aJN4K:X|fqq"><field name="VAR" id="EG^/:LbHx/r4#(9V!+0.">RadioGroup</field></block></value><next><block type="radio_set_group" id="VLIp04V~0y9vhu;Y^z-)"><value name="ID"><shadow type="math_number_minmax"><mutation min="0" max="255" label="Id" precision="0"></mutation><field name="SLIDER">1</field></shadow><block type="variables_get" id="eIl=F#yvbxFTaXUTg1J~"><field name="VAR" id="EG^/:LbHx/r4#(9V!+0.">RadioGroup</field></block></value><next><block type="variables_set" id="_i8GR$*4D~jC3,!6L):|"><field name="VAR" id="QIaRB[7t)u)gY8|9gdg8">PlayerHealth</field><value name="VALUE"><shadow type="math_number" id="jY;@dmbjJ[kU1{Qo7b)o"><field name="NUM">3</field></shadow></value><next><block type="variables_set" id="TAA*EreN{(bs5S0OmWdd"><field name="VAR" id="XS*hJ9Ot=r+;F+F#J_Xy">OpponentHealth</field><value name="VALUE"><shadow type="math_number" id="!AFIC$eHyl%.pFz29Ywg"><field name="NUM">3</field></shadow></value><next><block type="function_call" id="~obxtbkf;Wg7{FvRk6=C"><mutation name="MainBattleLoop" functionid="2]gIU~m,e3ID:wu%8v_:"></mutation></block></next></block></next></block></next></block></next></block></next></block></next></block></next></block></statement></block><block type="function_definition" id="zrjpz|;.Nd[GD;:H#Af?" x="741" y="-16"><mutation name="MainBattleLoop" functionid="2]gIU~m,e3ID:wu%8v_:"></mutation><field name="function_name">MainBattleLoop</field><statement name="STACK"><block type="device_while" id="1+8xe6HGs9gZ0AhaEj?/"><value name="COND"><shadow type="logic_boolean" id="4V^h)sOZV2qWa!C=[j(N"><field name="BOOL">TRUE</field></shadow></value><statement name="DO"><block type="controls_if" id="Qq#5.9?qHc,=?_KI%6Ru"><comment pinned="false" h="80" w="160">Player can only change their choice if not confirmed already</comment><value name="IF0"><shadow type="logic_boolean"><field name="BOOL">TRUE</field></shadow><block type="logic_operation" id=";csW^U2xkxzNv@C%LUs/"><field name="OP">AND</field><value name="A"><block type="logic_compare" id="}Rp!~Fad{OBK_5zdwdf$"><field name="OP">EQ</field><value name="A"><shadow type="math_number"><field name="NUM">0</field></shadow><block type="variables_get" id="p|N#eC8{zP721Auoe,vl"><field name="VAR" id="C^HOdD]X9WNK.DM+o#]7">Ready</field></block></value><value name="B"><shadow type="math_number" id="@MfqZD@1=d~ZjizBg}Pi"><field name="NUM">0</field></shadow></value></block></value><value name="B"><block type="logic_compare" id="?-#Vyx_{Th*It1XB^$P0"><field name="OP">EQ</field><value name="A"><shadow type="text" disabled="true"><field name="TEXT"></field></shadow><block type="deviceisgesture" id="PtVk+RK=yIy[W[Qj`gtQ"><field name="gesture">Gesture.Shake</field></block></value><value name="B"><shadow type="text" disabled="true"><field name="TEXT"></field></shadow><block type="logic_boolean" id="u,?Uolug]vRzPVfQi8l-"><field name="BOOL">TRUE</field></block></value></block></value></block></value><statement name="DO0"><block type="variables_set" id="u54kV`Eg{@t*S-q1@0lG"><field name="VAR" id="@r5Gd:yL!b-ihV!=+2CL">Hand</field><comment pinned="false" h="80" w="160">Cycles through 0, 1, 2</comment><value name="VALUE"><shadow type="math_number"><field name="NUM">0</field></shadow><block type="math_modulo" id="A_!a;z;b`P-@0@8U=pE,"><value name="DIVIDEND"><shadow type="math_number" disabled="true"><field name="NUM">0</field></shadow><block type="math_arithmetic" id="SDQXSF$1x.Pp_xNJ^hD#"><field name="OP">ADD</field><value name="A"><shadow type="math_number" disabled="true"><field name="NUM">0</field></shadow><block type="variables_get" id="LAmHfcwS/F!DtNs_Vo|$"><field name="VAR" id="@r5Gd:yL!b-ihV!=+2CL">Hand</field></block></value><value name="B"><shadow type="math_number" id="_O6;w2Xpi!Xw;cJFe7=~"><field name="NUM">1</field></shadow></value></block></value><value name="DIVISOR"><shadow type="math_number" id="oh/{xA[]j@u7VjVPr`.:"><field name="NUM">3</field></shadow></value></block></value></block></statement><next><block type="controls_if" id="1d~6VdPHKcEW03,O_X/x"><value name="IF0"><shadow type="logic_boolean" disabled="true"><field name="BOOL">TRUE</field></shadow><block type="device_get_button2" id="V3,`AB0N3Y24ludb*Qk%"><field name="NAME">Button.A</field></block></value><statement name="DO0"><block type="variables_set" id=",KN+q}_;aKX;H]%zrhz,"><field name="VAR" id="C^HOdD]X9WNK.DM+o#]7">Ready</field><value name="VALUE"><shadow type="math_number" id="LG^U~]|klnNznBUm!_/_"><field name="NUM">1</field></shadow></value><next><block type="radio_datagram_send" id="q9#m`H1K!nU|E/TBgH,R"><comment pinned="false" h="80" w="160">Send hand chosen by player. 0 - rock, 1 - paper, 2 - scissors</comment><value name="value"><shadow type="math_number"><field name="NUM">0</field></shadow><block type="variables_get" id="nDeGu_$lsl[i9o?@-V[#"><field name="VAR" id="@r5Gd:yL!b-ihV!=+2CL">Hand</field></block></value><next><block type="controls_if" id="oR.k/[email protected]%Hm3M;3hr"><comment pinned="false" h="140" w="265">Show confirmation if opponent has not already sent a move. If not, then the result of the match will be shown straight away.</comment><value name="IF0"><shadow type="logic_boolean"><field name="BOOL">TRUE</field></shadow><block type="logic_compare" id="C;#XCCklqUPV~3M5%*M$"><field name="OP">EQ</field><value name="A"><shadow type="math_number"><field name="NUM">0</field></shadow><block type="variables_get" id="Zw_PJUU-sAVLp5R6!QOT"><field name="VAR" id="8d*K^9H0![V*Kbq/}lJ]">Opponent</field></block></value><value name="B"><shadow type="math_number" id="BIqFBjPq7k0)giIppUgp"><field name="NUM">-1</field></shadow></value></block></value><statement name="DO0"><block type="basic_show_icon" id="g`Mte(]`r_|(`79ul4=B"><field name="i">IconNames.Yes</field></block></statement></block></next></block></next></block></statement><next><block type="controls_if" id="phke/pXAe)}Ug$enaEen"><mutation elseif="1" else="1"></mutation><comment pinned="false" h="80" w="160">Show hand picked</comment><value name="IF0"><shadow type="logic_boolean"><field name="BOOL">TRUE</field></shadow><block type="logic_compare" id="HV;WSI~rqh2$!?|u=S,*"><field name="OP">EQ</field><value name="A"><shadow type="math_number"><field name="NUM">0</field></shadow><block type="variables_get" id="uJC[zg4k.4~k;fy!y=_s"><field name="VAR" id="@r5Gd:yL!b-ihV!=+2CL">Hand</field></block></value><value name="B"><shadow type="math_number" id="o{xsBKSP,]r3%v|+3?!,"><field name="NUM">0</field></shadow></value></block></value><statement name="DO0"><block type="basic_show_icon" id="KetvwHi#t1r^hW-8m2F!"><field name="i">IconNames.SmallSquare</field></block></statement><value name="IF1"><block type="logic_compare" id="7-pmirpD@%n=iXp`?Zop"><field name="OP">EQ</field><value name="A"><shadow type="math_number"><field name="NUM">0</field></shadow><block type="variables_get" id="t@C_0fN:Kt)aW;hT~GW+"><field name="VAR" id="@r5Gd:yL!b-ihV!=+2CL">Hand</field></block></value><value name="B"><shadow type="math_number" id="Zm56Y`cJsWK~?NMW~m)e"><field name="NUM">1</field></shadow></value></block></value><statement name="DO1"><block type="basic_show_icon" id="MoRzkd:[!@UMH*c(Q3v-"><field name="i">IconNames.Square</field></block></statement><statement name="ELSE"><block type="basic_show_icon" id="M?mg;jUVQ:J(DCZK#27E"><field name="i">IconNames.Scissors</field></block></statement><next><block type="controls_if" id="1jaLq|k7B%D!w@q8W)~t"><value name="IF0"><shadow type="logic_boolean" disabled="true"><field name="BOOL">TRUE</field></shadow><block type="logic_operation" id="B:UID#;@-1_~TW]Ck|`h"><field name="OP">AND</field><value name="A"><block type="logic_compare" id="*0H;le{#;RV#@fA|mJF*"><field name="OP">GT</field><value name="A"><shadow type="math_number"><field name="NUM">0</field></shadow><block type="variables_get" id="E@_4-y|/g:y@QRDd?Cm0"><field name="VAR" id="8d*K^9H0![V*Kbq/}lJ]">Opponent</field></block></value><value name="B"><shadow type="math_number" id=").@vf^c-c,Gc7=sPtu6a"><field name="NUM">-1</field></shadow></value></block></value><value name="B"><block type="logic_compare" id="Oi,vNqPZls2RB%^!d3ex"><field name="OP">EQ</field><value name="A"><shadow type="math_number"><field name="NUM">0</field></shadow><block type="variables_get" id="pjjQD8A{?.M7-yTmx/_!"><field name="VAR" id="C^HOdD]X9WNK.DM+o#]7">Ready</field></block></value><value name="B"><shadow type="math_number" id="btT_?XGg1|PaxJ+Wr=RW"><field name="NUM">1</field></shadow></value></block></value></block></value><statement name="DO0"><block type="variables_set" id="[+cDyET1$R$zIg#;:0FW"><field name="VAR" id="?WWco)#Wi+{T]e;}MrGO">MatchResult</field><comment pinned="false" h="222" w="412">Match result calculated as (self - opponent)
Winning results:
0 - 2 = -2
2 - 1 = 1
1 - 0 = 1.
Losing results:
2 - 0 = 2
1 - 2 = -1
0 - 1 = -1.
0 is draw</comment><value name="VALUE"><shadow type="math_number"><field name="NUM">0</field></shadow><block type="math_arithmetic" id="I=]l{I7kmjn!j$Ti|*{8"><field name="OP">MINUS</field><value name="A"><shadow type="math_number"><field name="NUM">0</field></shadow><block type="variables_get" id="+J)JVXN%=AB?%_7xj3h^"><field name="VAR" id="@r5Gd:yL!b-ihV!=+2CL">Hand</field></block></value><value name="B"><shadow type="math_number"><field name="NUM">0</field></shadow><block type="variables_get" id="e`24w6iy+(aL9T[?+TQI"><field name="VAR" id="8d*K^9H0![V*Kbq/}lJ]">Opponent</field></block></value></block></value><next><block type="controls_if" id=")K:WgQT$`$B!r=_p`qI`"><mutation elseif="1" else="1"></mutation><value name="IF0"><shadow type="logic_boolean"><field name="BOOL">TRUE</field></shadow><block type="logic_operation" id="~F)]kf(kqLXv:wF]K*8|"><field name="OP">OR</field><value name="A"><block type="logic_compare" id="uK(=2v?p|v|H=p`6nXc}"><field name="OP">EQ</field><value name="A"><shadow type="math_number"><field name="NUM">0</field></shadow><block type="variables_get" id="c$WIXTRXBJoHLAj+rFDO"><field name="VAR" id="?WWco)#Wi+{T]e;}MrGO">MatchResult</field></block></value><value name="B"><shadow type="math_number" id="-Po$o7si661Pj~s]olS["><field name="NUM">-2</field></shadow></value></block></value><value name="B"><block type="logic_compare" id="4rQCwJ([email protected]*Br"><field name="OP">EQ</field><value name="A"><shadow type="math_number"><field name="NUM">0</field></shadow><block type="variables_get" id="=xy!b6eQn6KJ*8UT.!Ni"><field name="VAR" id="?WWco)#Wi+{T]e;}MrGO">MatchResult</field></block></value><value name="B"><shadow type="math_number" id="8`3FpccR.=/GJZ64NnC{"><field name="NUM">1</field></shadow></value></block></value></block></value><statement name="DO0"><block type="variables_change" id="bD*:+i}uk/N/%NsQLm?-"><field name="VAR" id="XS*hJ9Ot=r+;F+F#J_Xy">OpponentHealth</field><value name="VALUE"><shadow type="math_number" id="sXA`9-P]{G*HHOBb*g#W"><field name="NUM">-1</field></shadow></value><next><block type="basic_show_icon" id="`u-[MOxdm0Acr!yY/:(d"><field name="i">IconNames.Happy</field><comment pinned="false" h="80" w="160">You win!</comment><next><block type="music_playable_play_default_bkg" id="Ls|afo~,r_gcmAn;JT;="><field name="playbackMode">music.PlaybackMode.UntilDone</field><value name="toPlay"><shadow type="device_builtin_melody_playable" id="!#=[oZA{cw%b)8aXuw(,"><field name="melody">Melodies.PowerUp</field></shadow></value></block></next></block></next></block></statement><value name="IF1"><block type="logic_operation" id="nY9{R%t@!j?8J#~eJ!*H"><field name="OP">OR</field><value name="A"><block type="logic_compare" id="iAn29#LN`PlW04yU:go*"><field name="OP">EQ</field><value name="A"><shadow type="math_number"><field name="NUM">0</field></shadow><block type="variables_get" id="rPz^x9-s$6HlQvqpc32d"><field name="VAR" id="?WWco)#Wi+{T]e;}MrGO">MatchResult</field></block></value><value name="B"><shadow type="math_number" id="s:iCV7[/4d}iQ7d:PEt5"><field name="NUM">2</field></shadow></value></block></value><value name="B"><block type="logic_compare" id="F(t8BLjk{L4A~Fldp*F-"><field name="OP">EQ</field><value name="A"><shadow type="math_number"><field name="NUM">0</field></shadow><block type="variables_get" id="bI~aj]b4IVM5w$JrYtk@"><field name="VAR" id="?WWco)#Wi+{T]e;}MrGO">MatchResult</field></block></value><value name="B"><shadow type="math_number" id="k*I}[2dM7vTo8(.QGRnv"><field name="NUM">-1</field></shadow></value></block></value></block></value><statement name="DO1"><block type="variables_change" id="rTI5gA#:JULQbDblS|4$"><field name="VAR" id="QIaRB[7t)u)gY8|9gdg8">PlayerHealth</field><value name="VALUE"><shadow type="math_number" id="_SZvwI5U$.~h*_.!DNZV"><field name="NUM">-1</field></shadow></value><next><block type="basic_show_icon" id="3.,!j?Y2i|k5=[LZ7gVW"><field name="i">IconNames.Sad</field><comment pinned="false" h="80" w="160">You lose!</comment><next><block type="music_playable_play_default_bkg" id="y)3q~zO~@OIYf.@BMc:-"><field name="playbackMode">music.PlaybackMode.UntilDone</field><value name="toPlay"><shadow type="device_builtin_melody_playable" id="n.:3oOM_8ImqJ|:_OH4R"><field name="melody">Melodies.PowerDown</field></shadow></value></block></next></block></next></block></statement><statement name="ELSE"><block type="basic_show_icon" id="M/tY1^8aD@Y`*FRE1Hrl"><field name="i">IconNames.Surprised</field><comment pinned="false" h="80" w="160">Draw!</comment><next><block type="music_playable_play_default_bkg" id=";N#qYHf||uy0[GF7p20J"><field name="playbackMode">music.PlaybackMode.UntilDone</field><value name="toPlay"><shadow type="device_builtin_melody_playable" id=":@y~z:2n}1z)8(VNWFWK"><field name="melody">Melodies.BaDing</field></shadow></value></block></next></block></statement><next><block type="device_pause" id="%KhMJjA9;w~i6W7YZ9]R"><value name="pause"><shadow type="timePicker" id="YZbWK[cKwX@C5IRnQ#i."><field name="ms">2500</field></shadow></value><next><block type="variables_set" id="gfQq?euuc/?J/bd`#x*U"><field name="VAR" id="8d*K^9H0![V*Kbq/}lJ]">Opponent</field><value name="VALUE"><shadow type="math_number" id="OF6[JUy5SThuK1{=c:vy"><field name="NUM">-1</field></shadow></value><next><block type="variables_set" id="rGLQ|XIiM3+.rf]C5vt$"><field name="VAR" id="C^HOdD]X9WNK.DM+o#]7">Ready</field><value name="VALUE"><shadow type="math_number" id="|8+!2LY+85fI8uM!:KNs"><field name="NUM">0</field></shadow></value><next><block type="controls_if" id="TrNr)d-x+uWRZ~wm^R#m"><mutation elseif="1"></mutation><value name="IF0"><shadow type="logic_boolean"><field name="BOOL">TRUE</field></shadow><block type="logic_compare" id="2r4Hh)rwHht+kKW_|%uV"><field name="OP">LT</field><value name="A"><shadow type="math_number"><field name="NUM">0</field></shadow><block type="variables_get" id="pz3ZX3H7e/W0H}p)t.f,"><field name="VAR" id="XS*hJ9Ot=r+;F+F#J_Xy">OpponentHealth</field></block></value><value name="B"><shadow type="math_number" id="^yy4A82R!q[EPWm|!!jy"><field name="NUM">1</field></shadow></value></block></value><statement name="DO0"><block type="variables_change" id="aQ8eQ+ZE=uh?nMB:gx?M"><field name="VAR" id="kb;{qbqSwGkJEnLZ}Jhf">TotalWins</field><value name="VALUE"><shadow type="math_number" id="ZiwA+k4d}r{RTzCq-DkO"><field name="NUM">1</field></shadow></value><next><block type="music_playable_play_default_bkg" id="OJnsj4vse`M:cc;={}6e"><field name="playbackMode">music.PlaybackMode.InBackground</field><value name="toPlay"><shadow type="device_builtin_melody_playable" id="k[sT#h5{=f]`[Py*{*qm"><field name="melody">Melodies.Entertainer</field></shadow></value><next><block type="device_print_message" id="N-@foQU|nY$RWAdcl!-a"><value name="text"><shadow type="text" id=",o47w3J8H}a+jp(yNZhK"><field name="TEXT">You Win!</field></shadow></value><next><block type="break_keyword" id="j{]uVlkc-r}VFZ)]:Q~Q"></block></next></block></next></block></next></block></statement><value name="IF1"><block type="logic_compare" id="SUpBOL5;-/}A2yui;`lN"><field name="OP">LT</field><value name="A"><shadow type="math_number"><field name="NUM">0</field></shadow><block type="variables_get" id="~;weg;B#8?FrBwkG0_)k"><field name="VAR" id="QIaRB[7t)u)gY8|9gdg8">PlayerHealth</field></block></value><value name="B"><shadow type="math_number" id="8E*)qP1;=E_r`nS5BZw^"><field name="NUM">1</field></shadow></value></block></value><statement name="DO1"><block type="music_playable_play_default_bkg" id="0s_G.]`*D+1/#h_aa+Nu"><field name="playbackMode">music.PlaybackMode.InBackground</field><value name="toPlay"><shadow type="device_builtin_melody_playable" id="}HSb~Z-sP^1eXIuTkO|m"><field name="melody">Melodies.Wawawawaa</field></shadow></value><next><block type="device_print_message" id="s(LiTQ*6Y;6L/;*?n$H%"><value name="text"><shadow type="text" id=":EJR$oSwGS$.Z@/Ho+iC"><field name="TEXT">You Lose!</field></shadow></value><next><block type="break_keyword" id="i,yT*K31[!n?G8d7.iza"></block></next></block></next></block></statement></block></next></block></next></block></next></block></next></block></next></block></statement></block></next></block></next></block></next></block></statement><next><block type="function_call" id="CB1bq6^_#,w`jkY]WpuH"><mutation name="HomeScreen" functionid="MSukxV,e9(d7x%N3.Pw}"></mutation></block></next></block></statement></block><block type="pxt-on-start" id="aBT#H}XB-Y#tmirfzK0:" x="-868" y="142"><statement name="HANDLER"><block type="variables_set" id="@JB;;fK23t*d=!rjX^;3"><field name="VAR" id="kb;{qbqSwGkJEnLZ}Jhf">TotalWins</field><value name="VALUE"><shadow type="math_number" id="/~*ItKp$F{o)mVtr,|!0"><field name="NUM">0</field></shadow></value><next><block type="variables_set" id=")$}N,{2{~(W@0;:R*6NB"><field name="VAR" id="EG^/:LbHx/r4#(9V!+0.">RadioGroup</field><value name="VALUE"><shadow type="math_number" id="z`iYNNIv|/:K_FvVvfa]"><field name="NUM">0</field></shadow></value><next><block type="variables_set" id="N#^la_1gjlnlEf]9gjeV"><field name="VAR" id="@r5Gd:yL!b-ihV!=+2CL">Hand</field><value name="VALUE"><shadow type="math_number" id="|+75NKG)}d1qK!rU@)3I"><field name="NUM">0</field></shadow></value><next><block type="variables_set" id="jqv@MRu^JzSB1[x}7$2%"><field name="VAR" id="C^HOdD]X9WNK.DM+o#]7">Ready</field><comment pinned="false" h="80" w="160">Used for "three way handshake"</comment><value name="VALUE"><shadow type="math_number" id="?,V#{H8507Kh,ez)Hu$x"><field name="NUM">0</field></shadow></value><next><block type="variables_set" id="Y*|HcJL|ON#w}MAg]L}["><field name="VAR" id="8d*K^9H0![V*Kbq/}lJ]">Opponent</field><comment pinned="false" h="80" w="160">Stores received opponent hand. -1 marks no choice</comment><value name="VALUE"><shadow type="math_number" id="NTcw_AbLJYmd*@1q.C.?"><field name="NUM">-1</field></shadow></value><next><block type="function_call" id=":{y?H/O=1M[{@Zkqsd4J"><mutation name="HomeScreen" functionid="MSukxV,e9(d7x%N3.Pw}"></mutation></block></next></block></next></block></next></block></next></block></next></block></statement></block><block type="radio_on_number_drag" id="R7A)U-t;An{}8w]VWCEU" x="-867" y="529"><value name="HANDLER_DRAG_PARAM_receivedNumber"><shadow type="argument_reporter_number" id="(+57X:d8uc0O$h^2nuJK"><field name="VALUE">receivedNumber</field></shadow></value><statement name="HANDLER"><block type="variables_set" id="nQDo9qZq_i.dgtj4hNfe"><field name="VAR" id="8d*K^9H0![V*Kbq/}lJ]">Opponent</field><value name="VALUE"><shadow type="math_number"><field name="NUM">0</field></shadow><block type="argument_reporter_number" id="YytEVbFx9/3hDvwvme)x"><field name="VALUE">receivedNumber</field></block></value></block></statement></block></xml>