Indie Dev

Hello Guest!. Register a free account today to become a member! Once signed in, you'll be able to participate on this site by adding your own topics and posts, sell your games, upload content, as well as connect with other members through your own private inbox!

[Eventing] Center align in "Show Text"

Status
Not open for further replies.

Sly

Villager
Xy$
0.00
Hi,

I'm looking for a way to center align the text in the messages (besides put a lot of "spaces" and pray).
I need to make a introduction with the text in the center of the screen but the maker only give me option to centering the message box vertically. I don't found a way to center the text horizontally, even looking in plugins like Yanfly Message Core.

There is a way to make or i really need to find a plugin? If i need, which one?

Thanks, and sorry my english.
 

LTN Games

Master Mind
Resource Team
Xy$
0.01
The message code is fairly easy, I have an example below. This only works with Yanflys Message Core plugin.
\px[400] Hello There !!!!
My resolution is 800x600 height.. so I just divided the 800 in half and got 400, do this to your resolution to always get the exact center of the message window.
 
  • Like
Reactions: Sly

Sly

Villager
Xy$
0.00
Thanks for the answer but, i already tried this code.
When i use this the alignment is made with the begin of the line, not the center. So the text doesn't stay centralized, just begin in the center.
(See the image to understand).
EX.png
I need some way to make the center of the text line coincide with the center of the screen.
There is a way?

Thanks again.
 

eivl

Local Hero
Xy$
0.00
I can solve this with a plugin after blizzcon, would a manual offset be good enough? You would right left or center alignment and then offset it with +/- x in pixels.
 

Sly

Villager
Xy$
0.00
First of all, thanks for the help.

Sorry, I don't understood. It will be like Yanfly "\px[400] " but defined by the center of the text (not the begining like Yanfly) and i must to put the pixel of the center (this resolve my problem, and will be awesome) OR it automaticaly put the text to begin in the center and i just adjust pushing back half of the text in pixels, measuring with the eye the difference?

I think, if like the Yanfly (begin of the text as reference) the idea is:
(If the begining of the text in X)
Will be X = ([Screen Width] /2) - ([Text Width] /2)

But, if the center of the text in X
So X = ([Screen Width] /2) OR manually added, like Yanfly.

What you think?
Thanks, and sorry. My "english" need more pratice.
 

Sly

Villager
Xy$
0.00
So, if i had a plugin to do that it would be awesome.
Preferably working with a "escape code" or activating with a "Switch" to not centralize dialog text, for example.

If you can help, i'll wait after the blizzcon and thank you.:thumbsup:
[doublepost=1447801625,1446901326][/doublepost]So, some news Eivl?
 

eivl

Local Hero
Xy$
0.00
This is more complex then i thought, i am working on it, Yanfly has said that he might do it for another update of his Core Message plugin, but no timeframe.
[doublepost=1447851882,1447849486][/doublepost]So using pixel movement with Yanflys plugin is the only solution at the moment.
 

Sly

Villager
Xy$
0.00
Thank you Eivl.
I will make without any code and wait for the plugins to update the centered lines in the game.

Maybe some day...
 

eivl

Local Hero
Xy$
0.00
I need to make a introduction
It does sound like you only are going too use it a few times.

You would need to test a bit, i have just used 1 minute on this and though it needs work, it was pretty easy to do.

This is a Scrolling Text field.

Code:
\px[40]I'm looking for a way to center align the text in the
\px[50]messages (besides put a lot of "spaces" and pray).
\px[40]I need to make a introduction with the text in the
\px[80]center of the screen but the maker only give me
\px[80]option to centering the message box vertically.
\px[40]I don't found a way to center the text horizontally,
\px[80]even looking in plugins like Yanfly Message Core.

\px[60]There is a way to make or i really need to find a
\px[180]plugin? If i need, which one?

\px[180]Thanks, and sorry my english.
 

Sly

Villager
Xy$
0.00
I tried Scrolling Text but this is too limited.=/

To explain better, some parts of the game are narrative histories and between every message some images change in the background, making the history like pages of a book or something like that. But the single messages are short. With the Scrolling Text will seem weird to my objective.

Will be a illustration, two lines of text scrolling in the whole screen, the illustration change and other two lines text scrolling.
In the end, there is much text, but is fractionated in the messages and with scrolling text i cannot control which point of the text the pictures in the background change.

Beside that, i will lost the control of the pauses between words (\., \|, etc), to do the "narrative sensation".

I don't know if i get be clear but...
 

eivl

Local Hero
Xy$
0.00
Yeah, but you can use the pixel movement command in any text field, i used scrolling because it made for a bigger example.
 
  • Like
Reactions: Sly

Sly

Villager
Xy$
0.00
Ah, sorry, i misunderstood you.
Now i got it.

I will make it without the code, if the plugin is not be launched until i finish i will update the messages to do like that.

Thanks.
 

MinisterJay

Administrator
Staff member
Administrator
Closing this old support issue due to it being solved and to deter necro-posting. If the PO desires it to be re-opened, it will.
 
Status
Not open for further replies.
Top