REM PLAY Level 138

SET_GENERATE_SPEED(500)
MAX_CREATURES(PLAYER0,10)
START_MONEY(PLAYER0,15000)

ADD_CREATURE_TO_POOL(SORCEROR,20)
ADD_CREATURE_TO_POOL(BILE_DEMON,15)
ADD_CREATURE_TO_POOL(DARK_MISTRESS,20)
ADD_CREATURE_TO_POOL(Dragon,10)


CREATURE_AVAILABLE(ALL_PLAYERS,SORCEROR,1,1)
CREATURE_AVAILABLE(ALL_PLAYERS,BILE_DEMON,1,1)
CREATURE_AVAILABLE(ALL_PLAYERS,DARK_MISTRESS,1,1)
CREATURE_AVAILABLE(ALL_PLAYERS,ORC,1,1)

ROOM_AVAILABLE(ALL_PLAYERS,TREASURE,1,1)
ROOM_AVAILABLE(ALL_PLAYERS,LAIR,1,1)
ROOM_AVAILABLE(ALL_PLAYERS,GARDEN,1,1)
ROOM_AVAILABLE(ALL_PLAYERS,TRAINING,1,1)
ROOM_AVAILABLE(ALL_PLAYERS,RESEARCH,1,1)
ROOM_AVAILABLE(ALL_PLAYERS,GUARD_POST,1,0)
ROOM_AVAILABLE(ALL_PLAYERS,TORTURE,1,0)
ROOM_AVAILABLE(ALL_PLAYERS,TEMPLE,0,0)

MAGIC_AVAILABLE(ALL_PLAYERS,POWER_HAND,1,1)
MAGIC_AVAILABLE(ALL_PLAYERS,POWER_IMP,1,1)
MAGIC_AVAILABLE(ALL_PLAYERS,POWER_SLAP,1,1)

MAGIC_AVAILABLE(ALL_PLAYERS,POWER_OBEY,1,0)
MAGIC_AVAILABLE(ALL_PLAYERS,POWER_CALL_TO_ARMS,1,0)
MAGIC_AVAILABLE(ALL_PLAYERS,POWER_HEAL_CREATURE,0,0)
MAGIC_AVAILABLE(ALL_PLAYERS,POWER_SPEED,1,0)
MAGIC_AVAILABLE(ALL_PLAYERS,POWER_PROTECT,0,0)
MAGIC_AVAILABLE(ALL_PLAYERS,POWER_CONCEAL,0,0)
MAGIC_AVAILABLE(ALL_PLAYERS,POWER_CAVE_IN,1,0)
MAGIC_AVAILABLE(ALL_PLAYERS,POWER_CHICKEN,1,0)
MAGIC_AVAILABLE(ALL_PLAYERS,POWER_lightning,0,)

CREATE_PARTY(PARTY1)
   ADD_to_PARTY(PARTY1,ARCHER,4,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY1,ARCHER,4,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY1,ARCHER,4,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY1,WIZARD,4,100,ATTACK_ENEMIES,0)

IF_ACTION_POINT(1, PLAYER0)
   ADD_PARTY_TO_LEVEL(PLAYER_GOOD,PARTY1,1,1)
ENDIF

CREATE_PARTY(PARTY2)
   ADD_to_PARTY(PARTY2,ARCHER,4,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY2,ARCHER,4,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY2,GIANT,4,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY2,WIZARD,4,100,ATTACK_ENEMIES,0)

IF_ACTION_POINT(2, PLAYER0)
   ADD_PARTY_TO_LEVEL(PLAYER_GOOD,PARTY2,2,1)
ENDIF

CREATE_PARTY(PARTY3)
   ADD_to_PARTY(PARTY3,ARCHER,4,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY3,ARCHER,4,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY3,ARCHER,4,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY3,WIZARD,4,100,ATTACK_ENEMIES,0)

IF_ACTION_POINT(3, PLAYER0)
   ADD_PARTY_TO_LEVEL(PLAYER_GOOD,PARTY3,3,1)
ENDIF

CREATE_PARTY(PARTY4)
   ADD_to_PARTY(PARTY4,ARCHER,4,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY4,Giant,6,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY4,Witch,6,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY4,WIZARD,4,100,ATTACK_ENEMIES,0)

IF_ACTION_POINT(4, PLAYER0)
   ADD_PARTY_TO_LEVEL(PLAYER_GOOD,PARTY4,4,1)
ENDIF

CREATE_PARTY(PARTY5)
   ADD_to_PARTY(PARTY5,ARCHER,4,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY5,ARCHER,4,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY5,Giant,7,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY5,WIZARD,6,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY5,WIZARD,7,100,ATTACK_ENEMIES,0)
IF_ACTION_POINT(5, PLAYER0)
   ADD_PARTY_TO_LEVEL(PLAYER_GOOD,PARTY5,5,1)
ENDIF
CREATE_PARTY(PARTY6)
   ADD_to_PARTY(PARTY6,ARCHER,5,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY6,ARCHER,5,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY6,Giant,8,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY6,WIZARD,7,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY6,Witch,8,100,ATTACK_ENEMIES,0)
IF_ACTION_POINT(6, PLAYER0)
   ADD_PARTY_TO_LEVEL(PLAYER_GOOD,PARTY6,6,1)
ENDIF

CREATE_PARTY(PARTY7)
   ADD_to_PARTY(PARTY7,ARCHER,5,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY7,Monk,6,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY7,Giant,8,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY7,WIZARD,7,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY7,Witch,8,100,ATTACK_ENEMIES,0)
IF_ACTION_POINT(7, PLAYER0)
   ADD_PARTY_TO_LEVEL(PLAYER_GOOD,PARTY7,7,1)
ENDIF

CREATE_PARTY(PARTY8)
   ADD_to_PARTY(PARTY8,ARCHER,5,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY8,Barbarian,5,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY8,Giant,8,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY8,WIZARD,7,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY8,Witch,8,100,ATTACK_ENEMIES,0)
IF_ACTION_POINT(8, PLAYER0)
   ADD_PARTY_TO_LEVEL(PLAYER_GOOD,PARTY8,8,1)
ENDIF

CREATE_PARTY(PARTY9)
   ADD_to_PARTY(PARTY9,ARCHER,5,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY9,Monk,7,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY9,Giant,8,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY9,WIZARD,7,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY9,Witch,8,100,ATTACK_ENEMIES,0)
IF_ACTION_POINT(9, PLAYER0)
   ADD_PARTY_TO_LEVEL(PLAYER_GOOD,PARTY9,9,1)
ENDIF

CREATE_PARTY(PARTY10)
   ADD_to_PARTY(PARTY10,ARCHER,5,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY10,Fairy,8,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY10,Giant,8,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY10,WIZARD,7,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY10,Witch,8,100,ATTACK_ENEMIES,0)
IF_ACTION_POINT(10, PLAYER0)
   ADD_PARTY_TO_LEVEL(PLAYER_GOOD,PARTY10,10,1)
ENDIF

CREATE_PARTY(PARTY11)
   ADD_to_PARTY(PARTY11,Barbarian,8,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY11,Fairy,8,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY11,Giant,8,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY11,WIZARD,7,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY11,Witch,8,100,ATTACK_ENEMIES,0)
IF_ACTION_POINT(11, PLAYER0)
   ADD_PARTY_TO_LEVEL(PLAYER_GOOD,PARTY11,11,1)
ENDIF

CREATE_PARTY(PARTY12)
   ADD_to_PARTY(PARTY12,ARCHER,7,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY12,Fairy,8,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY12,Giant,9,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY12,WIZARD,7,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY12,Witch,9,100,ATTACK_ENEMIES,0)
IF_ACTION_POINT(12, PLAYER0)
   ADD_PARTY_TO_LEVEL(PLAYER_GOOD,PARTY12,12,1)
ENDIF

CREATE_PARTY(PARTY13)
   ADD_to_PARTY(PARTY13,Monk,8,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY13,Fairy,8,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY13,Giant,8,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY13,Giant,7,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY13,Witch,8,100,ATTACK_ENEMIES,0)
IF_ACTION_POINT(13, PLAYER0)
   ADD_PARTY_TO_LEVEL(PLAYER_GOOD,PARTY13,13,1)
ENDIF

CREATE_PARTY(PARTY14)
   ADD_to_PARTY(PARTY14,Monk,8,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY14,Thief,8,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY14,Giant,8,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY14,Giant,9,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY14,Thief,9,100,ATTACK_ENEMIES,0)
IF_ACTION_POINT(14, PLAYER0)
   ADD_PARTY_TO_LEVEL(PLAYER_GOOD,PARTY14,14,1)
ENDIF

CREATE_PARTY(PARTY15)
   ADD_to_PARTY(PARTY15,Monk,8,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY15,Fairy,8,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY15,Giant,8,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY15,Giant,7,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY15,Witch,8,100,ATTACK_ENEMIES,0)
IF_ACTION_POINT(15, PLAYER0)
   ADD_PARTY_TO_LEVEL(PLAYER_GOOD,PARTY15,15,1)
ENDIF

CREATE_PARTY(PARTY16)
   ADD_to_PARTY(PARTY16,Monk,10,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY16,Fairy,10,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY16,Giant,10,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY16,Giant,10,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY16,Giant,10,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY16,Witch,10,100,ATTACK_ENEMIES,0)
   ADD_to_PARTY(PARTY16,Knight,10,100,ATTACK_ENEMIES,0)
    ADD_to_PARTY(PARTY16,samurai,10,100,ATTACK_ENEMIES,0)
IF_ACTION_POINT(16, PLAYER0)
   ADD_PARTY_TO_LEVEL(PLAYER_GOOD,PARTY16,16,1)
   SET_FLAG(PLAYER0, FLAG0, 1)
ENDIF

DISPLAY_OBJECTIVE(899, PLAYER0)

IF(PLAYER0, FLAG0 == 1)
  IF(PLAYER_GOOD, KNIGHT == 0)
     IF(PLAYER_GOOD, DUNGEON_DESTROYED == 1)
	WIN_GAME
     ENDIF
  ENDIF
ENDIF


if(player0,workshop >= 1)
	room_available(player0,workshop,1,1)
endif

if(player0,prison >= 1)
	room_available(player0,prison,1,1)
endif

if(player0,torture >= 1)
	room_available(player0,torture,1,1)
endif

if(player0,temple >= 1)
	room_available(player0,temple,1,1)
endif

if(player0,scavenger >= 1)
	room_available(player0,scavenger,1,1)
endif

if(player0,barracks >= 1)
	room_available(player0,workshop,1,1)
endif
