diff options
author | SinSloth <SinSloth@54d463be-8e91-2dee-dedb-b68131a5f0ec> | 2007-06-09 16:01:23 +0000 |
---|---|---|
committer | SinSloth <SinSloth@54d463be-8e91-2dee-dedb-b68131a5f0ec> | 2007-06-09 16:01:23 +0000 |
commit | 8c47ae11d90922551d635ae06bde40e5d6723fae (patch) | |
tree | f3878612068d69a19b1fab3402181cf4d08f4218 /npc/other | |
parent | 306c786b5695d14319e2a31e55d7a0cb5a5b6763 (diff) | |
download | hercules-8c47ae11d90922551d635ae06bde40e5d6723fae.tar.gz hercules-8c47ae11d90922551d635ae06bde40e5d6723fae.tar.bz2 hercules-8c47ae11d90922551d635ae06bde40e5d6723fae.tar.xz hercules-8c47ae11d90922551d635ae06bde40e5d6723fae.zip |
* Added Hugel Bingo game system. Please test it and report any bugs.
- 'nosave' mapflag added to the map.
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@10734 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'npc/other')
-rw-r--r-- | npc/other/hugel_bingo.txt | 1120 |
1 files changed, 1120 insertions, 0 deletions
diff --git a/npc/other/hugel_bingo.txt b/npc/other/hugel_bingo.txt new file mode 100644 index 000000000..16ee282bf --- /dev/null +++ b/npc/other/hugel_bingo.txt @@ -0,0 +1,1120 @@ +//===== eAthena Script ======================================= +//= Hugel Bingo script +//===== By: ================================================== +//= SinSloth +//===== Current Version: ===================================== +//= 1.0 +//===== Compatible With: ===================================== +//= Any eAthena Version +//===== Description: ========================================= +//= Hugel Bingo game +//===== Additional Comments: ================================= +//= 1.0 - First version. Please report bugs you find out. [SinSloth] +//============================================================ + +que_bingo,48,84,5 script Bingo Waiting Room 124,{ + end; + +OnInit: + set $hu_bingoa,0; + set $hu_bingob,0; + waitingroom "Bingo Waiting Room - 5 People",50,"Bingo Waiting Room::OnWarp",5; + end; + +OnWarp: + warpwaitingpc "que_bingo",46,141; + donpcevent "start#bingo::OnStart"; + enablenpc "plate1#bingo"; + enablenpc "plate2#bingo"; + enablenpc "plate3#bingo"; + enablenpc "plate4#bingo"; + enablenpc "plate5#bingo"; + disablewaitingroomevent; + end; + +OnStart: + enablewaitingroomevent; + end; +} + +que_bingo,49,125,0 script plate1#bingo 139,1,1,{ + +OnInit: + disablenpc "plate1#bingo"; + disablenpc "plate2#bingo"; + disablenpc "plate3#bingo"; + disablenpc "plate4#bingo"; + disablenpc "plate5#bingo"; + end; + +OnTouch: + set Zeny,Zeny -1000; + set @bingo_a1$,0; + set @bingo_a2$,0; + set @bingo_a3$,0; + set @bingo_a4$,0; + set @bingo_a5$,0; + set @bingo_b1$,0; + set @bingo_b2$,0; + set @bingo_b3$,0; + set @bingo_b4$,0; + set @bingo_b5$,0; + set @bingo_c1$,0; + set @bingo_c2$,0; + set @bingo_c3$,0; + set @bingo_c4$,0; + set @bingo_c5$,0; + set @bingo_d1$,0; + set @bingo_d2$,0; + set @bingo_d3$,0; + set @bingo_d4$,0; + set @bingo_d5$,0; + set @bingo_e1$,0; + set @bingo_e2$,0; + set @bingo_e3$,0; + set @bingo_e4$,0; + set @bingo_e5$,0; + set @bingo_case,1; +L_Fill: + set @bingo_fill,callfunc("Func_Bingo",@bingo_case); + if(!@bingo_fill) + { + mes "The numbers you have entered"; + mes "exceed the limit, or you have"; + mes "already entered these numbers."; + mes "Please enter your numbers again."; + next; + } + else if(@bingo_fill) + { + if(@bingoplate[25] < 10) set @bingo_e5$,"0"+@bingoplate[25]+""; else set @bingo_e5$,@bingoplate[25]; + donpcevent "start#bingo::OnEnter"; + mes "["+@bingo_a1$+"] ["+@bingo_a2$+"] ["+@bingo_a3$+"] ["+@bingo_a4$+"] ["+@bingo_a5$+"]"; + mes "["+@bingo_b1$+"] ["+@bingo_b2$+"] ["+@bingo_b3$+"] ["+@bingo_b4$+"] ["+@bingo_b5$+"]"; + mes "["+@bingo_c1$+"] ["+@bingo_c2$+"] ["+@bingo_c3$+"] ["+@bingo_c4$+"] ["+@bingo_c5$+"]"; + mes "["+@bingo_d1$+"] ["+@bingo_d2$+"] ["+@bingo_d3$+"] ["+@bingo_d4$+"] ["+@bingo_d5$+"]"; + mes "["+@bingo_e1$+"] ["+@bingo_e2$+"] ["+@bingo_e3$+"] ["+@bingo_e4$+"] ["+@bingo_e5$+"]"; + close; + + } + goto L_Fill; + +} + +que_bingo,53,121,0 duplicate(plate1#bingo) plate2#bingo 139,1,1 +que_bingo,51,116,0 duplicate(plate1#bingo) plate3#bingo 139,1,1 +que_bingo,46,116,0 duplicate(plate1#bingo) plate4#bingo 139,1,1 +que_bingo,45,121,0 duplicate(plate1#bingo) plate5#bingo 139,1,1 + +que_bingo,51,51,0 script start#bingo 139,{ + +OnStart: + initnpctimer; + end; + +OnEnter: + if($hu_bingoa == 4) + { + set $hu_bingoa,5; + donpcevent "start2#bingo::OnStart"; + stopnpctimer; + end; + } + set $hu_bingoa,$hu_bingoa +1; + end; + +OnTimer1000: + mapannounce "que_bingo","Eukran: Hello, everyone! I'm Eukran, your Bingo Guide~",1,0xFFAB54; + end; + +OnTimer6000: + mapannounce "que_bingo","Eukran: Game participants, please enter the Warp Portal at the bottom of your screen and choose a Bingo Plate by entering a number.",1,0xFFAB54; + end; + +OnTimer11000: + mapannounce "que_bingo","Eukran: All participants must choose their Bingo Plates within 3 minutes, or the game will be canceled.",1,0xFFAB54; + end; + +OnTimer192000: + mapannounce "que_bingo","Eukran: Please enter a number in 5 seconds, or the game will be canceled.",1,0xFFAB54; + end; + +OnTimer200000: + mapannounce "que_bingo","Eukran: I'm sorry, but the game has been canceled. Please come again and enjoy a game of Bingo with us!",1,0xFFAB54; + end; + +OnTimer202000: + disablenpc "plate1#bingo"; + disablenpc "plate2#bingo"; + disablenpc "plate3#bingo"; + disablenpc "plate4#bingo"; + disablenpc "plate5#bingo"; + end; + +OnTimer203000: + donpcevent "player1#bingo::OnOut"; + donpcevent "player2#bingo::OnOut"; + donpcevent "player3#bingo::OnOut"; + donpcevent "player4#bingo::OnOut"; + donpcevent "player5#bingo::OnOut"; + enablenpc "out3#bingo"; + end; + +OnTimer201000: + donpcevent "player1#bingo::OnInit"; + donpcevent "player2#bingo::OnInit"; + donpcevent "player3#bingo::OnInit"; + donpcevent "player4#bingo::OnInit"; + donpcevent "player5#bingo::OnInit"; + disablenpc "out3#bingo"; + set $hu_bingoa,0; + donpcevent "Bingo Waiting Room::OnStart"; + end; +} + +que_bingo,49,125,0 script player1#bingo 139,1,1,{ + +OnInit: + disablenpc "player1#bingo"; + end; + +OnOut: + enablenpc "player1#bingo"; + end; + +OnTouch: + warp "que_bingo",40,124; + end; +} + +que_bingo,53,121,0 script player2#bingo 139,1,1,{ + +OnInit: + disablenpc "player2#bingo"; + end; + +OnOut: + enablenpc "player2#bingo"; + end; + +OnTouch: + warp "que_bingo",40,124; + end; +} + +que_bingo,51,116,0 script player3#bingo 139,1,1,{ + +OnInit: + disablenpc "player3#bingo"; + end; + +OnOut: + enablenpc "player3#bingo"; + end; + +OnTouch: + warp "que_bingo",40,124; + end; +} + +que_bingo,46,116,0 script player4#bingo 139,1,1,{ + +OnInit: + disablenpc "player4#bingo"; + end; + +OnOut: + enablenpc "player4#bingo"; + end; + +OnTouch: + warp "que_bingo",40,124; + end; +} + +que_bingo,45,121,0 script player5#bingo 139,1,1,{ + +OnInit: + disablenpc "player5#bingo"; + end; + +OnOut: + enablenpc "player5#bingo"; + end; + +OnTouch: + warp "que_bingo",40,124; + end; +} + +que_bingo,52,52,0 script start2#bingo 139,{ + +OnStop: + stopnpctimer; + end; + +OnStart: + initnpctimer; + end; + +OnTimer2000: + mapannounce "que_bingo","Eukran: Great, everyone seems to be ready~",1,0xFFAB54; + disablenpc "plate1#bingo"; + disablenpc "plate2#bingo"; + disablenpc "plate3#bingo"; + disablenpc "plate4#bingo"; + disablenpc "plate5#bingo"; + end; + +OnTimer5000: + mapannounce "que_bingo","Eukran: Now, let the game begin!",1,0xFFAB54; + setarray $@bingoarray[0],1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25; + for(set .@i,0; .@i < 25; set .@i,.@i +1) + { +L_Roll: + set $@bingo0,rand(0,24); + setarray $bingo[.@i],$@bingoarray[$@bingo0]; + if(!$bingo[.@i]) goto L_Roll; + cleararray $@bingoarray[$@bingo0],0,1; + } + end; + +OnTimer8000: + mapannounce "que_bingo","Eukran: I'll announce the Bingo Numbers. If you get 5 lines by matching 5 Bingo Numbers in a straight line on your Bingo Plate, yell out ''Bingo'' to win~",1,0xFFAB54; + end; + +OnTimer10000: + set $@bingoresult,1; + callfunc "Func_BingoResult",$@bingoresult; + end; + +OnTimer15000: + donpcevent "1a#bingo::OnInit"; + end; + +OnTimer20000: + callfunc "Func_BingoResult",$@bingoresult; + end; + +OnTimer25000: + donpcevent "1a#bingo::OnInit"; + end; + +OnTimer30000: + callfunc "Func_BingoResult",$@bingoresult; + end; + +OnTimer35000: + donpcevent "1a#bingo::OnInit"; + end; + +OnTimer40000: + callfunc "Func_BingoResult",$@bingoresult; + end; + +OnTimer45000: + donpcevent "1a#bingo::OnInit"; + end; + +OnTimer50000: + callfunc "Func_BingoResult",$@bingoresult; + end; + +OnTimer55000: + donpcevent "1a#bingo::OnInit"; + end; + +OnTimer60000: + callfunc "Func_BingoResult",$@bingoresult; + end; + +OnTimer65000: + donpcevent "1a#bingo::OnInit"; + end; + +OnTimer70000: + callfunc "Func_BingoResult",$@bingoresult; + end; + +OnTimer75000: + donpcevent "1a#bingo::OnInit"; + end; + +OnTimer80000: + callfunc "Func_BingoResult",$@bingoresult; + end; + +OnTimer85000: + donpcevent "1a#bingo::OnInit"; + end; + +OnTimer90000: + callfunc "Func_BingoResult",$@bingoresult; + end; + +OnTimer95000: + donpcevent "1a#bingo::OnInit"; + end; + +OnTimer100000: + callfunc "Func_BingoResult",$@bingoresult; + end; + +OnTimer105000: + donpcevent "1a#bingo::OnInit"; + end; + +OnTimer110000: + callfunc "Func_BingoResult",$@bingoresult; + end; + +OnTimer115000: + donpcevent "1a#bingo::OnInit"; + end; + +OnTimer120000: + callfunc "Func_BingoResult",$@bingoresult; + end; + +OnTimer125000: + donpcevent "1a#bingo::OnInit"; + end; + +OnTimer130000: + callfunc "Func_BingoResult",$@bingoresult; + end; + +OnTimer135000: + donpcevent "1a#bingo::OnInit"; + end; + +OnTimer140000: + callfunc "Func_BingoResult",$@bingoresult; + end; + +OnTimer145000: + donpcevent "1a#bingo::OnInit"; + end; + +OnTimer150000: + callfunc "Func_BingoResult",$@bingoresult; + end; + +OnTimer155000: + donpcevent "1a#bingo::OnInit"; + end; + +OnTimer160000: + callfunc "Func_BingoResult",$@bingoresult; + end; + +OnTimer179000: + donpcevent "1a#bingo::OnInit"; + end; + +OnTimer180000: + callfunc "Func_BingoResult",$@bingoresult; + end; + +OnTimer199000: + donpcevent "1a#bingo::OnInit"; + end; + +OnTimer200000: + callfunc "Func_BingoResult",$@bingoresult; + end; + +OnTimer219000: + donpcevent "1a#bingo::OnInit"; + end; + +OnTimer220000: + callfunc "Func_BingoResult",$@bingoresult; + end; + +OnTimer239000: + donpcevent "1a#bingo::OnInit"; + end; + +OnTimer240000: + callfunc "Func_BingoResult",$@bingoresult; + end; + +OnTimer259000: + donpcevent "1a#bingo::OnInit"; + end; + +OnTimer260000: + callfunc "Func_BingoResult",$@bingoresult; + end; + +OnTimer279000: + donpcevent "1a#bingo::OnInit"; + end; + +OnTimer280000: + callfunc "Func_BingoResult",$@bingoresult; + end; + +OnTimer299000: + donpcevent "1a#bingo::OnInit"; + end; + +OnTimer300000: + callfunc "Func_BingoResult",$@bingoresult; + end; + +OnTimer319000: + donpcevent "1a#bingo::OnInit"; + end; + +OnTimer320000: + callfunc "Func_BingoResult",$@bingoresult; + end; + +OnTimer339000: + donpcevent "1a#bingo::OnInit"; + end; + +OnTimer340000: + callfunc "Func_BingoResult",$@bingoresult; + end; + +OnTimer440000: + mapannounce "que_bingo","Eukran: I've announced all of the selected numbers, but I haven't heard anyone yell ''Bingo.''",1,0xFFAB54; + end; + +OnTimer445000: + mapannounce "que_bingo","Eukran: I'll give you all 10 seconds to check if any of you have won. If no one can yell ''Bingo'' in 10 seconds, this game will end without a winner.",1,0xFFAB54; + end; + +OnTimer460000: + mapannounce "que_bingo","Eukran: I'm sorry, but this game has ended without a winner. Thanks for playing, everyone~",1,0xFFAB54; + donpcevent "1a#bingo::OnInit"; + donpcevent "player1#bingo::OnOut"; + donpcevent "player2#bingo::OnOut"; + donpcevent "player3#bingo::OnOut"; + donpcevent "player4#bingo::OnOut"; + donpcevent "player5#bingo::OnOut"; + set $hu_bingoa,0; + donpcevent "Bingo Waiting Room::OnStart"; + end; +} + +que_bingo,49,125,0 script 1a#bingo 139,1,1,{ + end; + +OnInit: + disablenpc "1a#bingo"; + disablenpc "2a#bingo"; + disablenpc "3a#bingo"; + disablenpc "4a#bingo"; + disablenpc "5a#bingo"; + disablenpc "6a#bingo"; + disablenpc "7a#bingo"; + disablenpc "8a#bingo"; + disablenpc "9a#bingo"; + disablenpc "10a#bingo"; + disablenpc "11a#bingo"; + disablenpc "12a#bingo"; + disablenpc "13a#bingo"; + disablenpc "14a#bingo"; + disablenpc "15a#bingo"; + disablenpc "16a#bingo"; + disablenpc "17a#bingo"; + disablenpc "18a#bingo"; + disablenpc "19a#bingo"; + disablenpc "20a#bingo"; + disablenpc "21a#bingo"; + disablenpc "22a#bingo"; + disablenpc "23a#bingo"; + disablenpc "24a#bingo"; + disablenpc "25a#bingo"; + disablenpc "1b#bingo"; + disablenpc "2b#bingo"; + disablenpc "3b#bingo"; + disablenpc "4b#bingo"; + disablenpc "5b#bingo"; + disablenpc "6b#bingo"; + disablenpc "7b#bingo"; + disablenpc "8b#bingo"; + disablenpc "9b#bingo"; + disablenpc "10b#bingo"; + disablenpc "11b#bingo"; + disablenpc "12b#bingo"; + disablenpc "13b#bingo"; + disablenpc "14b#bingo"; + disablenpc "15b#bingo"; + disablenpc "16b#bingo"; + disablenpc "17b#bingo"; + disablenpc "18b#bingo"; + disablenpc "19b#bingo"; + disablenpc "20b#bingo"; + disablenpc "21b#bingo"; + disablenpc "22b#bingo"; + disablenpc "23b#bingo"; + disablenpc "24b#bingo"; + disablenpc "25b#bingo"; + disablenpc "1c#bingo"; + disablenpc "2c#bingo"; + disablenpc "3c#bingo"; + disablenpc "4c#bingo"; + disablenpc "5c#bingo"; + disablenpc "6c#bingo"; + disablenpc "7c#bingo"; + disablenpc "8c#bingo"; + disablenpc "9c#bingo"; + disablenpc "10c#bingo"; + disablenpc "11c#bingo"; + disablenpc "12c#bingo"; + disablenpc "13c#bingo"; + disablenpc "14c#bingo"; + disablenpc "15c#bingo"; + disablenpc "16c#bingo"; + disablenpc "17c#bingo"; + disablenpc "18c#bingo"; + disablenpc "19c#bingo"; + disablenpc "20c#bingo"; + disablenpc "21c#bingo"; + disablenpc "22c#bingo"; + disablenpc "23c#bingo"; + disablenpc "24c#bingo"; + disablenpc "25c#bingo"; + disablenpc "1d#bingo"; + disablenpc "2d#bingo"; + disablenpc "3d#bingo"; + disablenpc "4d#bingo"; + disablenpc "5d#bingo"; + disablenpc "6d#bingo"; + disablenpc "7d#bingo"; + disablenpc "8d#bingo"; + disablenpc "9d#bingo"; + disablenpc "10d#bingo"; + disablenpc "11d#bingo"; + disablenpc "12d#bingo"; + disablenpc "13d#bingo"; + disablenpc "14d#bingo"; + disablenpc "15d#bingo"; + disablenpc "16d#bingo"; + disablenpc "17d#bingo"; + disablenpc "18d#bingo"; + disablenpc "19d#bingo"; + disablenpc "20d#bingo"; + disablenpc "21d#bingo"; + disablenpc "22d#bingo"; + disablenpc "23d#bingo"; + disablenpc "24d#bingo"; + disablenpc "25d#bingo"; + disablenpc "1e#bingo"; + disablenpc "2e#bingo"; + disablenpc "3e#bingo"; + disablenpc "4e#bingo"; + disablenpc "5e#bingo"; + disablenpc "6e#bingo"; + disablenpc "7e#bingo"; + disablenpc "8e#bingo"; + disablenpc "9e#bingo"; + disablenpc "10e#bingo"; + disablenpc "11e#bingo"; + disablenpc "12e#bingo"; + disablenpc "13e#bingo"; + disablenpc "14e#bingo"; + disablenpc "15e#bingo"; + disablenpc "16e#bingo"; + disablenpc "17e#bingo"; + disablenpc "18e#bingo"; + disablenpc "19e#bingo"; + disablenpc "20e#bingo"; + disablenpc "21e#bingo"; + disablenpc "22e#bingo"; + disablenpc "23e#bingo"; + disablenpc "24e#bingo"; + disablenpc "25e#bingo"; + end; + +OnTouch: + if(@bingoplate[1] == $bingo[$@bingoresult -1]){ set @bingo_a1$,"^ff0000- -^000000"; setarray @bingoplate[1],99; } + else if(@bingoplate[2] == $bingo[$@bingoresult -1]){ set @bingo_a2$,"^ff0000- -^000000"; setarray @bingoplate[2],99; } + else if(@bingoplate[3] == $bingo[$@bingoresult -1]){ set @bingo_a3$,"^ff0000- -^000000"; setarray @bingoplate[3],99; } + else if(@bingoplate[4] == $bingo[$@bingoresult -1]){ set @bingo_a4$,"^ff0000- -^000000"; setarray @bingoplate[4],99; } + else if(@bingoplate[5] == $bingo[$@bingoresult -1]){ set @bingo_a5$,"^ff0000- -^000000"; setarray @bingoplate[5],99; } + else if(@bingoplate[6] == $bingo[$@bingoresult -1]){ set @bingo_b1$,"^ff0000- -^000000"; setarray @bingoplate[6],99; } + else if(@bingoplate[7] == $bingo[$@bingoresult -1]){ set @bingo_b2$,"^ff0000- -^000000"; setarray @bingoplate[7],99; } + else if(@bingoplate[8] == $bingo[$@bingoresult -1]){ set @bingo_b3$,"^ff0000- -^000000"; setarray @bingoplate[8],99; } + else if(@bingoplate[9] == $bingo[$@bingoresult -1]){ set @bingo_b4$,"^ff0000- -^000000"; setarray @bingoplate[9],99; } + else if(@bingoplate[10] == $bingo[$@bingoresult -1]){ set @bingo_b5$,"^ff0000- -^000000"; setarray @bingoplate[10],99; } + else if(@bingoplate[11] == $bingo[$@bingoresult -1]){ set @bingo_c1$,"^ff0000- -^000000"; setarray @bingoplate[11],99; } + else if(@bingoplate[12] == $bingo[$@bingoresult -1]){ set @bingo_c2$,"^ff0000- -^000000"; setarray @bingoplate[12],99; } + else if(@bingoplate[13] == $bingo[$@bingoresult -1]){ set @bingo_c3$,"^ff0000- -^000000"; setarray @bingoplate[13],99; } + else if(@bingoplate[14] == $bingo[$@bingoresult -1]){ set @bingo_c4$,"^ff0000- -^000000"; setarray @bingoplate[14],99; } + else if(@bingoplate[15] == $bingo[$@bingoresult -1]){ set @bingo_c5$,"^ff0000- -^000000"; setarray @bingoplate[15],99; } + else if(@bingoplate[16] == $bingo[$@bingoresult -1]){ set @bingo_d1$,"^ff0000- -^000000"; setarray @bingoplate[16],99; } + else if(@bingoplate[17] == $bingo[$@bingoresult -1]){ set @bingo_d2$,"^ff0000- -^000000"; setarray @bingoplate[17],99; } + else if(@bingoplate[18] == $bingo[$@bingoresult -1]){ set @bingo_d3$,"^ff0000- -^000000"; setarray @bingoplate[18],99; } + else if(@bingoplate[19] == $bingo[$@bingoresult -1]){ set @bingo_d4$,"^ff0000- -^000000"; setarray @bingoplate[19],99; } + else if(@bingoplate[20] == $bingo[$@bingoresult -1]){ set @bingo_d5$,"^ff0000- -^000000"; setarray @bingoplate[20],99; } + else if(@bingoplate[21] == $bingo[$@bingoresult -1]){ set @bingo_e1$,"^ff0000- -^000000"; setarray @bingoplate[21],99; } + else if(@bingoplate[22] == $bingo[$@bingoresult -1]){ set @bingo_e2$,"^ff0000- -^000000"; setarray @bingoplate[22],99; } + else if(@bingoplate[23] == $bingo[$@bingoresult -1]){ set @bingo_e3$,"^ff0000- -^000000"; setarray @bingoplate[23],99; } + else if(@bingoplate[24] == $bingo[$@bingoresult -1]){ set @bingo_e4$,"^ff0000- -^000000"; setarray @bingoplate[24],99; } + else if(@bingoplate[25] == $bingo[$@bingoresult -1]){ set @bingo_e5$,"^ff0000- -^000000"; setarray @bingoplate[25],99; } + set @bingowin,0; + if(@bingoplate[1] == @bingoplate[2] && @bingoplate[1] == @bingoplate[3] && @bingoplate[1] == @bingoplate[4] && @bingoplate[1] == @bingoplate[5]) set @bingowin,@bingowin +1; + if(@bingoplate[6] == @bingoplate[7] && @bingoplate[6] == @bingoplate[8] && @bingoplate[6] == @bingoplate[9] && @bingoplate[6] == @bingoplate[10]) set @bingowin,@bingowin +1; + if(@bingoplate[11] == @bingoplate[12] && @bingoplate[11] == @bingoplate[13] && @bingoplate[11] == @bingoplate[14] && @bingoplate[11] == @bingoplate[15]) set @bingowin,@bingowin +1; + if(@bingoplate[16] == @bingoplate[17] && @bingoplate[16] == @bingoplate[18] && @bingoplate[16] == @bingoplate[19] && @bingoplate[16] == @bingoplate[20]) set @bingowin,@bingowin +1; + if(@bingoplate[21] == @bingoplate[22] && @bingoplate[21] == @bingoplate[23] && @bingoplate[21] == @bingoplate[24] && @bingoplate[21] == @bingoplate[25]) set @bingowin,@bingowin +1; + if(@bingoplate[1] == @bingoplate[6] && @bingoplate[1] == @bingoplate[11] && @bingoplate[1] == @bingoplate[16] && @bingoplate[1] == @bingoplate[21]) set @bingowin,@bingowin +1; + if(@bingoplate[2] == @bingoplate[7] && @bingoplate[2] == @bingoplate[12] && @bingoplate[2] == @bingoplate[17] && @bingoplate[2] == @bingoplate[22]) set @bingowin,@bingowin +1; + if(@bingoplate[3] == @bingoplate[8] && @bingoplate[3] == @bingoplate[13] && @bingoplate[3] == @bingoplate[18] && @bingoplate[3] == @bingoplate[23]) set @bingowin,@bingowin +1; + if(@bingoplate[4] == @bingoplate[9] && @bingoplate[4] == @bingoplate[14] && @bingoplate[4] == @bingoplate[19] && @bingoplate[4] == @bingoplate[24]) set @bingowin,@bingowin +1; + if(@bingoplate[5] == @bingoplate[10] && @bingoplate[5] == @bingoplate[15] && @bingoplate[5] == @bingoplate[20] && @bingoplate[5] == @bingoplate[25]) set @bingowin,@bingowin +1; + if(@bingoplate[1] == @bingoplate[7] && @bingoplate[1] == @bingoplate[13] && @bingoplate[1] == @bingoplate[19] && @bingoplate[1] == @bingoplate[25]) set @bingowin,@bingowin +1; + if(@bingoplate[5] == @bingoplate[9] && @bingoplate[5] == @bingoplate[13] && @bingoplate[5] == @bingoplate[17] && @bingoplate[5] == @bingoplate[21]) set @bingowin,@bingowin +1; + if($@bingoresult == 1 || $@bingoresult == 21) mes "[ "+$@bingoresult+"st Number - "+$bingo[$@bingoresult -1]+" ]"; + else if($@bingoresult == 2 || $@bingoresult == 22) mes "[ "+$@bingoresult+"nd Number - "+$bingo[$@bingoresult -1]+" ]"; + else if($@bingoresult == 3 || $@bingoresult == 23) mes "[ "+$@bingoresult+"rd Number - "+$bingo[$@bingoresult -1]+" ]"; + else mes "[ "+$@bingoresult+"th Number - "+$bingo[$@bingoresult -1]+" ]"; + mes "["+@bingo_a1$+"] ["+@bingo_a2$+"] ["+@bingo_a3$+"] ["+@bingo_a4$+"] ["+@bingo_a5$+"]"; + mes "["+@bingo_b1$+"] ["+@bingo_b2$+"] ["+@bingo_b3$+"] ["+@bingo_b4$+"] ["+@bingo_b5$+"]"; + mes "["+@bingo_c1$+"] ["+@bingo_c2$+"] ["+@bingo_c3$+"] ["+@bingo_c4$+"] ["+@bingo_c5$+"]"; + mes "["+@bingo_d1$+"] ["+@bingo_d2$+"] ["+@bingo_d3$+"] ["+@bingo_d4$+"] ["+@bingo_d5$+"]"; + mes "["+@bingo_e1$+"] ["+@bingo_e2$+"] ["+@bingo_e3$+"] ["+@bingo_e4$+"] ["+@bingo_e5$+"]"; + mes "[Currently Finished Lines - "+@bingowin+" ]"; + if($@bingoresult > 15) + { + if(@bingowin > 4) + { + next; + mes "We just have made 5 lines!"; + mes "Say ^ff0000Bingo^000000!"; + mes "W-we just matched"; + mes "5 numbers in a row!"; + mes "Quickly, say ''^FF0000Bingo^000000!''"; + mes "Remember, you'll only"; + mes "have one chance to say it!"; + input @bingoyell$; + if(@bingoyell$ == "Bingo") + { + if($hu_bingoa == 5) + { + set $hu_bingoa,6; + donpcevent "start2#bingo::OnStop"; + set $@bingowinner$,strcharinfo(0); + donpcevent "win1a#bingo::OnWin"; + close; + + } + else if($hu_bingoa == 6) + { + next; + mes "Oh no! I'm sorry, but"; + mes "someone already yelled"; + mes "''bingo'' before you did."; + mes "I'm sorry, but you missed"; + mes "your chance! Better luck,"; + mes "next time, alright?"; + close; + } + } + else + { + next; + mes "I'm sorry, but you"; + mes "said it wrong. Next time,"; + mes "make sure that you yell"; + mes "out the word, ''^FF0000Bingo^000000,'' okay?"; + close; + } + } + close; + } + close; +} + +que_bingo,49,125,0 duplicate(1a#bingo) 2a#bingo 139,1,1 +que_bingo,49,125,0 duplicate(1a#bingo) 3a#bingo 139,1,1 +que_bingo,49,125,0 duplicate(1a#bingo) 4a#bingo 139,1,1 +que_bingo,49,125,0 duplicate(1a#bingo) 5a#bingo 139,1,1 +que_bingo,49,125,0 duplicate(1a#bingo) 6a#bingo 139,1,1 +que_bingo,49,125,0 duplicate(1a#bingo) 7a#bingo 139,1,1 +que_bingo,49,125,0 duplicate(1a#bingo) 8a#bingo 139,1,1 +que_bingo,49,125,0 duplicate(1a#bingo) 9a#bingo 139,1,1 +que_bingo,49,125,0 duplicate(1a#bingo) 10a#bingo 139,1,1 +que_bingo,49,125,0 duplicate(1a#bingo) 11a#bingo 139,1,1 +que_bingo,49,125,0 duplicate(1a#bingo) 12a#bingo 139,1,1 +que_bingo,49,125,0 duplicate(1a#bingo) 13a#bingo 139,1,1 +que_bingo,49,125,0 duplicate(1a#bingo) 14a#bingo 139,1,1 +que_bingo,49,125,0 duplicate(1a#bingo) 15a#bingo 139,1,1 +que_bingo,49,125,0 duplicate(1a#bingo) 16a#bingo 139,1,1 +que_bingo,49,125,0 duplicate(1a#bingo) 17a#bingo 139,1,1 +que_bingo,49,125,0 duplicate(1a#bingo) 18a#bingo 139,1,1 +que_bingo,49,125,0 duplicate(1a#bingo) 19a#bingo 139,1,1 +que_bingo,49,125,0 duplicate(1a#bingo) 20a#bingo 139,1,1 +que_bingo,49,125,0 duplicate(1a#bingo) 21a#bingo 139,1,1 +que_bingo,49,125,0 duplicate(1a#bingo) 22a#bingo 139,1,1 +que_bingo,49,125,0 duplicate(1a#bingo) 23a#bingo 139,1,1 +que_bingo,49,125,0 duplicate(1a#bingo) 24a#bingo 139,1,1 +que_bingo,49,125,0 duplicate(1a#bingo) 25a#bingo 139,1,1 +que_bingo,53,121,0 duplicate(1a#bingo) 1b#bingo 139,1,1 +que_bingo,53,121,0 duplicate(1a#bingo) 2b#bingo 139,1,1 +que_bingo,53,121,0 duplicate(1a#bingo) 3b#bingo 139,1,1 +que_bingo,53,121,0 duplicate(1a#bingo) 4b#bingo 139,1,1 +que_bingo,53,121,0 duplicate(1a#bingo) 5b#bingo 139,1,1 +que_bingo,53,121,0 duplicate(1a#bingo) 6b#bingo 139,1,1 +que_bingo,53,121,0 duplicate(1a#bingo) 7b#bingo 139,1,1 +que_bingo,53,121,0 duplicate(1a#bingo) 8b#bingo 139,1,1 +que_bingo,53,121,0 duplicate(1a#bingo) 9b#bingo 139,1,1 +que_bingo,53,121,0 duplicate(1a#bingo) 10b#bingo 139,1,1 +que_bingo,53,121,0 duplicate(1a#bingo) 11b#bingo 139,1,1 +que_bingo,53,121,0 duplicate(1a#bingo) 12b#bingo 139,1,1 +que_bingo,53,121,0 duplicate(1a#bingo) 13b#bingo 139,1,1 +que_bingo,53,121,0 duplicate(1a#bingo) 14b#bingo 139,1,1 +que_bingo,53,121,0 duplicate(1a#bingo) 15b#bingo 139,1,1 +que_bingo,53,121,0 duplicate(1a#bingo) 16b#bingo 139,1,1 +que_bingo,53,121,0 duplicate(1a#bingo) 17b#bingo 139,1,1 +que_bingo,53,121,0 duplicate(1a#bingo) 18b#bingo 139,1,1 +que_bingo,53,121,0 duplicate(1a#bingo) 19b#bingo 139,1,1 +que_bingo,53,121,0 duplicate(1a#bingo) 20b#bingo 139,1,1 +que_bingo,53,121,0 duplicate(1a#bingo) 21b#bingo 139,1,1 +que_bingo,53,121,0 duplicate(1a#bingo) 22b#bingo 139,1,1 +que_bingo,53,121,0 duplicate(1a#bingo) 23b#bingo 139,1,1 +que_bingo,53,121,0 duplicate(1a#bingo) 24b#bingo 139,1,1 +que_bingo,53,121,0 duplicate(1a#bingo) 25b#bingo 139,1,1 +que_bingo,51,116,0 duplicate(1a#bingo) 1c#bingo 139,1,1 +que_bingo,51,116,0 duplicate(1a#bingo) 2c#bingo 139,1,1 +que_bingo,51,116,0 duplicate(1a#bingo) 3c#bingo 139,1,1 +que_bingo,51,116,0 duplicate(1a#bingo) 4c#bingo 139,1,1 +que_bingo,51,116,0 duplicate(1a#bingo) 5c#bingo 139,1,1 +que_bingo,51,116,0 duplicate(1a#bingo) 6c#bingo 139,1,1 +que_bingo,51,116,0 duplicate(1a#bingo) 7c#bingo 139,1,1 +que_bingo,51,116,0 duplicate(1a#bingo) 8c#bingo 139,1,1 +que_bingo,51,116,0 duplicate(1a#bingo) 9c#bingo 139,1,1 +que_bingo,51,116,0 duplicate(1a#bingo) 10c#bingo 139,1,1 +que_bingo,51,116,0 duplicate(1a#bingo) 11c#bingo 139,1,1 +que_bingo,51,116,0 duplicate(1a#bingo) 12c#bingo 139,1,1 +que_bingo,51,116,0 duplicate(1a#bingo) 13c#bingo 139,1,1 +que_bingo,51,116,0 duplicate(1a#bingo) 14c#bingo 139,1,1 +que_bingo,51,116,0 duplicate(1a#bingo) 15c#bingo 139,1,1 +que_bingo,51,116,0 duplicate(1a#bingo) 16c#bingo 139,1,1 +que_bingo,51,116,0 duplicate(1a#bingo) 17c#bingo 139,1,1 +que_bingo,51,116,0 duplicate(1a#bingo) 18c#bingo 139,1,1 +que_bingo,51,116,0 duplicate(1a#bingo) 19c#bingo 139,1,1 +que_bingo,51,116,0 duplicate(1a#bingo) 20c#bingo 139,1,1 +que_bingo,51,116,0 duplicate(1a#bingo) 21c#bingo 139,1,1 +que_bingo,51,116,0 duplicate(1a#bingo) 22c#bingo 139,1,1 +que_bingo,51,116,0 duplicate(1a#bingo) 23c#bingo 139,1,1 +que_bingo,51,116,0 duplicate(1a#bingo) 24c#bingo 139,1,1 +que_bingo,51,116,0 duplicate(1a#bingo) 25c#bingo 139,1,1 +que_bingo,46,116,0 duplicate(1a#bingo) 1d#bingo 139,1,1 +que_bingo,46,116,0 duplicate(1a#bingo) 2d#bingo 139,1,1 +que_bingo,46,116,0 duplicate(1a#bingo) 3d#bingo 139,1,1 +que_bingo,46,116,0 duplicate(1a#bingo) 4d#bingo 139,1,1 +que_bingo,46,116,0 duplicate(1a#bingo) 5d#bingo 139,1,1 +que_bingo,46,116,0 duplicate(1a#bingo) 6d#bingo 139,1,1 +que_bingo,46,116,0 duplicate(1a#bingo) 7d#bingo 139,1,1 +que_bingo,46,116,0 duplicate(1a#bingo) 8d#bingo 139,1,1 +que_bingo,46,116,0 duplicate(1a#bingo) 9d#bingo 139,1,1 +que_bingo,46,116,0 duplicate(1a#bingo) 10d#bingo 139,1,1 +que_bingo,46,116,0 duplicate(1a#bingo) 11d#bingo 139,1,1 +que_bingo,46,116,0 duplicate(1a#bingo) 12d#bingo 139,1,1 +que_bingo,46,116,0 duplicate(1a#bingo) 13d#bingo 139,1,1 +que_bingo,46,116,0 duplicate(1a#bingo) 14d#bingo 139,1,1 +que_bingo,46,116,0 duplicate(1a#bingo) 15d#bingo 139,1,1 +que_bingo,46,116,0 duplicate(1a#bingo) 16d#bingo 139,1,1 +que_bingo,46,116,0 duplicate(1a#bingo) 17d#bingo 139,1,1 +que_bingo,46,116,0 duplicate(1a#bingo) 18d#bingo 139,1,1 +que_bingo,46,116,0 duplicate(1a#bingo) 19d#bingo 139,1,1 +que_bingo,46,116,0 duplicate(1a#bingo) 20d#bingo 139,1,1 +que_bingo,46,116,0 duplicate(1a#bingo) 21d#bingo 139,1,1 +que_bingo,46,116,0 duplicate(1a#bingo) 22d#bingo 139,1,1 +que_bingo,46,116,0 duplicate(1a#bingo) 23d#bingo 139,1,1 +que_bingo,46,116,0 duplicate(1a#bingo) 24d#bingo 139,1,1 +que_bingo,46,116,0 duplicate(1a#bingo) 25d#bingo 139,1,1 +que_bingo,45,121,0 duplicate(1a#bingo) 1e#bingo 139,1,1 +que_bingo,45,121,0 duplicate(1a#bingo) 2e#bingo 139,1,1 +que_bingo,45,121,0 duplicate(1a#bingo) 3e#bingo 139,1,1 +que_bingo,45,121,0 duplicate(1a#bingo) 4e#bingo 139,1,1 +que_bingo,45,121,0 duplicate(1a#bingo) 5e#bingo 139,1,1 +que_bingo,45,121,0 duplicate(1a#bingo) 6e#bingo 139,1,1 +que_bingo,45,121,0 duplicate(1a#bingo) 7e#bingo 139,1,1 +que_bingo,45,121,0 duplicate(1a#bingo) 8e#bingo 139,1,1 +que_bingo,45,121,0 duplicate(1a#bingo) 9e#bingo 139,1,1 +que_bingo,45,121,0 duplicate(1a#bingo) 10e#bingo 139,1,1 +que_bingo,45,121,0 duplicate(1a#bingo) 11e#bingo 139,1,1 +que_bingo,45,121,0 duplicate(1a#bingo) 12e#bingo 139,1,1 +que_bingo,45,121,0 duplicate(1a#bingo) 13e#bingo 139,1,1 +que_bingo,45,121,0 duplicate(1a#bingo) 14e#bingo 139,1,1 +que_bingo,45,121,0 duplicate(1a#bingo) 15e#bingo 139,1,1 +que_bingo,45,121,0 duplicate(1a#bingo) 16e#bingo 139,1,1 +que_bingo,45,121,0 duplicate(1a#bingo) 17e#bingo 139,1,1 +que_bingo,45,121,0 duplicate(1a#bingo) 18e#bingo 139,1,1 +que_bingo,45,121,0 duplicate(1a#bingo) 19e#bingo 139,1,1 +que_bingo,45,121,0 duplicate(1a#bingo) 20e#bingo 139,1,1 +que_bingo,45,121,0 duplicate(1a#bingo) 21e#bingo 139,1,1 +que_bingo,45,121,0 duplicate(1a#bingo) 22e#bingo 139,1,1 +que_bingo,45,121,0 duplicate(1a#bingo) 23e#bingo 139,1,1 +que_bingo,45,121,0 duplicate(1a#bingo) 24e#bingo 139,1,1 +que_bingo,45,121,0 duplicate(1a#bingo) 25e#bingo 139,1,1 + + +que_bingo,79,19,0 script win1a#bingo 139,4,4,{ + end; + +OnWin: + initnpctimer; + end; + +OnTimer1000: + donpcevent "1a#bingo::OnInit"; + enablenpc "win2a#bingo"; + enablenpc "win2b#bingo"; + enablenpc "win2c#bingo"; + enablenpc "win2d#bingo"; + enablenpc "win2e#bingo"; + end; +} + +que_bingo,49,125,0 script win2a#bingo 139,1,1,{ + end; + +OnInit: + disablenpc "win2a#bingo"; + disablenpc "win2b#bingo"; + disablenpc "win2c#bingo"; + disablenpc "win2d#bingo"; + disablenpc "win2e#bingo"; + end; + +OnTouch: + if($@bingowinner$ != strcharinfo(0)) end; + specialeffect 183; + soundeffect "tming_success.wav",1; + if($@bingoresult == 16) getitem 7515,50; + else getitem 7515,1; + initnpctimer; + end; + +OnTimer1000: + mapannounce "que_bingo","Eukran: Wow, Bingo! It's Bingo!",1,0xFFAB54; + end; + +OnTimer5000: + mapannounce "que_bingo","Eukran: "+$@bingowinner$+" has said Bingo!",1,0xFFAB54; + end; + +OnTimer10000: + if($@bingoresult == 16) mapannounce "que_bingo","Eukran: Congratulations, "+$@bingowinner$+"! You will be rewarded with 50 Marvelous Medals.",1,0xFFAB54; + else mapannounce "que_bingo","Eukran: Congratulations, "+$@bingowinner$+"! You will be rewarded with 1 Marvelous Medal.",1,0xFFAB54; + end; + +OnTimer15000: + mapannounce "que_bingo","Eukran: Thank you all for participating in the game. See you next time!",1,0xFFAB54; + end; + +OnTimer20000: + donpcevent "end#bingo::OnEnd"; + donpcevent "win2a#bingo::OnInit"; + end; +} + +que_bingo,53,121,0 duplicate(win2a#bingo) win2b#bingo 139,1,1 +que_bingo,51,116,0 duplicate(win2a#bingo) win2c#bingo 139,1,1 +que_bingo,46,116,0 duplicate(win2a#bingo) win2d#bingo 139,1,1 +que_bingo,45,121,0 duplicate(win2a#bingo) win2e#bingo 139,1,1 + +que_bingo,89,59,0 script end#bingo 139,4,4,{ + end; + +OnEnd: + initnpctimer; + end; + +OnTimer1000: + enablenpc "end1a#bingo"; + enablenpc "end1b#bingo"; + enablenpc "end1c#bingo"; + enablenpc "end1d#bingo"; + enablenpc "end1e#bingo"; + end; + +OnTimer5000: + disablenpc "end1a#bingo"; + disablenpc "end1b#bingo"; + disablenpc "end1c#bingo"; + disablenpc "end1d#bingo"; + disablenpc "end1e#bingo"; + set $hu_bingoa,0; + donpcevent "Bingo Waiting Room::OnStart"; + end; +} + +que_bingo,49,125,0 script end1a#bingo 139,1,1,{ + +OnInit: + disablenpc "end1a#bingo"; + disablenpc "end1b#bingo"; + disablenpc "end1c#bingo"; + disablenpc "end1d#bingo"; + disablenpc "end1e#bingo"; + end; + +OnTouch: + if(strcharinfo(0) == $@bingowinner$ && hg_ma1 == 6) warp "que_bingo",45,186; + else warp "que_bingo",40,121; + end; +} + +que_bingo,53,121,0 duplicate(end1a#bingo) end1b#bingo 139,1,1 +que_bingo,51,116,0 duplicate(end1a#bingo) end1c#bingo 139,1,1 +que_bingo,46,116,0 duplicate(end1a#bingo) end1d#bingo 139,1,1 +que_bingo,45,121,0 duplicate(end1a#bingo) end1e#bingo 139,1,1 + +que_bingo,50,138,1 script out3#bingo 139,5,8,{ + +OnInit: + disablenpc "out3#bingo"; + end; + +OnTouch: + warp que_bingo,40,121; + end; +} + +que_bingo,49,136,0 script go3#bingo 45,1,1,{ + +OnTouch: + switch($hu_bingob) + { + case 0: warp "que_bingo",49,125; break; + case 1: warp "que_bingo",53,121; break; + case 2: warp "que_bingo",51,116; break; + case 3: warp "que_bingo",46,116; break; + case 4: warp "que_bingo",45,121; break; + } + set $hu_bingob,$hu_bingob +1; + if($hu_bingob == 4) set $hu_bingob,0; + end; +} + +function script Func_Bingo { + + + for( set .@i,getarg(0); .@i < 26; set .@i,.@i +1) + { + if(@bingoplate[1] < 10) set @bingo_a1$,"0"+@bingoplate[1]+""; else set @bingo_a1$,@bingoplate[1]; + if(@bingoplate[2] < 10) set @bingo_a2$,"0"+@bingoplate[2]+""; else set @bingo_a2$,@bingoplate[2]; + if(@bingoplate[3] < 10) set @bingo_a3$,"0"+@bingoplate[3]+""; else set @bingo_a3$,@bingoplate[3]; + if(@bingoplate[4] < 10) set @bingo_a4$,"0"+@bingoplate[4]+""; else set @bingo_a4$,@bingoplate[4]; + if(@bingoplate[5] < 10) set @bingo_a5$,"0"+@bingoplate[5]+""; else set @bingo_a5$,@bingoplate[5]; + if(.@i > 5) mes "["+@bingo_a1$+"] ["+@bingo_a2$+"] ["+@bingo_a3$+"] ["+@bingo_a4$+"] ["+@bingo_a5$+"]"; + else + { + switch(.@i) + { + case 1: mes "^ff0000[__]^000000 [ ] [ ] [ ] [ ]"; break; + case 2: mes "["+@bingo_a1$+"] ^ff0000[__]^000000 [ ] [ ] [ ]"; break; + case 3: mes "["+@bingo_a1$+"] ["+@bingo_a2$+"] ^ff0000[__]^000000 [ ] [ ]"; break; + case 4: mes "["+@bingo_a1$+"] ["+@bingo_a2$+"] ["+@bingo_a3$+"] ^ff0000[__]^000000 [ ]"; break; + case 5: mes "["+@bingo_a1$+"] ["+@bingo_a2$+"] ["+@bingo_a3$+"] ["+@bingo_a4$+"] ^ff0000[__]^000000"; break; + } + } + if(@bingoplate[6] < 10) set @bingo_b1$,"0"+@bingoplate[6]+""; else set @bingo_b1$,@bingoplate[6]; + if(@bingoplate[7] < 10) set @bingo_b2$,"0"+@bingoplate[7]+""; else set @bingo_b2$,@bingoplate[7]; + if(@bingoplate[8] < 10) set @bingo_b3$,"0"+@bingoplate[8]+""; else set @bingo_b3$,@bingoplate[8]; + if(@bingoplate[9] < 10) set @bingo_b4$,"0"+@bingoplate[9]+""; else set @bingo_b4$,@bingoplate[9]; + if(@bingoplate[10] < 10) set @bingo_b5$,"0"+@bingoplate[10]+""; else set @bingo_b5$,@bingoplate[10]; + if(.@i > 10) mes "["+@bingo_b1$+"] ["+@bingo_b2$+"] ["+@bingo_b3$+"] ["+@bingo_b4$+"] ["+@bingo_b5$+"]"; + else if(.@i < 6) mes "[ ] [ ] [ ] [ ] [ ]"; + else + { + switch(.@i) + { + case 6: mes "^ff0000[__]^000000 [ ] [ ] [ ] [ ]"; break; + case 7: mes "["+@bingo_b1$+"] ^ff0000[__]^000000 [ ] [ ] [ ]"; break; + case 8: mes "["+@bingo_b1$+"] ["+@bingo_b2$+"] ^ff0000[__]^000000 [ ] [ ]"; break; + case 9: mes "["+@bingo_b1$+"] ["+@bingo_b2$+"] ["+@bingo_b3$+"] ^ff0000[__]^000000 [ ]"; break; + case 10: mes "["+@bingo_b1$+"] ["+@bingo_b2$+"] ["+@bingo_b3$+"] ["+@bingo_b4$+"] ^ff0000[__]^000000"; break; + } + } + if(@bingoplate[11] < 10) set @bingo_c1$,"0"+@bingoplate[11]+""; else set @bingo_c1$,@bingoplate[11]; + if(@bingoplate[12] < 10) set @bingo_c2$,"0"+@bingoplate[12]+""; else set @bingo_c2$,@bingoplate[12]; + if(@bingoplate[13] < 10) set @bingo_c3$,"0"+@bingoplate[13]+""; else set @bingo_c3$,@bingoplate[13]; + if(@bingoplate[14] < 10) set @bingo_c4$,"0"+@bingoplate[14]+""; else set @bingo_c4$,@bingoplate[14]; + if(@bingoplate[15] < 10) set @bingo_c5$,"0"+@bingoplate[15]+""; else set @bingo_c5$,@bingoplate[15]; + if(.@i > 15) mes "["+@bingo_c1$+"] ["+@bingo_c2$+"] ["+@bingo_c3$+"] ["+@bingo_c4$+"] ["+@bingo_c5$+"]"; + else if(.@i < 11) mes "[ ] [ ] [ ] [ ] [ ]"; + else + { + switch(.@i) + { + case 11: mes "^ff0000[__]^000000 [ ] [ ] [ ] [ ]"; break; + case 12: mes "["+@bingo_c1$+"] ^ff0000[__]^000000 [ ] [ ] [ ]"; break; + case 13: mes "["+@bingo_c1$+"] ["+@bingo_c2$+"] ^ff0000[__]^000000 [ ] [ ]"; break; + case 14: mes "["+@bingo_c1$+"] ["+@bingo_c2$+"] ["+@bingo_c3$+"] ^ff0000[__]^000000 [ ]"; break; + case 15: mes "["+@bingo_c1$+"] ["+@bingo_c2$+"] ["+@bingo_c3$+"] ["+@bingo_c4$+"] ^ff0000[__]^000000"; break; + } + } + if(@bingoplate[16] < 10) set @bingo_d1$,"0"+@bingoplate[16]+""; else set @bingo_d1$,@bingoplate[16]; + if(@bingoplate[17] < 10) set @bingo_d2$,"0"+@bingoplate[17]+""; else set @bingo_d2$,@bingoplate[17]; + if(@bingoplate[18] < 10) set @bingo_d3$,"0"+@bingoplate[18]+""; else set @bingo_d3$,@bingoplate[18]; + if(@bingoplate[19] < 10) set @bingo_d4$,"0"+@bingoplate[19]+""; else set @bingo_d4$,@bingoplate[19]; + if(@bingoplate[20] < 10) set @bingo_d5$,"0"+@bingoplate[20]+""; else set @bingo_d5$,@bingoplate[20]; + if(.@i > 20) mes "["+@bingo_d1$+"] ["+@bingo_d2$+"] ["+@bingo_d3$+"] ["+@bingo_d4$+"] ["+@bingo_d5$+"]"; + else if(.@i < 16) mes "[ ] [ ] [ ] [ ] [ ]"; + else + { + switch(.@i) + { + case 16: mes "^ff0000[__]^000000 [ ] [ ] [ ] [ ]"; break; + case 17: mes "["+@bingo_d1$+"] ^ff0000[__]^000000 [ ] [ ] [ ]"; break; + case 18: mes "["+@bingo_d1$+"] ["+@bingo_d2$+"] ^ff0000[__]^000000 [ ] [ ]"; break; + case 19: mes "["+@bingo_d1$+"] ["+@bingo_d2$+"] ["+@bingo_d3$+"] ^ff0000[__]^000000 [ ]"; break; + case 20: mes "["+@bingo_d1$+"] ["+@bingo_d2$+"] ["+@bingo_d3$+"] ["+@bingo_d4$+"] ^ff0000[__]^000000"; break; + } + } + if(@bingoplate[21] < 10) set @bingo_e1$,"0"+@bingoplate[21]+""; else set @bingo_e1$,@bingoplate[21]; + if(@bingoplate[22] < 10) set @bingo_e2$,"0"+@bingoplate[22]+""; else set @bingo_e2$,@bingoplate[22]; + if(@bingoplate[23] < 10) set @bingo_e3$,"0"+@bingoplate[23]+""; else set @bingo_e3$,@bingoplate[23]; + if(@bingoplate[24] < 10) set @bingo_e4$,"0"+@bingoplate[24]+""; else set @bingo_e4$,@bingoplate[24]; + if(.@i < 21) mes "[ ] [ ] [ ] [ ] [ ]"; + else + { + switch(.@i) + { + case 21: mes "^ff0000[__]^000000 [ ] [ ] [ ] [ ]"; break; + case 22: mes "["+@bingo_e1$+"] ^ff0000[__]^000000 [ ] [ ] [ ]"; break; + case 23: mes "["+@bingo_e1$+"] ["+@bingo_e2$+"] ^ff0000[__]^000000 [ ] [ ]"; break; + case 24: mes "["+@bingo_e1$+"] ["+@bingo_e2$+"] ["+@bingo_e3$+"] ^ff0000[__]^000000 [ ]"; break; + case 25: mes "["+@bingo_e1$+"] ["+@bingo_e2$+"] ["+@bingo_e3$+"] ["+@bingo_e4$+"] ^ff0000[__]^000000"; break; + } + } + next; + input .@bingoinput; + if(.@bingoinput < 1 || .@bingoinput > 25) { set @bingo_case,.@i; return 0; } + if(.@i > 1) + { + for(set .@j,.@i; .@j > 0; set .@j,.@j -1) + { + if(.@bingoinput == @bingoplate[.@j -1]) { set @bingo_case,.@i; return 0; } + } + } + setarray @bingoplate[.@i],.@bingoinput; + } + return 1; +} + +function script Func_BingoResult { + + if(getarg(0) == 1 || getarg(0) == 21) mapannounce "que_bingo","Eukran: The "+getarg(0)+"st number is "+$bingo[getarg(0) -1]+". Please check your Bingo Plate.",4,0xFFAB54; + else if(getarg(0) == 2 || getarg(0) == 22) mapannounce "que_bingo","Eukran: The "+getarg(0)+"nd number is "+$bingo[getarg(0) -1]+". Please check your Bingo Plate.",4,0xFFAB54; + else if(getarg(0) == 3 || getarg(0) == 23) mapannounce "que_bingo","Eukran: The "+getarg(0)+"rd number is "+$bingo[getarg(0) -1]+". Please check your Bingo Plate.",4,0xFFAB54; + else mapannounce "que_bingo","Eukran: The "+getarg(0)+"th number is "+$bingo[getarg(0) -1]+". Please check your Bingo Plate.",4,0xFFAB54; + enablenpc ""+getarg(0)+"a#bingo"; + enablenpc ""+getarg(0)+"b#bingo"; + enablenpc ""+getarg(0)+"c#bingo"; + enablenpc ""+getarg(0)+"d#bingo"; + enablenpc ""+getarg(0)+"e#bingo"; + set getarg(0),getarg(0) +1; + end; +}
\ No newline at end of file |