Moving Scene_Item to Scene_Menu

Hello everybody, I would like to ask how to make an Item List Window in main menu.
 
Problem Description
In my main menu I only have one character and 3 commands : "Items", "Map" and "Options" and lots of free space.
What I would love to have is to draw that list in main menu and when I'd pick "Items" then I would be redirected to that window, where I could use items. (With no category selection - I only have ITEMS, no EQ/keys etc.) --> Just move item list window with its help window from Scene_Item to Scene_Menu.
 
Workaround
Or at least disable category selection - > when picking "Items" command, you'll be redirected to Scene_Item but no categories - it instantly shows item list etc.
Scene_Item would have the same background as Scene_Menu and nobody would notice a thing. (=
 
Whining
I really tried many things and I was kinda close to solution, but I can't... Any help appreciated.
 
What I've got
So far I got this, though I'm not sure how to use that - I never did selectable windows.

Spoiler
It can be done.
Make a Window_Selectable.
Set item_max to $game_party.all_items.size
In draw_item do something like:

Code:
def draw_item(index)  rect = item_rect(index)  item = $game_party.all_items[index]  draw_icon(item.icon_index, rect.x, rect.y)  # I think you know what else...end
And when creating a window, set the handlers like
Code:
def create_item_window  @item_window = Window_Items.new  @item_window.set_handler(:ok, method(:on_item_ok))  @item_window.set_handler(:cancel, method(:on_item_cancel))end
And then define two methods, on_item_ok and on_item_cancel and they should handle when user selects the item (and uses it) and when user goes back to Menu

If you think you can do such thing on your own, try it.
Else, I suggest you to open a new thread.
"Just move" makes it sound so easy 🙂 But what you are doing is trying to combine the functionality of two scenes.


You can use the windows from Scene_Item, but you need to add the functionality from Scene_Item right into Scene_Menu, and make it use those windows.


Are you replacing the Status window with the Item window completely?
That bad? =P

In main menu I have disabled Status Window. (gold window as well)

There is only "Command window" and some windows with drawn pictures (nothing special - just something like a window with draw_text in it). That's why I have lots of free space and it looks bad. I want to "put" something in here, but besides "Item list" there's nothing more - I'm not using many things in that game.

I was also thinking of replacing windows in Scene_Item and setting the same background as in Scene_Menu - so it would look like the window would be opened is Scene_Menu, but I can't remove categories (weapons / key items etc.)

Hmmm...
If you want to remove categories, you'd need to change the way Scene_Item works... You will be removing the category window, then set it up such that the first window you'll activate is the item window. Then you'd also modify the cancel behavior for Item window in Scene_Item so that it returns to the previous scene rather than activating the category window.


Adding it to Scene_Menu also isn't that hard, if you know what to do... I suggest trying to edit the Scene_Item for now, then when you grasp that idea that's when you try to actually make the item list in Scene_Menu
That's what I'm trying all the time, but I totally have no experience with making selectable windows. I can make 999 windows everywhere easily, but I never did selectable ones and that confuses me. =P
Take a look at how the default script handles them.

You create the choices in the class of the Selectable window itself, while what happens when you select a certain choice is defined in the class that uses that selectable window.

You would like something like

class Scene_Menu alias start_menu_item start def start start_menu_item @item_window = Window_ItemList.new(blahblahblah) @item_window.set_handler🙂on_item_ok) end def on_item_ok #Stuff to happen when you select an item #Pattern it with the on_item_ok of Scene_Item endendOf course you'd also need to replicate the Window_MenuActor or make your Window_ItemList use the Status window to select which actor to use items upon.You'd also modify the behavior of the Item option of the menu command window so that it activates the Item list rather than go to the item scene.

It might need a bit of work to familiarize yourself with making Scenes that uses selectable windows but once you do, it's easy.
Okay okay! I managed to create that window in main menu - now when I click "Items" I'm redirected to window above and when I press "cancel" I'm back to commands.

Now, I only need to make that window draw "items" instantly, because it's empty atm - it requires choosen category by default, so I need to figure it out how to skip category selection.

Also, I need to skip actor selection - I only have one actor, so it'd be great if items could be used intantly... or ... nope I know what i'll do - I'll replace actor's face and things with "Confirm use" or something. xD
call draw_items or refresh during the start method of Scene_Menu assuming you're making the item list on the start method


And possibly supply it with the category "item" if it's needed.
Yup, that's it. Thank you!

So I guess I'll be okay for now, but who knows. (=

Thank you.
Sorry for double posting.

I'm having a problem with using items -> It crashes the game.

I tried some things (changing on_ok or whatever they are called) but it doesn't work - probably I'm just too dumby-dump to find this out.

I would like to have this like in normal Scene_Item or simpler:

-> A window with actor appears (I have only one), so I'd replace his face and stuff with text_draw(............"Use") and it would work like in normal Scene_Item -> it just uses item on 1st/all members or launch a common event.

-> Simpler: clicking "potion" instantly uses item on first actor (or all); or simply runs a common event.

Thank you in advance.
well, since you're having errors the most common thing that we need is a screenshot of that error...


and apologizing but still doing it intentionally is just...
Sorry for that mess I've created.

I copied everything from Scene_ItemBase to class Scene_Menu < Scene_MenuBase and created second 'sub window' and it works. Nevertheless thank you for help. (=

Now I'm 99.9% sure everything will be okay now.

Thank you. (=

Original thread: https://forums.rpgmakerweb.com/threads/moving-scene_item-to-scene_menu.44435/