diff options
Diffstat (limited to 'world/map/npc/001-2/casino.txt')
-rw-r--r-- | world/map/npc/001-2/casino.txt | 272 |
1 files changed, 134 insertions, 138 deletions
diff --git a/world/map/npc/001-2/casino.txt b/world/map/npc/001-2/casino.txt index b4cb7bb0..9dcbf5c5 100644 --- a/world/map/npc/001-2/casino.txt +++ b/world/map/npc/001-2/casino.txt @@ -1,181 +1,177 @@ // -001-2.gat,134,23,0 script Valdo 117,{ - mes "[Valdo the Worker]"; - mes "\"Please let me work, I'm really in a hurry!\""; - close; +001-2.gat,134,23,0|script|Valdo|117,{ + mes "[Valdo the Worker]"; + mes "\"Please let me work, I'm really in a hurry!\""; + close; } -001-2.gat,37,65,0 script Slot1 127,{ - callfunc "SlotMachine"; - close; +001-2.gat,37,65,0|script|Slot1|127,{ + callfunc "SlotMachine"; + close; } -001-2.gat,39,65,0 script Slot2 127,{ - callfunc "SlotMachine"; - close; +001-2.gat,39,65,0|script|Slot2|127,{ + callfunc "SlotMachine"; + close; } -001-2.gat,41,65,0 script Slot3 127,{ - callfunc "SlotMachine"; - close; +001-2.gat,41,65,0|script|Slot3|127,{ + callfunc "SlotMachine"; + close; } -001-2.gat,32,67,0 script MoneyChanger 124,{ - mes "[" + @npcname$ + "]"; - mes "\"I used to exchange Casino Coins for cash, but the Wizard's Council shut me down. Now the casino only runs off Casino Coins currently in circulation.\""; - next; - mes "\"I heard that many a gambler wandered onto the Beach to the South West and through to the Snake Desert to the South East. If you want to find coins already in circulation, you might find some on the monsters there.\""; - close; +001-2.gat,32,67,0|script|MoneyChanger|124,{ + mes "[" + @npcname$ + "]"; + mes "\"I used to exchange Casino Coins for cash, but the Wizard's Council shut me down. Now the casino only runs off Casino Coins currently in circulation.\""; + next; + mes "\"I heard that many a gambler wandered onto the Beach to the South West and through to the Snake Desert to the South East. If you want to find coins already in circulation, you might find some on the monsters there.\""; + close; } -001-2.gat,28,63,0 script BlackJack 107,{ - mes "[Croupier]"; - mes "\"Would you like to play Black Jack?"; - mes "You will need 15 casino coins.\""; - next; - - menu - "Yes", L_Begin, - "No", -; - mes "\"As you wish.\""; - close; +001-2.gat,28,63,0|script|BlackJack|107,{ + mes "[Croupier]"; + mes "\"Would you like to play Black Jack?"; + mes "You will need 15 casino coins.\""; + next; + menu + "Yes", L_Begin, + "No", -; + mes "\"As you wish.\""; + close; L_Begin: - if(countitem("CasinoCoins") < 15) goto L_NoCoin; - delitem "CasinoCoins", 15; - set @croupier, rand(0, 4); - set @croupier, @croupier + 17; - set @player, rand(4, 21); - mes "\"You got " + @player + " with your cards."; - if(@player == 21) goto L_End; - mes "Do you want another card?\""; - next; - - menu - "Yes", L_Another, - "No", L_End; - + if(countitem("CasinoCoins") < 15) goto L_NoCoin; + delitem "CasinoCoins", 15; + set @croupier, rand(0, 4); + set @croupier, @croupier + 17; + set @player, rand(4, 21); + mes "\"You got " + @player + " with your cards."; + if(@player == 21) goto L_End; + mes "Do you want another card?\""; + next; + menu + "Yes", L_Another, + "No", L_End; + L_Another: - set @tempace, rand(2, 11); - if (@tempace == 11) goto L_Ace; - set @player, @player + @tempace; - if (@player > 21) goto L_Lost; - if (@player == 21) goto L_End; - mes "\"You got " + @player + " with your cards."; - mes "Do you want another card?\""; - next; - - menu - "Yes", L_Another, - "No", L_End; + set @tempace, rand(2, 11); + if (@tempace == 11) goto L_Ace; + set @player, @player + @tempace; + if (@player > 21) goto L_Lost; + if (@player == 21) goto L_End; + mes "\"You got " + @player + " with your cards."; + mes "Do you want another card?\""; + next; + menu + "Yes", L_Another, + "No", L_End; + L_End: - if (@player <= @croupier) goto L_Lost; - mes "\"Congratulations, you won!"; - mes "I had " + @croupier + "."; - mes "You get 45 casino coins.\""; - getitem "CasinoCoins", 45; - close; + if (@player <= @croupier) goto L_Lost; + mes "\"Congratulations, you won!"; + mes "I had " + @croupier + "."; + mes "You get 45 casino coins.\""; + getitem "CasinoCoins", 45; + close; L_NoCoin: - mes "\"You need at least 15 coins.\""; - close; + mes "\"You need at least 15 coins.\""; + close; L_Lost: - mes "\"I'm sorry but you lost."; - mes "You got " + @player + " with your cards."; - mes "I had " + @croupier + ".\""; - close; + mes "\"I'm sorry but you lost."; + mes "You got " + @player + " with your cards."; + mes "I had " + @croupier + ".\""; + close; L_Ace: - set @player, @player + 11; - if (@player > 21) set @player, @player - 10; - if (@player > 21) goto L_Lost; - if (@player == 21) goto L_End; - mes "You got " + @player + " with your cards."; - mes "Do you want another card?"; - next; - - menu - "Yes", L_Another, - "No", L_End; - close; + set @player, @player + 11; + if (@player > 21) set @player, @player - 10; + if (@player > 21) goto L_Lost; + if (@player == 21) goto L_End; + mes "You got " + @player + " with your cards."; + mes "Do you want another card?"; + next; + menu + "Yes", L_Another, + "No", L_End; + close; } -001-2.gat,22,69,0 script Roulette 107,{ - mes "\"Good evening monsieur..."; - mes "How much would you like to bet?\""; - next; - - menu - "1 coin", L_b1, - "5 coins", L_b5, - "10 coins", L_b10, - "50 coins", L_b50, - "100 coins", L_b100, - "Maybe I'll play later", -; - mes "Come again."; - close; +001-2.gat,22,69,0|script|Roulette|107,{ + mes "\"Good evening monsieur..."; + mes "How much would you like to bet?\""; + next; + menu + "1 coin", L_b1, + "5 coins", L_b5, + "10 coins", L_b10, + "50 coins", L_b50, + "100 coins", L_b100, + "Maybe I'll play later", -; + mes "Come again."; + close; L_b1: - set @bet, 1; - goto L_Check; + set @bet, 1; + goto L_Check; L_b5: - set @bet, 5; - goto L_Check; + set @bet, 5; + goto L_Check; L_b10: - set @bet, 10; - goto L_Check; + set @bet, 10; + goto L_Check; L_b50: - set @bet, 50; - goto L_Check; + set @bet, 50; + goto L_Check; L_b100: - set @bet, 100; - goto L_Check; - + set @bet, 100; + goto L_Check; + L_Check: - if(countitem("CasinoCoins") < @bet) goto L_NoCoin; - delitem "CasinoCoins", @bet; - menu - "Choose a color", -, - "Choose a number", L_Number; - menu - "Black", -, - "Red", -; + if(countitem("CasinoCoins") < @bet) goto L_NoCoin; + delitem "CasinoCoins", @bet; + menu + "Choose a color", -, + "Choose a number", L_Number; + menu + "Black", -, + "Red", -; set @color,rand(2); - if(@color == 1) goto L_Lost; - mes "You won!"; - getitem "CasinoCoins", @bet * 2; - close; + if(@color == 1) goto L_Lost; + mes "You won!"; + getitem "CasinoCoins", @bet * 2; + close; L_Number: - menu - "0", -, "00", -, "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", -, "26", -, "27", -, "28", -, - "29", -, "30", -, "31", -, "32", -, "33", -, "34", -, "35", -, "36", -; - - if (@menu == 1) set @number, 0; - if (@menu == 2) set @number, 37; - if (@menu >= 3) set @number, @menu - 2; - - set @roulette, rand(38); - if (@roulette == 37) mes "The ball stopped on 00"; - if (@roulette < 37) mes "The ball stopped on " + @roulette; - if (@number != @roulette) goto L_Lost; - mes "\"You won!\""; - getitem "CasinoCoins", @bet * 10; - close; + menu + "0", -, "00", -, "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", -, "26", -, "27", -, "28", -, + "29", -, "30", -, "31", -, "32", -, "33", -, "34", -, "35", -, "36", -; + + if (@menu == 1) set @number, 0; + if (@menu == 2) set @number, 37; + if (@menu >= 3) set @number, @menu - 2; + + set @roulette, rand(38); + if (@roulette == 37) mes "The ball stopped on 00"; + if (@roulette < 37) mes "The ball stopped on " + @roulette; + if (@number != @roulette) goto L_Lost; + mes "\"You won!\""; + getitem "CasinoCoins", @bet * 10; + close; L_NoCoin: - mes "\"You don't have enough coins.\""; - close; + mes "\"You don't have enough coins.\""; + close; L_Lost: - mes "\"I'm sorry, you lost.\""; - close; + mes "\"I'm sorry, you lost.\""; + close; } |