How do i make this look not squashed out in the game

I'm making my own custom window and it's squished in the game how do i fix that?
Window.png

Here is an example
Spoiler: in game window
1625513032754.png
So, the issue is that the engine, when drawing a windowskin, will just keep the corners at 1x, and will stretch the edges out to fit. So anything that counts as an "edge" will be stretched.

Are you using MZ? MV?
basically you need a plugin that reprograms the handling of the windowskin from stretching to repeating segments.
Alternatively, you create your own window as a picture and display that picture before you show a message. Also choose Background Transparent.
@Andar Do you know of one I could use
@Escalus MZ
@Nolonar I wouldn't even know how to begin
Edit: MZ has a window.js but i can't make heads or tails with script
If I had known one I would have pointed you to it.
I know its possible because up until including Ace that was how the engine handled the windowskin, only with MV that was changed, and several people wanted the old way back.
@Andar how do I do the picture method bc I've heard in MZ the dialog box will always be on top of the picture
@Andar how do I do the picture method bc I've heard in MZ the dialog box will always be on top of the picture
If you set the dialogue box as transparent that is irrelevant, you make a transparent image the size of your game resolution and paste on it your windowskin as you want it to look then on dialogues you put the show picture command before any message commands, you will lose any special stretching effects of "opening" a messagebox.
@Andar how do I do the picture method bc I've heard in MZ the dialog box will always be on top of the picture

First you create your window in your favorite image editing software and put it in your img/pictures folder, for example (inspired by Persona 5):
window.png


Then you display the picture before your message, and make the message background transparent:
Screenshot 2021-07-06 121359.png

Screenshot 2021-07-06 121134.png


Enjoy:
Screenshot 2021-07-06 121156.png


The example isn't very pretty, because I only spent about 5 minutes on it. It's only a proof of concept, though, so it doesn't have to be pretty.

Pros:
  • It's really simple to set up, and only uses 3 event commands (you need to hide the picture at the end, which I didn't). You can even simulate the open/close animation by playing around with the picture scaling and the Move Picture event command.
  • You have full control over your window and any window decorations (though you can't animate your windows while a message is displayed).
Cons:
  • It's a lot of effort, since you need to manage your window yourself (opening, closing, positioning, etc.)
  • You cannot make your windows adapt to the text, so you need to make sure your windows are the proper size and position, or make the text adapt to the window.
http://sumrndm.site/window-frame-anti-stretch-mz/ will do what you want. Super easy to use, no settings, just load it and go.
@ImaginaryVillain it doesn't I tried it
@Nolonar do you know what position is have to make it how to make it look like it's opening and closing how big to make it etc
@Nolonar do you know what position is have to make it how to make it look like it's opening and closing how big to make it etc

That depends on multiple factors, such as your resolution and the UI Area Width/Height (both 816x720 by default in MV and MZ), where you want to position the window (top, middle, bottom), the actual dimensions of your window picture, and what kind of opening/closing animation you want.

By default, a message window has the dimension of UI Area Width x (UI Area Height / 3), or 816x240 pixels.

By default, the window coordinates are:
  • (0, 0): top
  • (0, 240): middle
  • (0, 480): bottom

Assuming you want your window to grow from or shrink to the window's center, the x-position at the beginning of the opening animation and at the end of the closing animation will be Window Width / 2 + (UI Area Width - Window Width) / 2. The Window Width / 2 is obvious, since you want your window to start/end at its center. If your window is smaller than the UI Area Width (which I don't recommend, as it makes the calculation more complex), you want to add half of the difference between the UI Area Width and the window width. By default that's x = 816 / 2 + (816 - 816) / 2 = 408.

Meanwhile, the y-position will be y Position + Window Height / 2 + (UI Area Height / 3 - Window Height) / 2. Assuming you want the window at the bottom, that's y = 480 + 240 / 2 + (720 / 3 - 240) / 2 = 480 + 120 + (240 - 240) / 2 = 600 by default.

So the starting position for a window that grows from its center and is positioned at the bottom of the screen is (408, 600) with a scaling of (0%, 0%), and will be moved towards (0, 480) with a scaling of (100%, 100%). To close the window towards its center, you just move the window back towards (408, 600) and scale it back to (0%, 0%).

If your resolution is not the same as the UI Area Width/Height, you'll want to add half of the difference between resolution and UI Area dimension to your coordinates. For example, with a resolution of 1280x720 pixels (everything else being default), the coordinates are (640, 600) and (232, 480) for a bottom-position window because 232 = (1280 - 816) / 2.

PS: Remember that your window has borders, and that it's part of your window size, too. If your borders are too large, you'll need to adjust your window position (and possibly adjust its size as well).

This thread is being closed, due to being solved. If for some reason you would like this thread re-opened, please report this post and leave a message why. Thank you.

Original thread: https://forums.rpgmakerweb.com/threads/how-do-i-make-this-look-not-squashed-out-in-the-game.138146/