Hey all! I've been struggling to align everything with SV sprites using YEP Battle Engine Core. I've got the characters in the right spot, but now magic power animations and states are misaligned. Any tips on how to fix this? I've had a very hard time figuring out the right code to use. Thanks in advance!
MV Battler's not aligning with animations; YEP Battle Engine Core
Javascript/Plugin SupportIf it's aligned with standard home position, shouldn't they align with the modified home positions? Unless you have a plugin changing that.
It is aligned if I remove the anchor points from the character notes, but then the actors are all evenly spaced/ not where I'd like them to be. I've been fighting with that code for a long time trying to get everyone where I need them. Battle core is the only plugin I'm using to change their placement
You can give the home position at the end of the Yanfly Battle Core codes, like I think it's:
Sprite_Actor.prototype.setActorHome At the end of that method, before the line this.setHome(homeX, homeY); write (just give the numbers any values you want):
EDIT:
And I mean get rid of the anchor notetags
Sprite_Actor.prototype.setActorHome At the end of that method, before the line this.setHome(homeX, homeY); write (just give the numbers any values you want):
if (index === 0)homeX = number1;if (index === 1)homeX = number2;if (index === 2)homeX = number3;EDIT:
And I mean get rid of the anchor notetags
I'm struggling to grasp this I'm so sorry Is there anyway you can simplify this
Open your Yanfly Battle Core plugin with notepad and find the function below (Sprite_Actor.prototype.setActorHome) and put the extra lines near the end (change the numbers for x position):
Sprite_Actor.prototype.setActorHome = function(index) { var screenWidth = Graphics.boxWidth; var screenHeight = Graphics.boxHeight; var maxSize = $gameParty.maxBattleMembers(); var partySize = $gameParty.battleMembers().length; var statusHeight = eval(Yanfly.Param.BECCommandRows); statusHeight *= Window_Base.prototype.lineHeight.call(this); statusHeight += Window_Base.prototype.standardPadding.call(this) * 2; if ($gameSystem.isSideView()) { var code = Yanfly.Param.BECHomePosX; try { var homeX = eval(code); } catch (e) { var homeX = 0; Yanfly.Util.displayError(e, code, 'SIDE VIEW HOME X FORMULA ERROR'); } var code = Yanfly.Param.BECHomePosY; try { var homeY = eval(code); } catch (e) { var homeY = 0; Yanfly.Util.displayError(e, code, 'SIDE VIEW HOME Y FORMULA ERROR'); } } else { var code = Yanfly.Param.BECFrontPosX; try { var homeX = eval(code); } catch (e) { var homeX = 0; Yanfly.Util.displayError(e, code, 'FRONT VIEW HOME X FORMULA ERROR'); } var code = Yanfly.Param.BECFrontPosY; try { var homeY = eval(code); } catch (e) { var homeY = 0; Yanfly.Util.displayError(e, code, 'FRONT VIEW HOME Y FORMULA ERROR'); } } this._checkAliveStatus = false; if ($gameParty.battleMembers()[index]) { var actor = $gameParty.battleMembers()[index]; if (actor.isAlive()) this._checkAliveStatus = true; } if (index === 0) homeX = 100; if (index === 1) homeX = 300; if (index === 2) homeX = 700; this.setHome(homeX, homeY); this.moveToStartPosition();};Oh my god it worked. Thank you so much I've been trying to figure this out for so long.
Haven't dug around in the actual code of the plugins too much I would have never accomplished this with out you THANK YOU <3 <3 <3
Why are you doing all this when adjusting the home positions is right in the plugin parameters?
@ATT_Turan
It's a clean edit that takes about 1 min to make. Their battlers aren't evenly spaced and they complained about working ages with the formula, so I wanted to tell them that they can just give the values. And writing the values on separate lines is funnier than putting them on the one row that's in the Yanfly plugin settings.
It's a clean edit that takes about 1 min to make. Their battlers aren't evenly spaced and they complained about working ages with the formula, so I wanted to tell them that they can just give the values. And writing the values on separate lines is funnier than putting them on the one row that's in the Yanfly plugin settings.
Okay...but they can just give values in the plugin parameter, also, and it takes less than one minute with no opening the file and searching for functions, right? Not that providing values is necessary, since:
Except the OP screenshot indicates evenly-spaced windows, which means all one needs is a single-line formula with the correct math.
But if the question is answered, then whatever.
@ATT_Turan
What's the point of your messages again? If you wanna give them the single line formula, feel free to do that. If you have a preferable solution, just give it to them, instead of making 2 posts about the way I (correctly) answered them. Isn't this exactly the reason why some people got annoyed with you when you were more active here? 😀
EDIT: Also, maybe I'm just tired, but it's not immediately obvious to me what does their window spacing have to do with this. To my understanding they wanted to show the stuff on the battlers, not the windows.
What's the point of your messages again? If you wanna give them the single line formula, feel free to do that. If you have a preferable solution, just give it to them, instead of making 2 posts about the way I (correctly) answered them. Isn't this exactly the reason why some people got annoyed with you when you were more active here? 😀
EDIT: Also, maybe I'm just tired, but it's not immediately obvious to me what does their window spacing have to do with this. To my understanding they wanted to show the stuff on the battlers, not the windows.
Original thread: https://forums.rpgmakerweb.com/threads/battlers-not-aligning-with-animations-yep-battle-engine-core.182673/