REM Play Level Nevergrin

REM ******* Basic settings *******

SET_GENERATE_SPEED(300)

MAX_CREATURES(PLAYER0,12)

START_MONEY(PLAYER0,9000)

ADD_CREATURE_TO_POOL(FLY,6)
ADD_CREATURE_TO_POOL(DEMONSPAWN,4)
ADD_CREATURE_TO_POOL(SORCEROR,5)
ADD_CREATURE_TO_POOL(HELL_HOUND,7)

REM ********** Available creatures **********

CREATURE_AVAILABLE(ALL_PLAYERS,FLY,1,1)
CREATURE_AVAILABLE(ALL_PLAYERS,DEMONSPAWN,1,1)
CREATURE_AVAILABLE(ALL_PLAYERS,SORCEROR,1,1)
CREATURE_AVAILABLE(ALL_PLAYERS,HELL_HOUND,1,1)

REM ********** Available rooms **********

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,RESEARCH,1,1)

REM ********** Available spells **********

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_SIGHT,1,0)
MAGIC_AVAILABLE(ALL_PLAYERS,POWER_SPEED,1,0)
MAGIC_AVAILABLE(ALL_PLAYERS,POWER_CALL_TO_ARMS,1,0)


REM ********** Game settings **********

IF(PLAYER0,DUNGEON_DESTROYED == 1)
    LOSE_GAME
ENDIF

SET_CREATURE_STRENGTH(AVATAR,30)


CREATE_PARTY(ONE)
    ADD_TO_PARTY(ONE,THIEF,1,500,ATTACK_ENEMIES,0)
    ADD_TO_PARTY(ONE,THIEF,1,500,ATTACK_ENEMIES,0)

CREATE_PARTY(TWO)
    ADD_TO_PARTY(TWO,BARBARIAN,1,500,ATTACK_ENEMIES,0)
    ADD_TO_PARTY(TWO,GIANT,1,600,ATTACK_ENEMIES,0)

IF(PLAYER0,TOTAL_CREATURES >= 7)
    ADD_CREATURE_TO_LEVEL(PLAYER_GOOD,THIEF,-1,1,1,500)
    IF(PLAYER0,TOTAL_CREATURES >= 12)
        ADD_CREATURE_TO_LEVEL(PLAYER_GOOD,THIEF,-1,3,1,500)
        SET_TIMER(PLAYER_GOOD,TIMER0)
        ADD_TUNNELLER_PARTY_TO_LEVEL(PLAYER_GOOD,ONE,1,DUNGEON_HEART,0,1,500)
    ENDIF
ENDIF

IF(PLAYER_GOOD,TIMER0 >= 3000)
    ADD_PARTY_TO_LEVEL(PLAYER_GOOD,ONE,-1,2)
ENDIF

IF_ACTION_POINT(2,PLAYER0)
    ADD_CREATURE_TO_LEVEL(PLAYER_GOOD,DEMONSPAWN,1,2,1,0)
    ADD_CREATURE_TO_LEVEL(PLAYER_GOOD,DEMONSPAWN,1,1,2,0)
    ADD_CREATURE_TO_LEVEL(PLAYER_GOOD,DEMONSPAWN,1,1,5,0)
ENDIF

IF_ACTION_POINT(4,PLAYER0)
    ADD_CREATURE_TO_LEVEL(PLAYER_GOOD,ARCHER,5,1,1,500)
    ADD_PARTY_TO_LEVEL(PLAYER_GOOD,ONE,5,1)
ENDIF

IF_ACTION_POINT(6,PLAYER0)
    ADD_CREATURE_TO_LEVEL(PLAYER_GOOD,ARCHER,7,1,1,500)
    ADD_PARTY_TO_LEVEL(PLAYER_GOOD,ONE,7,1)
ENDIF

IF_ACTION_POINT(3,PLAYER0)
    ADD_CREATURE_TO_LEVEL(PLAYER_GOOD,AVATAR,-2,1,1,1500)
    ADD_PARTY_TO_LEVEL(PLAYER_GOOD,TWO,-2,1)
    ADD_CREATURE_TO_LEVEL(PLAYER_GOOD,ARCHER,-2,2,1,500)
    IF(PLAYER_GOOD,TOTAL_CREATURES == 0)
        WIN_GAME
    ENDIF
ENDIF
