Selected Menu Commands Displayed as a Different Colour

Hey all,

I was wondering if there'd be any way to display selected menu commands in a different colour than normal. For example:

 Option 1

-Option 2

 Option 3

(option 2 is selected)

The only real customization I'd like to have is just being able to adjust the colour quickly. I think the request is rather simple to explain.

Any and all help is appreciated!
Cheers~
try

Code:
module COMMAND  COLOR = Color.new(R,G,B,A) #set RGBA to what you wantendclass Window_Command  #OVERRIDES draw_item  def draw_item(index)    if current_symbol == @list[index][:symbol]      contents.font.color.set(COMMAND::COLOR)    else      change_color(normal_color, command_enabled?(index))          end    draw_text(item_rect_for_text(index), command_name(index), alignment)  end  def update_cursor    super    refresh  endend
this should work for any command window unless that window defines it's own draw_item
Hm, doesn't seem to do anything, even on a project with no custom scripts. Thanks for trying though. ;D
No, not working for me either. I think it's because draw_item is called initially, but the window is not constantly refreshed, so draw_item is not called every time you move the cursor.


I think the command needs to be redrawn when the cursor moves, but the PREVIOUS command also needs to be redrawn (so it goes back to the default colour)
@Shaz - oh... w8... I think I added a refresh call to the update cursor method when I used this... w8


EDIT: I updated the post above, defined update_cursor for window command and made it call refresh
There we have it! Now I just to find a way for this to work with YEA's Command Window Icons. Shouldn't be too tedious. 
Do you have a link to the script (non-dropbox, I can't seem to access his dropbox links here)? I can take a look at his script... 🙂
I got it to work, thanks though!
I just gotta look into how to make it show a different colour when options are disabled now. 

Edit:

Fun story. I made an accident when making the conditions, and now icons only display when the option is selected. I actually quite like it. 
module COMMAND


COLOR = Color.new(R,G,B,A) #set RGBA to what you want


COLOR_DISABLED = Color.new(R,G,B,A) #set RGBA to what you want


end


class Window_Command


#OVERRIDES draw_item


def draw_item(index)


if current_symbol == @list[index][:symbol]


if command_enabled?(index)


contents.font.color.set(COMMAND::COLOR)


else


contents.font.color.set(COMMAND::COLOR_DISABLED)


end


else


change_color(normal_color, command_enabled?(index))


end


draw_text(item_rect_for_text(index), command_name(index), alignment)


end


def update_cursor


super


refresh


end


end
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/selected-menu-commands-displayed-as-a-different-colour.21766/