Preserved forum archive. This topic stores the original first post and locally mirrored RPG Maker Web attachments when available. It is posted by the BMMPlay archive account, not by the original creator.
Original Source
- Original title: Battle Formation[Beta]
- Original author: Lecode
- Original date: November 21, 2015
- Source thread: https://forums.rpgmakerweb.com/threads/battle-formation-beta.51136/
- Source forum path: Game Development Engines > RPG Maker Javascript Plugins > JS Plugin Releases (RMMV)
Summary
Battle Formation 1.0 By Lecode Introduction This plugin adds the possibility to create battle formations with defined positions and bonuses.
Archived First Post
Battle Formation 1.0
By Lecode
By Lecode
Introduction
This plugin adds the possibility to create battle formations with defined positions and bonuses.
(Beta)
I know that currently the plugin isn't fully compatible with Yanfly's ones.
I plan to make a patch.
Screenshot
Files
Plugin
BattleFormations.json
Dependencies
MVCommons
LeUtilities
How to Use
There are a lot of parameters so make sure to check them.
And see the detailed help:
Setup
- Download the plugin and save it as LeBattleFormation.js
- Place it via the plugin manager under MVCommons and LeUtilities
- Get the file BattleFormations.json and place it in your project Data folder
- Make sure to set the default formation via the parameters
Create a formation
The file BattleFormations.json purpose is to hold all created formations. So, to create a new formation you'll needto modify this file.
Let's analyse the file with just one formation:
[{ "name": "Equilibred", "unlock": "true", "hide": "false", "size": 5, "positions": [ [525,310], [565,350], [610,275], [635,310], [660,345] ], "bonus": [ ["def 10%"], ["def 10%"], ["atk 10%"], ["mat 10%"], ["mcr -20%"] ], "partyBonus": ["atk 6%","def 6%","mdf 6%"]}]The file starts with [ and ends with ]. The whole file is an array. Do not remove them.
Creating a new formation consists of adding some code inside this array.
That code follows a special pattern as you can see below.
{ "name": NAME OF THE FORMATION, "unlock": CONDITION TO UNLOCK BY DEFAULT, "hide": CONDITION TO HIDE BY DEFAULT, "size": MAX PARTY MEMBERS IN BATTLE FOR THAT FORMATION, "positions": [ [X1,Y1], [X2,Y1], ... [XN,YN] <= WITHOUT COMMA HERE (last element) ], "bonus": [ [BONUS_A1,BONUS_A2,BONUS_A3...], [BONUS_B1,BONUS_B2...], ... [BONUS_Z1,...] <= NO COMMA HERE (last element) ], "partyBonus": [BONUS_1,BONUS_2,BONUS_3...] <= NO COMMA HERE} <= NO COMMA IF IT'S THE LAST FORMATIONStrings for "unlock" and "hide" are evaluated and must return a boolean ( true or false ). You can set for example:
"unlock": "$gameParty.members().length >= 2",to enable that formation only if there are 2 or more actors in the party.
"positions" and "bonus" returns an array.
In the case of "positions", this array must contains the coordinate of each member as an array ( [x,y] ).
Make sure that the number of coordinates is equals to the "size" of that formation. Obviously.
Same for "bonus". This array is also composed with arrays, which the number is equals to "size" value.
See below to see how to configure the bonuses.
I suggest you to examine the pre-made formations in the file to understand better the syntaxe.
Setup Bonuses
Each array inside the "bonus" array contains one or more strings. See this example:"bonus": [ ["mhp 15%"], <= BONUS FOR THE FIRST MEMBER ( +15% MAX HP) ["atk 20%","mat 20%"], <= BONUSES FOR THE SECOND MEMBER ( +20% ATK and 20% MAT ) ["def -15"], <= ... ( -15 flat DEF ) ["mmp 80"] <= ... ( +80 flat MAX MP )],The string pattern is: "key value" or "key value%".
Keys are simply used stats in the Game_Battler class:
mhp: Max HP
mmp: Max MP
atk: Attack
def: Defense
mat: Magic attack power
mdf: Magic attack power
agi: Agility
luk: Luck
hit: Hit rate
eva: Evasion rate
cri: Critical rate
cev: Critical evasion rate
mev: Magic evasion rate
mrf: Magic reflection rate
cnt: Counter attack rate
hrg: HP regeneration rate
mrg: MP regeneration rate
trg: TP regeneration rate
tgr: Target rate ( I don't know exactly what is the purpose of that stat...)
grd: Guard effect rate
rec: Recovery effect rate
pha: Pharmacology ability
mcr: MP cost rate
tcr: TP charge rate
pdr: Received physical damage rate
mdr: Received magical damage rate
fdr: Received floor damage rate
exr: Experience rate
"partyBonus": ["atk 6%","def 6%","mdf 6%"]Finnaly, make sure to add a comma to the } thing if it's not the last formation.
[{ "name": "Harmony", "unlock": "true", "hide": "false", "size": 4, "positions": [ [560,320], [630,275], [655,310], [680,345] ], "bonus": [ ["mhp 15%"], ["pdr 15%"], ["mdr 15%"], ["rec 15%"] ], "partyBonus": ["eva 10%"]}, <== COMMA{ "name": "Mentor & Apprentice", "unlock": "$gameParty.members().length >= 2", "hide": "false", "size": 2, "positions": [ [525,310], [635,310] ], "bonus": [ ["mhp 10%","pdr 400%","mdr 20%"], ["exr 100%"] ], "partyBonus": ["exr 20%"]} <=== NO COMMA]
Credit and Thanks
- Lecode
Author's Notes
I plan to add some features in the future, or maybe anothers plugins to give more sense to this,
like an AOE Manager plugin.
Downloads / Referenced Files
Log in to download
Log in, then follow the RPG Maker Developers Group to see these download links.
Log in to downloadLicense / Terms Note
Credit and Thanks - Lecode Author's Notes I plan to add some features in the future, or maybe anothers plugins to give more sense to this,
Creator Claims / Removal
If you are the original creator and want this listing reassigned, edited, or removed, join BMMPlay and contact the moderators with proof that matches the original RPG Maker Web profile, linked GitHub, itch.io page, or another public creator identity.
Replies (0)
No replies yet.
0
replies
1
view
Topic Summary
Loading summary...