oasis-b

Docs / Battle system

LW_BattleRules

Battle system
RPG Maker MV and MZ battle rules and defeat without game over plugin

Defeat without Game Over, a safe battle abort, turn counters for troop events, enemies standing on one ground line.

Battle Essentials ($9.99)Full Collection ($19.99)

Needs LW_Core (LWZ_Core in MZ) above all Living World plugins in the Plugin Manager. It's included in every pack.

LW_BattleRules in a test project

Small battle rules that story RPGs need again and again.

Highlights

Ideas for your game

Works well with

LW_VictoryScreenLW_BattleInsightLW_EnemyScaling

Introduction

Small battle rules that story RPGs need again and again.

Defeat Without Game Over

When the party loses, it wakes up at the wake point: everybody healed, part of the gold gone. The event that started the battle stops, so the story doesn't go on as if the party had won.

Set the wake point with a bed, a bench or an inn:

LW_WakePoint                  here, where the party stands
LW_WakePoint mapId x y        a fixed spot

Without a wake point the party wakes up at the start position.

These battles still end with Game Over:

- troops with <LW GameOver> in their name (your final boss)
These work like normal MV:
- battles with "Continue when loss" in the Battle Processing command
- battle tests

Aborting a Battle

Don't use "Abort Battle" from a troop event when a turn order plugin (CTB, ATB) is installed. The battle resets its phase afterwards and the player is stuck. Use this script call instead:

LW.abortBattle();

The battle ends as soon as no message and no event is running.

A tutorial fight the player shouldn't win: give the troop a page with "Enemy HP below 30%" that calls LW.abortBattle().

Turn Counters

MV's turn conditions don't work well with turn order plugins. Count actions instead, in a troop page condition or a script:

LW.turnCount('a1')      actions of actor 1
LW.turnCount('e0')      actions of the first enemy in the troop
LW.turnCount('all')     all actions so far

Example with a Conditional Branch (Script):

LW.turnCount('e0') >= 3

Ground Line

Enemies placed by hand in the troop editor often float at different heights. With a Ground Line the whole troop moves down until the highest feet touch that line. Their spacing stays the same. Enemies with <LW Flying> in their note keep their height.

Terms of Use

See TERMS_OF_USE.txt in the download. Short version: use it in as many of your own games as you like, free or commercial. Edit it for your game, but keep this header. Don't share or resell the plugin files on their own. Name oasis-b in the credits of your game.

Changelog

Version 1.0.2 - 2026-11-25 - Ground Line leaves a little room above the status window.

Version 1.0.1 - 2026-11-25 - Ground Line keeps the lowest enemy above the status window.

Version 1.0.0 - 2026-11-21 - First release.

Plugin commands in MZ

In MZ these come as Plugin Command in the event editor, with fields to fill in. Old MV text commands from copied events keep working.

Set Wake Point

Where the party wakes up after a lost battle. Map 0 = where the player stands now.

  • Map (number): Map ID. 0 = the current map and the tile of the player. Default: 0.
  • X (number) Default: 0.
  • Y (number) Default: 0.

Abort Battle

Ends the running battle like "Abort Battle", but waits for messages and the battle event.

Introduction

Small battle rules that story RPGs need again and again.

Defeat Without Game Over

When the party loses, it wakes up at the wake point: everybody healed, part of the gold gone. The event that started the battle stops, so the story doesn't go on as if the party had won.

Set the wake point with a bed, a bench or an inn, with the plugin command "Set Wake Point": Map 0 means here, where the party stands, any other map ID with X and Y is a fixed spot.

Without a wake point the party wakes up at the start position.

These battles still end with Game Over:

- troops with <LW GameOver> in their name (your final boss)
These work like normal MZ:
- battles with "Continue when loss" in the Battle Processing command
- battle tests

Aborting a Battle

Don't use "Abort Battle" from a troop event when a turn order plugin (like LWZ_TurnOrder) is installed. The battle resets its phase afterwards and the player is stuck. Use the plugin command "Abort Battle" or this script call instead:

LW.abortBattle();

The battle ends as soon as no message and no event is running.

A tutorial fight the player shouldn't win: give the troop a page with "Enemy HP below 30%" that calls LW.abortBattle().

Turn Counters

MZ's turn conditions don't work well with turn order plugins or time progress battles. Count actions instead, in a troop page condition or a script:

LW.turnCount('a1')      actions of actor 1
LW.turnCount('e0')      actions of the first enemy in the troop
LW.turnCount('all')     all actions so far

Example with a Conditional Branch (Script):

LW.turnCount('e0') >= 3

Ground Line

Enemies placed by hand in the troop editor often float at different heights. With a Ground Line the whole troop moves down until the highest feet touch that line. Their spacing stays the same. The lowest enemy never moves below the top of the status window. Enemies with <LW Flying> in their note keep their height.

Terms of Use

See TERMS_OF_USE.txt in the download. Short version: use it in as many of your own games as you like, free or commercial. Edit it for your game, but keep this header. Don't share or resell the plugin files on their own. Name oasis-b in the credits of your game.

Changelog

Version 1.0.0 - First release for MZ.

Get it

LW_BattleRules is in these packs. Every pack comes as an MV and an MZ download at the same price and needs no other plugin collection. Tested in RPG Maker MV 1.6.2 and MZ 1.10.0 games on Windows, macOS and Linux and in current browsers.

Battle Essentials ($9.99)Full Collection ($19.99)
← LW_ActionScriptLW_HitFormula →