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.

Changing the Step Box into a Location Box

I want to know how to change the code in the RGSS so instead of the box displaying how many steps you've taken, I want it to display the current map you're on when you open up the menu. Can someone tell me what to do please?
 
yes...maybe its because you don't have SDK...
i did this: im not expert scripter, but this should do (only if you have the default menu)

#==============================================================================
# ** Window_Location
#---
class Game_Map
def name
load_data("Data/MapInfos.rxdata")[@map_id].name
end
end

class Window_Location < Window_Base
#--------------------------------------------------------------------------
# * Object Initialization
#--------------------------------------------------------------------------
def initialize
super(0, 0, 160, 95)
self.contents = Bitmap.new(width - 32, height - 32)
refresh
end
#--------------------------------------------------------------------------
# * Refresh
#--------------------------------------------------------------------------
def refresh
self.contents.clear
self.contents.font.color = system_color
self.contents.font.bold = true
self.contents.font.size = 20
self.contents.draw_text(4, 0, 120, 32, "Location")
self.contents.font.color = normal_color
self.contents.draw_text(4, 20, 400, 40, $game_map.name.to_s)
end
end

umm...try that...hope it works =)

just replace your Window_Step with the script above and in Scene_Menu replace
@steps_window = Window_Steps.new
with
@steps_window = Window_Location.new
 
I did add in the SDK, BUT I didn't replace Window_Step in the Scene_Menu.


It's OK, I decided to go with the Float Location script that displays the name of the map when you enter it. Thanks you helping me anyway =)
 

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