Jump to content
Sign in to follow this  
samsasalem

Remove item categories

Recommended Posts

Hey, I'm making an adventure-like game where there are no item categories. All the items are shown in the same screen.

For example, I want the inventory to look the same as in RPG Maker VX.

I've been looking a lot for a script to achieve this, but I haven't found one and I hope someone can help me.

Thanks in advance!

Share this post


Link to post
Share on other sites

class Window_ItemList < Window_Selectable

 

def initialize(x, y, width, height)

super

@category = :none

@data = []

refresh

self.oy = 0

end

 

def include?(item)

return true if item

end

end

 

class Scene_Item < Scene_ItemBase

def start

super

create_help_window

create_item_window

end

 

def create_item_window

wy = @help_window.y + @help_window.height

wh = Graphics.height - wy

@item_window = Window_ItemList.new(0, wy, Graphics.width, wh)

@item_window.viewport = @viewport

@item_window.help_window = @help_window

@item_window.set_handler(:ok, method(:on_item_ok))

@item_window.set_handler(:cancel, method(:on_item_cancel))

@item_window.select_last

@item_window.activate

end

 

def on_item_cancel

return_scene

end

end

This is just an example. Edited by Tsukihime

Share this post


Link to post
Share on other sites
Guest
This topic is now closed to further replies.
Sign in to follow this  

  • Recently Browsing   0 members

    No registered users viewing this page.

×
Top ArrowTop Arrow Highlighted