05-27-2005, 01:00 PM
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.
No support is given. If you are the owner of the thread, please contact administration.
okay this took like 5 minutes so, um, you know, somethin
warning message, and now because people can't figure stuff out, i made the
window follow the player, it is right above the player, soo..... ph yea you can toggle the window by pressing "Q"
in Scene_Map right under main paste:
Code:
unless $game_system.encounter_disabled
@encounter = Encounter.new(0,0,($game_map.encounter_step + 30))
@encounter.x = ($game_player.real_x - $game_map.display_x) / 4 - 19
@encounter.y = ($game_player.real_y - $game_map.display_y) / 4 - 60
end
now under Graphics.freeze (line 42) paste
Code:
if @encounter != nil
@encounter.dispose
end
right under def_update paste
Code:
if $game_system.encounter_disabled
@encounter.visible = false
else
if Input.trigger?(Input::L)
case @encounter.visible
when true
@encounter.visible = false
when false
@encounter.visible = true
end
else
if @encounter !=nil
@encounter.refresh
@encounter.x = ($game_player.real_x - $game_map.display_x) / 4 - 19
@encounter.y = ($game_player.real_y - $game_map.display_y) / 4 - 60
end
end
end
and finally make a new script and paste this in there
Code:
#=================================================
# The amazing Battle Warning thing by makeamidget
#=================================================
class Encounter < Window_Base
def initialize(x=0,y=0,width=200,height=45)
if width > 640
width = 640
end
super(x, y, width, height)
self.contents = Bitmap.new(width - 32, height - 32)
self.contents.font.name = $defaultfonttype # "Help" window font
self.contents.font.size = $defaultfontsize
self.opacity = 0#change if you want to see the box
refresh
end
def refresh
self.contents.clear
draw_encounter(0,0)
end
def draw_encounter( x=200, y=200, width = $game_map.encounter_step, height=20)
self.contents.font.color = normal_color
self.contents.font.size = 17
# if you don't want a warning message take out the next line
if $game_player.encounter_count > ($game_map.encounter_step/10)
# stop
self.contents.fill_rect(x-1, y+1, width+2,11, Color.new(0, 0, 0, 255))
w = width * $game_player.encounter_count / $game_map.encounter_step
self.contents.fill_rect(x, y+2, w,1, Color.new(0, 0, 100,255))
self.contents.fill_rect(x, y+3, w,1, Color.new(4, 4, 106, 255))
self.contents.fill_rect(x, y+4, w,1, Color.new(8, 8, 112, 255))
self.contents.fill_rect(x, y+5, w,1, Color.new(12, 12, 118, 255))
self.contents.fill_rect(x, y+6, w,1, Color.new(16, 16, 124, 255))
self.contents.fill_rect(x, y+7, w,1, Color.new(20, 20, 130, 255))
self.contents.fill_rect(x, y+8, w,1, Color.new(24, 24, 136, 255))
self.contents.fill_rect(x, y+9, w,1, Color.new(28, 28, 142, 255))
self.contents.fill_rect(x, y+10, w,1, Color.new(32, 32, 148, 255))
# if you don't want the warning message delete untill i say stop
else
#change warn to whatever you want displayed for the warning message
warn = "Warning"
cx = contents.text_size(warn).width
self.contents.draw_text((width/2) - (cx/2) +8,-6 ,width,height, warn)
end
# go ahead and stop now
end
end
theres not a wole lot of stuff here as this was a half assed commitment, the bar will only who up when the encounter rate is less than the encounter step, to take this out i put instructions on what to delete in the comments, the way the encounter rate works makes this hard to keep the bar full all the time, sometimes it will be half full or three quarters full, or somethin, its nothing bad though, so it would probobly be better that way....
any suggestions are welcome