> For the complete documentation index, see [llms.txt](https://bizachi-dev.gitbook.io/bullethell-elemental-template/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://bizachi-dev.gitbook.io/bullethell-elemental-template/scriptables/create-new-monster-wave.md).

# Create New Monster wave

Waves, win condition, boss, XP table and perks of a map are set on the GameplayManager of each scene. No ScriptableObject is needed.

Select the **GameplayManager** object in the map scene. Everything that happens during a PvE match is set here.

<figure><img src="https://215355839-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fc8AVbPtcUOjcVrQx9Eyu%2Fuploads%2Fgit-blob-06f46f2b698eed9f1b56e6604aec33ea7c26b3b8%2Fv16-gameplaymanager.png?alt=media" alt="GameplayManager in the Inspector"><figcaption><p>GameplayManager of MapArena2.</p></figcaption></figure>

***

### Revive

**Revive Seconds**: online co-op only. When a player dies, the others see a countdown of this many seconds and the player comes back when it ends. Default 20.

**Revive Limit**: offline only. How many times the player can use the **Revive** button of the defeat screen in one match. `0` means a defeat ends the run.

### Game Mode

**Win Condition**: how the match is won.

* **Survival Time**: survive until the timer reaches 0. The Boss Prefab is not used.
* **Kill Boss**: when the last wave ends the boss appears, and the match is won when it dies. The timer does not end the match.
* **Survival Time And Kill Boss**: when the timer reaches 0 the waves stop (even in the middle of a wave), the boss appears, and the match is won when it dies.

**Upgrade Mode**: what happens when the player levels up in the match.

* **Upgrade On Level Up**: the game pauses and shows 3 perk cards.
* **Upgrade On Button Click**: the player keeps upgrade points and opens the cards with a button on the HUD.
* **Upgrade Random**: a random perk is applied.

Online matches always use **Upgrade On Button Click**, because the match cannot pause for one player.

**Boss Prefab**: the boss spawned by the two boss win conditions. Its MonsterEntity must have **Is Final Boss** checked. See [Bosses](/bullethell-elemental-template/gameplay-systems/bosses.md).

{% hint style="warning" %}
If the Boss Prefab does not have **Is Final Boss** checked, the game finds no final boss to wait for and ends the match as a victory after 5 seconds.
{% endhint %}

**Survival Time**: match time in seconds, shown on the HUD.

**Waves**: the list of waves, played one after the other (see below).

### Game EXP settings

**Xp To Next Level**: XP needed for each level inside the match. Fill it with **Tools > XP Progression Generator** (see [Creating a new scene](/bullethell-elemental-template/user-interface-menus/creating-a-new-scene.md)). The first value is not used, because the character starts at level 1.

**Max Level**: highest level in the match. Keep **Xp To Next Level** at least this long.

**Min Damage**: the smallest damage a player (or a summon) can take after Defense is applied. Default 5.

**Time Display Format**: not used in v1.6; the HUD prefab has its own format.

### Perks Settings

**Max Level Stat Perks**: how many times a stat perk can be picked when its own **Max Level** is 0. Default 5.

**Max Skills / Max Stats**: fallback number of skill and stat perk slots. The real number comes from the character's **Max Skills** and **Max Stats** stats.

**Skill Perk Data / Stat Perk Data**: the perks that can be offered on level up in this map. See [Create New SkillPerkData](/bullethell-elemental-template/scriptables/create-new-skillperkdata.md) and [Create New StatPerkData](/bullethell-elemental-template/scriptables/create-new-statperkdata.md).

{% hint style="info" %}
Online, perks are sent as their position in these lists. Keep the same lists, in the same order, in every map of a multiplayer game. The shipped maps all use the same 8 skill perks and 15 stat perks.
{% endhint %}

### Monster Spawn

**Spawn Points List**: the spawn areas of the map. Each monster picks one at random.

### PVP Spawn

**Team Spawn Slots**: where players start. In PvE (offline and co-op) every player starts at the first slot. In PvP each team uses its own slot.

**Team Spawn Spread Radius**: random offset around the slot so players do not overlap.

***

## Waves

<figure><img src="https://215355839-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fc8AVbPtcUOjcVrQx9Eyu%2Fuploads%2Fgit-blob-5f3e3fb14e2324cbb925e445f5b4a08da4bf989e%2Fv16-gameplaymanager-waves.png?alt=media" alt="Waves list"><figcaption></figcaption></figure>

Each wave spawns one or more kinds of monster at the same time, for a set duration. The next wave starts right after.

**Wave Duration**: how long the wave lasts, in seconds.

**Monsters**: the monsters of this wave. For each one:

* **Monster Prefab**: the monster to spawn. See [Create New Monster/Mob](/bullethell-elemental-template/scriptables/create-new-monster-mob.md).
* **Spawn Interval**: seconds between two spawns of this monster. The first one comes after one interval, so a wave of 20 seconds with an interval of 2 spawns 10 of them.
* **Gold Per Monster**: gold the monster gives when it dies.
* **Xp Per Monster**: XP the monster gives when it dies.

**Spawn Boss After Wave**: not used in v1.6. When the boss appears depends only on the **Win Condition**.

{% hint style="success" %}
Add up your wave durations and compare them with **Survival Time**. If the waves end first, nothing spawns until the timer ends. If the timer ends first with Survival Time And Kill Boss, the remaining waves are skipped and the boss comes.
{% endhint %}

### Tips

* Difficulty comes from the monster prefabs (the Lv1 to Lv4 variants) and from the spawn intervals. Nothing scales automatically with the number of players, except the boss HP in co-op.
* The pause menu and the perk cards freeze the wave clock offline, so pausing never makes monsters pile up.
* In co-op only the room leader spawns the waves. If the leader leaves, the new leader continues from the same wave.
