Question about Yanfly's Party System and Battle Engine Core

nguyenvuky

Villager
Member
Joined
Nov 28, 2014
Messages
13
Reaction score
0
First Language
Vietnamese
Primarily Uses
These are two plugin that I'm asking about:


http://yanfly.moe/2015/10/10/yep-3-battle-engine-core/


http://yanfly.moe/2015/11/20/yep-29-party-system/


Currently, my game allows player to use maximum 7 characters in battle, so I set "Command Window Rows:" parameter in BattleEngineCore to 7. However, from start of the game, player's party has 1 member only. When encountering monster, command window is too high, as if enough for 7 members. So I'm looking for a way (plugin command or anything) to control the height of window rows in-game.


Thank you for reading. :)
 

TakaDynasty

Apologetic Lurker
Veteran
Joined
Dec 21, 2016
Messages
41
Reaction score
8
First Language
English
Primarily Uses
Disclaimer: I'm not amazing at JavaScript, but I'd like to try to at least set you on the right path, so I'll give it a shot.


You may well just need to make your game window bigger. This can be done with Yanfly's core plugin. A bigger window will mean the command window is the same size, but everything will be visible. If you want a smaller window, tread below with great caution, as I am terrible at JavaScript. :p

Found this in the Battle Engine plugin code:
 


statusHeight = eval(Yanfly.Param.BECCommandRows)



And Yanfly.Param.BECCommandRows is essentially whatever you set your parameter to. In this case, 7.

What you might attempt is setting it to 4, and then try setting up a parallel-running common event with this script:



Yanfly.Param.BECCommandRows = Number((Yanfly.Parameters['Command Window Rows']) + ($gameParty.members().length - 4))



I have no idea if that will work, so I'd definitely try messing with window size first. :p If it does work, by some miracle, make sure you test with a full party to see if it adds to the rows when you get more then four party members. The HOPE is that it'll basically give you the default status window height until you have more than four party members, at which point it'll add an extra row at 5, then 6, then 7.
 
Last edited by a moderator:

nguyenvuky

Villager
Member
Joined
Nov 28, 2014
Messages
13
Reaction score
0
First Language
Vietnamese
Primarily Uses
Disclaimer: I'm not amazing at JavaScript, but I'd like to try to at least set you on the right path, so I'll give it a shot.


You may well just need to make your game window bigger. This can be done with Yanfly's core plugin. A bigger window will mean the command window is the same size, but everything will be visible. If you want a smaller window, tread below with great caution, as I am terrible at JavaScript. :p

Found this in the Battle Engine plugin code:
 



statusHeight = eval(Yanfly.Param.BECCommandRows)



And Yanfly.Param.BECCommandRows is essentially whatever you set your parameter to. In this case, 7.

What you might attempt is setting it to 4, and then try setting up a parallel-running common event with this script:




Yanfly.Param.BECCommandRows = Number((Yanfly.Parameters['Command Window Rows']) + ($gameParty.members().length - 4))



I have no idea if that will work, so I'd definitely try messing with window size first. :p If it does work, by some miracle, make sure you test with a full party to see if it adds to the rows when you get more then four party members. The HOPE is that it'll basically give you the default status window height until you have more than four party members, at which point it'll add an extra row at 5, then 6, then 7.


Thank you for your reply. I did try but it not worked. The statusHeight variable is used to determined position of battler.


However I found a solution thank to your idea.


Basically I had to edit the js file of BattleEngineCore, I replaced Yanfly.Param.BECCommandRows by $gameParty.battlemembers().length in some lines (4 total) and it worked well. In order to keep the minimum line of status windows as 4, I used Math.max(4, $gameParty.battlemembers().length). So in the end, I totally ignore the use of Yanfly.Param.BECCommandRows, hope none of Yanfly's other scripts use this variable.


Until this point, I don't know if changing his script is allowed or not, if anyone know please tell me.
 

TakaDynasty

Apologetic Lurker
Veteran
Joined
Dec 21, 2016
Messages
41
Reaction score
8
First Language
English
Primarily Uses
@nguyenvuky Glad I could help at least indirectly!

I imagine as long as you don't redistribute the modified code as your own, Yanfly won't mind. But he probably won't help if it breaks something else in the plugin either. :p So here's hoping nothing else uses that variable!
 

LadyBaskerville

Hell-poodle
Veteran
Joined
Sep 12, 2016
Messages
645
Reaction score
497
First Language
German
Primarily Uses
RMMV
Yanfly's Terms of Use (from his site) state:

Any original material made by Yanfly is free for use with both free and commercial RPG Maker games unless specified otherwise. I do not demand royalties or special liberties if you choose to use Yanfly original content in your commercial games. (Although a free copy of your game would be nice!) I only ask that you provide “Yanfly” or “Yanfly Engine” a spot in your game’s credits.


Any edits made to Yanfly original material are okay as long as you still provide the proper credit. Any non-Original content posted, linked, or shared on my website and channel will still require you to contact the respective parties for permission of use.
so you should be fine :)
 

Users Who Are Viewing This Thread (Users: 0, Guests: 1)

Latest Threads

Latest Posts

Latest Profile Posts

Can't wait for the next Sonichu
Birdhouses are usually made of wood. Birds typically live in trees. Trees are wood. Birdhouses are made of birdhouses.
He just discovered cellphones...

(I don't know why am I drawing so much these days...)
In medieval times, a common way to eat food was upon edible plates, which were made of bread, called trenchers.

Forum statistics

Threads
93,670
Messages
914,448
Members
123,260
Latest member
ft371pta
Top