REM ********************************************
REM  Ancient Keeper campaign for KeeperFX
REM  Script for Level 16
REM  Version 1.00
REM ********************************************

SET_GENERATE_SPEED(600)

COMPUTER_PLAYER(PLAYER2,0)
COMPUTER_PLAYER(PLAYER3,0)

START_MONEY(ALL_PLAYERS,10000)

DISPLAY_OBJECTIVE(84,PLAYER0)

MAX_CREATURES(PLAYER0,10)
MAX_CREATURES(PLAYER2,25)
MAX_CREATURES(PLAYER3,25)

ADD_CREATURE_TO_POOL(DRAGON,30)
ADD_CREATURE_TO_POOL(DEMONSPAWN,9)

CREATURE_AVAILABLE(PLAYER0,DEMONSPAWN,1,1)
CREATURE_AVAILABLE(ALL_PLAYERS,DRAGON,1,1)

DOOR_AVAILABLE(PLAYER0,STEEL,0,30)
DOOR_AVAILABLE(ALL_PLAYERS,MAGIC,1,0)

MAGIC_AVAILABLE(ALL_PLAYERS,POWER_HAND,1,1)
MAGIC_AVAILABLE(ALL_PLAYERS,POWER_SLAP,1,1)
MAGIC_AVAILABLE(ALL_PLAYERS,POWER_IMP,1,0)
MAGIC_AVAILABLE(ALL_PLAYERS,POWER_OBEY,1,0)
MAGIC_AVAILABLE(ALL_PLAYERS,POWER_SPEED,1,0)
MAGIC_AVAILABLE(ALL_PLAYERS,POWER_PROTECT,1,0)
MAGIC_AVAILABLE(ALL_PLAYERS,POWER_CALL_TO_ARMS,1,0)
MAGIC_AVAILABLE(ALL_PLAYERS,POWER_HEAL_CREATURE,1,0)

ROOM_AVAILABLE(PLAYER0,BRIDGE,1,0)

IF(PLAYER0,TOTAL_CREATURES>0)
  SET_FLAG(PLAYER0,FLAG1,1)
ENDIF

IF(PLAYER0,FLAG1<1)
  IF(PLAYER0,BATTLES_LOST>0)
    DISPLAY_OBJECTIVE(85,PLAYER0)
  ENDIF
ENDIF

IF(PLAYER0,DEMONSPAWN > 0)
  DISPLAY_OBJECTIVE(86,PLAYER0)
ENDIF

IF(PLAYER0,ENTRANCE > 0)
  DISPLAY_OBJECTIVE(87,PLAYER0)
ENDIF

IF(PLAYER0,DRAGON > 0)
  DISPLAY_OBJECTIVE(88,PLAYER0)
  DISPLAY_INFORMATION(89,PLAYER0)
ENDIF

IF(PLAYER0,ALL_DUNGEONS_DESTROYED == 1)
  IF(PLAYER_GOOD,TOTAL_CREATURES < 1)
    DISPLAY_OBJECTIVE(90,PLAYER0)
    WIN_GAME
  ENDIF
ENDIF
