Envision, Create, Share

Welcome to HBGames, a leading amateur game development forum and Discord server. All are welcome, and amongst our ranks you will find experts in their field from all aspects of video game design and development.

Menu window transparent and seperate windowskin, possible?

I have very limited knowledge of RGSS, I sincerely apologize if what follows is noobish  :blush: .

I have been toying around with the default script but i one thing that i really want to achieve but i can't! I want to make the menu window (the one that show up when you press escape during a game) semi transparent.

I want to make it transparent such a way that when you press escape, you can see the map. I have made a quick example on what's on my mind:

http://img134.imageshack.us/img134/3121 ... entfd9.jpg[/img]

This is obviously photoshoping, the base idea is to make a menu window with around 80% transparency. Is this possible?

I've got another question; I wanted to know whether i can use a separate windowskin for the menu. Is script needed to do so?

I'll gladly accept any help!

Thanks for reading my topic! <3

Peace.

Jess
 
Since the following is completely remembered from when I used RMXP, I'd suggest you to backup your project or scripts.rxdata in order to allow me making mistakes without screwing your project up unintentionally ^^"

The windowskin thing is quickly answered... you sure need to script, but as it's a single line, it shouldn't be too bothersome. All you need to do is inserting the following line in every window's initialize method used by Scene_Menu... (aka click on, for example, Window_Gold in the script editor's left column, then find the line 'def initialize', and below the 'super(...)' line, insert this line:)
Code:
self.windowskin = Cache.windowskin("NameOfImageWithoutFileExtension")
Come to think of it, it will be bothersome, because the default menu screen uses like a fortune of windows... maybe you'd be better off changin the message window's windowskin...

A common way to achieve transparency is the way to overlay the menu scene over the map scene... not too hard actually, just look for the '$scene = Scene_Menu.new' within Scene_Map and replace it with this:
Code:
$scene2 = Scene_Map.new
Now, head for Scene_Menu and search a line containing '$scene = Scene_Map.new', which you want to change to
Code:
$scene2 = nil
That should do it, though I'm not entirely sure because I simply never used it myself... oh, you need to change all the window's opacity as well... do the same as for the windowskin, just with this line:
Code:
self.back_opacity = 204
This sets the opacity of the blue window background to 80% of 255, which is the non-transparent value...

Hope this works.
 
I've always used this:
Code:
@map = Spriteset_Map.new
And then settings the opacity to like 200 for the windows, as for the default menu:
Code:
@command_window.opacity = 200
@status_window.opacity = 200
@playtime_window.opacity = 200
@gold_window.opacity = 200
Note that 0 is totally transparent, and 255 is opaque. Many people I have known misunderstood this part :P

Oh, and before I forget, search for:
Code:
@status_window.dispose
And toss in right above it:
Code:
@map.dispose

Cheers.
 

Thank you for viewing

HBGames is a leading amateur video game development forum and Discord server open to all ability levels. Feel free to have a nosey around!

Discord

Join our growing and active Discord server to discuss all aspects of game making in a relaxed environment. Join Us

Content

  • Our Games
  • Games in Development
  • Emoji by Twemoji.
    Top