Yanfly message positioning with a 2x zoom

RoseRainblood

Veteran
Veteran
Joined
Nov 29, 2018
Messages
73
Reaction score
8
First Language
English
Primarily Uses
RMMV
Hi all,

This has been an issue I've been trying to fix for a while.

Yanfly's Message Core and ExtMesPack1 allow me to position a message above an event's head with \msgevent[x]. It works perfectly when RPG Maker MV doesn't have a zoom on it, but when at 2x zoom, the positioning is off.

I've found the JS in ExtMesPack1 that changes the positioning and added +48 due to the 2x zoom:

if (eventId <= 0) {
x = $gamePlayer.screenX();
y = $gamePlayer.screenY();
y -= $gamePlayer.spriteHeight()+48;
} else {
var ev = $gameMap.event(eventId);
if (ev) {
x = ev.screenX();
y = ev.screenY();
y -= ev.spriteHeight()+48;
}
}
}


It works for the player when a message is above their head, which is great. It's exactly where it should be but it doesn't work for events. The positioning is still slightly off for them. Does anyone know what I need to change in this code to get it to work for events?

This is the zoom script I'm using. (I have it placed in a parallel event on each map)
var xPos = $gamePlayer.screenX();
var YPos = $gamePlayer.screenY();

$gameScreen.setZoom(xPos, YPos, 2)


I also tried out MSB_MapZoom which works wonderfully as a zoom plugin and saves me having a parallel event script on every map, but sadly the message boxes are even more out of position with this plugin.
 

mlogan

Global Moderators
Global Mod
Joined
Mar 18, 2012
Messages
15,381
Reaction score
8,537
First Language
English
Primarily Uses
RMMV

I've moved this thread to Plugin Support. Please be sure to post your threads in the correct forum next time. Thank you.

 

ct_bolt

Creator
Veteran
Joined
May 3, 2012
Messages
954
Reaction score
520
First Language
Javascript
Primarily Uses
RMMZ
Yanfly's Message Core and ExtMesPack1 allow me to position a message above an event's head with \msgevent[x]. It works perfectly when RPG Maker MV doesn't have a zoom on it, but when at 2x zoom, the positioning is off.
I was commissioned a bit ago to make such a plugin. It has many many features.
Still perfecting it but hey I guess I'll early release to the public since it seems to be needed :)

Here's a couple very small sample of how an event could be set up...
1580800005928.png
1580799922421.png

See page screenshots for more info. I'm getting quite lazy at explaining how my plugins work lol.

Well let me know how it goes. :popcorn:
Been really trying to thoroughly test this one. Seems to be working pretty nicely for me.

I am charging a minimum of $2.00 for this one though, I spent quite a bit of time developing this one.
(though if you really really really can't afford the cost I could possibly donate for a good cause)
 
Last edited:

RoseRainblood

Veteran
Veteran
Joined
Nov 29, 2018
Messages
73
Reaction score
8
First Language
English
Primarily Uses
RMMV
This is pretty neat. I bought it and gave it a try. It's not working successfully for me currently. Where would I need to place this plugin?

If I place it above Yanfly's Message Core/ExtMesPack1, the messages above the heads doesn't work. However, if I place it BELOW those plugins, the messages above the heads do work. And that's great. Unfortunately doing that makes the text messages/choice boxes etc go off center in some scenes and towards the far bottom right of the screen. It does this even with all plugins disabled minus Yanfly's Message Core/ExtMesPack1. When I disable them, the text is fine and not off center anymore. But of course, I need those plugins enabled. :')

There's also type error when going into the menu/inputting text to name a character:"Cannot read property 'pages' of null". I started a new game but it still happened so I'm disabling plugins to find out what the cause of it is.

This plugin would be perfect for me if I can get it working so I'm hoping there's an easy fix to these issues.
 
Last edited:

ct_bolt

Creator
Veteran
Joined
May 3, 2012
Messages
954
Reaction score
520
First Language
Javascript
Primarily Uses
RMMZ
This is pretty neat. I bought it and gave it a try.
Thank you for the purchase!
Where would I need to place this plugin?
Place below Yanfly's plugins and most likely below all other plugins too for best results.
1580832727189.png
text messages/choice boxes etc go off center in some scenes and towards the far bottom right of the screen.
Oh me goodness!? Woops! That's a pretty big problem... sorry about that. I knew I needed more testing...
Fixed please download v0.92. Seems to be working now for me.

There's also type error when going into the menu/inputting text to name a character:"Cannot read property 'pages' of null". I started a new game but it still happened so I'm disabling plugins to find out what the cause of it is.
Hmm... couldn't replicate this one... not sure what that's about really...
...but I think I fixed the issue... please try and let me know.

This plugin would be perfect for me if I can get it working so I'm hoping there's an easy fix to these issues.
Hope that fixed all the issues. Sorry again about that. Please let me know how it goes for ya :)

Thanks again for testing and purchasing.

Shouldn't have to pay again right? ...If so I'll just send you a direct link.
 

RoseRainblood

Veteran
Veteran
Joined
Nov 29, 2018
Messages
73
Reaction score
8
First Language
English
Primarily Uses
RMMV
I've found out that the Plugin that causes the type error "Cannot read property 'pages' of null" is Yanfly's Event Mini Label plugin. Luckily that's not one of the plugins I need, so I turned it off and everything is working fine.

Also, the text being off center and on the right is fine now. It may have been my fault, due to having the old x and y \msgpos still there. Now I've removed that, it's working great!

Thank you so much for this plugin. It will save me a lot of time! If I come across any other issues, I will be sure to let you know.
 

ct_bolt

Creator
Veteran
Joined
May 3, 2012
Messages
954
Reaction score
520
First Language
Javascript
Primarily Uses
RMMZ
I've found out that the Plugin that causes the type error "Cannot read property 'pages' of null" is Yanfly's Event Mini Label plugin. Luckily that's not one of the plugins I need, so I turned it off and everything is working fine.

Also, the text being off center and on the right is fine now. It may have been my fault, due to having the old x and y \msgpos still there. Now I've removed that, it's working great!

Thank you so much for this plugin. It will save me a lot of time! If I come across any other issues, I will be sure to let you know.
No prob. Yay! Very glad to hear it's working now again. I still want to do a few more things to this one yet myself like better scroll & more plugin command options.
Also I'll fix the issue with mini-label too though just for best compatibility :)
Now fixed the issue with Yanfly Mini Event Label Plugin :)

Edit:
@RoseRainblood: The problem with Yanfly Mini Event Label Plugin is now fixed :)
v0.93 Compatiblility/Bugfix: Now works with Yanfly Mini Event Label Plugin :)


Thanks again for testing ;)

Happy Game Making :)
 
Last edited:

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

Latest Threads

Latest Profile Posts

Don't forget, aspiring writers: Personality isn't what your characters do, it is WHY they do it.
Hello! I would like to know if there are any pluggings or any way to customize how battles look?
I was thinking that when you start the battle for it to appear the eyes of your characters and opponents sorta like Ace Attorney.
Sadly I don't know how that would be possible so I would be needing help! If you can help me in any way I would really apreciate it!
The biggest debate we need to complete on which is better, Waffles or Pancakes?
rux
How is it going? :D
Day 9 of giveaways! 8 prizes today :D

Forum statistics

Threads
106,051
Messages
1,018,549
Members
137,837
Latest member
Dabi
Top