01-07-2006, 01:00 PM (This post was last modified: 07-25-2017, 04:37 AM by DerVVulfman.)
This is a locked, single-post thread from Creation Asylum. Archived here to prevent its loss.
No support is given. If you are the owner of the thread, please contact administration.
This can be used to make either a normal command window, or one using a cursor (a pointer).
It should work for any menu.
First import this into the icons folder. (Make sure you make the background transparent)
def disable_item(index)
draw_item(index, disabled_color)
end
def update_cursor_rect
if @index < 0 or @pointer == true
self.cursor_rect.empty
return
end
x = 0
y = 32 * @index
cursor_width = self.contents.width
self.cursor_rect.set(x, y, cursor_width, 32)
end
alias :original_update :update
def update
if @pointer == true
refresh(@index)
end
original_update
end
end
Now here are the instructions -
To create a nomal menu do this-
Code:
@menu = Cursor_Command.new(width,[commands])
To create a menu using the pointer (cursor) do this-
Code:
@menu = Cursor_Command.new(width,[commands],true)
If you get an error tell me immediately, it's a simple script so if it has any errors, it shouldn't be too hard to fix