;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
[@Ma21]
{
#ACT
breaktimerecall
#SAY
Welcome to the Friendship room.  You cannoy leave this room\
until there are 2 people in here.\
<[ I give up - Send me back to the Town :( ]/@SendtoLobby>\
<[ 2 People here! ]/@Ma21_game>\

[@Ma21_game]
#IF
checkhum D1701_021 2
#ACT
goto @Ma21_pre_cube
#ELSESAY
Sorry, still not enough people\\
<[ I give up - Send me back to the Town :( ]/@SendtoLobby>\
<[ Exit ]/@exit>\

[@SendtoLobby]
#ACT
Map 10_000
break

[@Ma21_pre_cube]
#IF
checkitem GambleChip 1
#ACT
take GambleChip 1
movr d0 6
inc d0 1
playdice 1 @Ma21_cube
#SAY
Rolls the dice...\\ 
#ELSEACT
Map 10_000

[@Ma21_cube]
#IF
equal d0 1 
#ACT
mapmove D1701_022 10 16
break

#IF
equal d0 2 
#ACT
mapmove D1701_023 10 16
break

#IF
equal d0 3 
#ACT
mapmove D1701_024 10 16
break

#IF
equal d0 4 
#ACT
mapmove D1701_025 10 16
break

#IF
equal d0 5
#ACT
mapmove D1701_026 10 16
break

#IF
equal d0 6 
#ACT
mapmove D1701_027 10 16
break
}

[@Ma22]
{
#IF
#ACT  
breaktimerecall
#SAY
Welcome to the Room of the Wind,\
Roll a 4 or above and move forward 8 Rooms!\
Roll less and move forward that number of rooms\
<[ Shake the dice ]/@Ma22_race>\

[@Ma22_race]
#IF
checkitem GambleChip 1
#ACT
take GambleChip 1
movr d0 6
inc d0 1
playdice 1 @Ma22_cube
#SAY
Rolls the dice...\\ 
#ELSEACT
Map 10_000

[@Ma22_cube]
#IF
large d0 3
#ACT
mapmove D1701_030 10 16
#ELSEACT
goto @Ma22_move

[@Ma22_move]
#IF
equal d0 1
#ACT
mapmove D1701_023 10 16
break                                                                
#IF
equal d0 2
#ACT
mapmove D1701_024 10 16
break                                                                
#IF
equal d0 3
#ACT
mapmove D1701_025 10 16
break
}

[@Ma23]
{
#IF
#ACT
breaktimerecall
#SAY
Welcome to the Room or Patience.\
Roll 2 Die, subtract the first number from\
the 2nd, if that equals 2 then you can move forwards\
You have 3 attempts per GambleChip\\
<[ Lets have a go ]/@Ma23_game>\

[@Ma23_game]
#IF
checkitem GambleChip 1
#SAY
You have paid the chip, you have 3 tries\ \
<[ Roll 'em... ]/@Ma23_dicestart>\
#ACT
take GambleChip 1
mov n1 0
#ELSEACT
Map 10_000

[@Ma23_dicestart]
#IF
small n1 3
#ACT
movr d0 6
inc d0 1
movr d1 6
inc d1 1
inc n1 1
playdice 2 @Ma23_result
#SAY
Rolls the dice...\\ 
#ELSEACT
goto @Ma23_game

[@Ma23_result]
#ACT
dec d1 %d0

#IF
equal d1 2
#ACT
goto @Ma23_pre_cube
#ELSEACT
goto @Ma23_dicestart

[@Ma23_pre_cube]
#IF
checkitem GambleChip 1
#ACT
take GambleChip 1
movr d0 6
inc d0 1
playdice 1 @Ma23_cube
#SAY
Woo Hoo.. 2... \
Rolls the dice...\\ 
#ELSEACT
Map 10_000

[@Ma23_cube]
#IF
equal d0 1 
#ACT
mapmove D1701_024 10 16
break

#IF
equal d0 2 
#ACT
mapmove D1701_025 10 16
break

#IF
equal d0 3 
#ACT
mapmove D1701_026 10 16
break

#IF
equal d0 4 
#ACT
mapmove D1701_027 10 16
break

#IF
equal d0 5
#ACT
mapmove D1701_028 10 16
break

#IF
equal d0 6 
#ACT
mapmove D1701_029 10 16
break
}

[@Ma24]
{
#IF
#ACT
movr d0 3
breaktimerecall
#SAY
Welcome to the room of confusion.  This room will exchange you with\
anyone in another selected room\
<[ Lets do it ]/@Ma24_exchange>\

[@Ma24_exchange]
#IF
checkitem GambleChip 1
equal d0 0
#ACT
take GambleChip 1
ExchangeMap D1701_002
break

#IF
checkitem GambleChip 1
equal d0 1
#ACT
take GambleChip 1
ExchangeMap D1701_015
break

#IF
checkitem GambleChip 1
equal d0 2
#ACT
take GambleChip 1
ExchangeMap D1701_026
break

#ELSEACT
Map 10_000
}

[@Ma25]
{
#IF
#ACT
breaktimerecall
#SAY
Here you can replenish you potions, we will give you \
2 Ginseng for each GambleChip\
<[ Buy some Ginseng ]/@Ma25_buyB>\
<[ Shake the dice ]/@Ma25_pre_cube>


[@Ma25_buyB]
#IF
checkitem GambleChip 1
#ACT
take GambleChip 1
give Ginseng 2
#SAY
There you go... \
<[ Exit ]/@exit>\
#ELSESAY
You do not have any chips!\
<[ Exit ]/@exit>\

[@Ma25_pre_cube]
#IF
checkitem GambleChip 1
#ACT
take GambleChip 1
movr d0 6
inc d0 1
playdice 1 @Ma25_cube
#SAY
Rolls the dice...\\ 
#ELSEACT
Map 10_000

[@Ma25_cube]
#IF
equal d0 1 
#ACT
mapmove D1701_026 10 16
break

#IF
equal d0 2 
#ACT
mapmove D1701_027 10 16
break

#IF
equal d0 3 
#ACT
mapmove D1701_028 10 16
break

#IF
equal d0 4 
#ACT
mapmove D1701_029 10 16
break

#IF
equal d0 5
#ACT
mapmove D1701_030 10 16
break

#IF
equal d0 6 
#ACT
mapmove D1701_031 10 16
break
}

[@Ma26]
{
#IF
#ACT
breaktimerecall
#SAY
Welcome to the 16th Room Migration Trap.. sorry..\
<[ Migrate ]/@Ma26_move>\\\

[@Ma26_move]
#IF
checkitem GambleChip 1
#ACT
take GambleChip 1
mapmove D1701_016 10 16
#ELSEACT
Map 10_000
}

[@Ma27]
{
#IF
#ACT
breaktimerecall
movr d0 8
#SAY
Welcome to the Lucky Room,\
Here we have a random effect once you\
decide to continue.. Give, Take, Move, who knows\\
<[ Lets see what happens [/@Ma27_game>\

[@Ma27_game]
#IF
equal d0 0
#ACT
goto @Ma27_race
take GambleChip 6
break

#IF
equal d0 1
#ACT
goto @Ma27_race
give GambleChip 6
break

#IF
equal d0 2
#ACT
mapmove D1701_023 10 16
break

#IF
equal d0 3
#ACT
mapmove D1701_031 10 16
break

#IF
equal d0 4
#ACT
goto @Ma27_race
break

#IF
equal d0 5
#ACT
take Gold 40000
goto @Ma27_race
break

#IF
equal d0 6
#ACT
take Ginseng 20
goto @Ma27_race
break

#IF
equal d0 7
#ACT
give Ginseng  20
goto @Ma27_race
break

[@Ma27_race]
#IF
checkitem GambleChip 1
#ACT
take GambleChip 1
movr d0 6
inc d0 1
playdice 1 @Ma27_cube
#SAY
Rolls the dice...\\ 
#ELSEACT
Map 10_000

[@Ma27_cube]
#IF
equal d0 1 
#ACT
mapmove D1701_028 10 16
break

#IF
equal d0 2 
#ACT
mapmove D1701_029 10 16
break

#IF
equal d0 3 
#ACT
mapmove D1701_030 10 16
break

#IF
equal d0 4 
#ACT
mapmove D1701_031 10 16
break

#IF
equal d0 5
#ACT
mapmove D1701_032 10 16
break

#IF
equal d0 6 
#ACT
mapmove D1701_033 10 16
break
}

[@Ma28]
{
#IF
#ACT
breaktimerecall
#SAY
Welcome to the Gamble Trap, you cannot win!\
Say goodbye to some of those Chips\
<[ OK.. oh well ]/@Ma28_game>\
#ELSEACT
Map 10_000

[@Ma28_game]
#IF
#ACT
take GambleChip 12
goto @Ma28_race

[@Ma28_race]
#IF
checkitem GambleChip 1
#ACT
take GambleChip 1
movr d0 6
inc d0 1
playdice 1 @cube
#SAY
Rolls the dice...\\ 
#ELSEACT
Map 10_000

[@cube]
#IF
equal d0 1 
#ACT
mapmove D1701_029 10 16
break

#IF
equal d0 2 
#ACT
mapmove D1701_030 10 16
break

#IF
equal d0 3 
#ACT
mapmove D1701_031 10 16
break

#IF
equal d0 4 
#ACT
mapmove D1701_032 10 16
break

#IF
equal d0 5
#ACT
mapmove D1701_033 10 16
break

#IF
equal d0 6 
#ACT
mapmove D1701_034 10 16
break
}

[@Ma29]
{
#IF
#ACT
breaktimerecall
#SAY
Welcome to the Room of Patience. Roll a pair to continue\
You get 3 chances per GambleChip\\
<[ Thats easy! ]/@Ma29_game>\

#ELSEACT
Map 10_000

[@Ma29_game]
#IF
checkitem GambleChip 1
#SAY
Thanks for the Chip.. you now have 3 attempts\
<[ Roll Em! ]/@Ma29_dicestart>\

#ACT
take GambleChip 1
mov n1 0
#ELSEACT
Map 10_000

[@Ma29_dicestart]
#IF
small n1 3
#ACT
inc n1 1
movr d0 6
inc d0 1
movr d1 6
inc d1 1
playdice 2 @Ma29_result
#SAY
Rolls the dice...\\ 
#ELSEACT
goto @Ma29_game

[@Ma29_result]
#IF
equal d0 %d1
#ACT
goto @Ma29_race
#ELSEACT
goto @Ma29_dicestart

[@Ma29_race]
#IF
checkitem GambleChip 1
#ACT
take GambleChip 1
movr d0 6
inc d0 1
playdice 1 @Ma29_cube
#SAY
Rolls the dice...\\ 
#ELSEACT
Map 10_000

[@Ma29_cube]
#IF
equal d0 1 
#ACT
mapmove D1701_030 10 16
break

#IF
equal d0 2 
#ACT
mapmove D1701_031 10 16
break

#IF
equal d0 3 
#ACT
mapmove D1701_032 10 16
break

#IF
equal d0 4 
#ACT
mapmove D1701_033 10 16
break

#IF
equal d0 5
#ACT
mapmove D1701_034 10 16
break

#IF
equal d0 6 
#ACT
mapmove D1701_035 10 16
break
}

[@Ma30]
{
#ACT
movr d0 4
breaktimerecall
#SAY
Welcome to the Transport Room, Just see what happens\
<[ Here we go... ]/@Ma30_game>


[@Ma30_game]
#IF
equal d0 0
#ACT
give GambleChip 3
mapmove D1701_029 10 16
break

#IF
equal d0 1
#ACT
take GambleChip 6
mapmove D1701_028 10 16
break

#IF
equal d0 2
#ACT
take GambleChip 6
mapmove D1701_031 10 16
break

#IF
equal d0 3
#ACT
give GambleChip 6
mapmove D1701_032 10 16
break
}
;;;;;;;;;;;;;;;;;;;;;;;;;;;