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.

Need a couple scripts [XP]

Edit:

Ok, I've got the title screen the way I want kinda. I just need to hide the box around the commands. Anyone?

Edit: Making a second request

Ok I am using:

[rgss]#==============================================================================
# â–  New_Battle
#------------------------------------------------------------------------------
# Compiled By : Maki
#==============================================================================
# Original Scripts By : Fukuyama, and 桜雅 在土
#==============================================================================
# ¥£¥ XRXS_BP 3. Ÿ—˜ŽžHP‰ñ•œ ver.1.01 ¥£¥ by fukuyama, ÷‰ë Ý“y
# Modified by Alael
# ==========================================================
 
 
 
#==============================================================================
# ¡ Window_BattleStatus
#==============================================================================
class Window_BattleStatus < Window_Base
#--------------------------------------------------------------------------
# œ ŒöŠJƒCƒ“ƒXƒ^ƒ“ƒX•Ï”
#--------------------------------------------------------------------------
attr_accessor   :update_cp_only                   # CPƒ[ƒ^[‚݂̂̍XV
#--------------------------------------------------------------------------
# œ ƒIƒuƒWƒFƒNƒg‰Šú‰»
#--------------------------------------------------------------------------
alias xrxs_bp7_initialize initialize
def initialize
 xrxs_bp7_initialize
 # «Full-View‚̏ꍇ‚͉º“ñs‚Ì # ‚ðÁ‚µ‚Ä‚­‚¾‚³‚¢B
 #self.opacity = 0
 #self.back_opacity = 0
end
#--------------------------------------------------------------------------
# œ ƒŠƒtƒŒƒbƒVƒ…
#--------------------------------------------------------------------------
alias xrxs_bp7_refresh refresh
def refresh
 if @update_cp_only
   xrxs_bp7_refresh
   return
 end
 # •`ŽÊ‚ð‹ÖŽ~‚µ‚È‚ª‚ç–ß‚·
 @draw_ban = true
 xrxs_bp7_refresh
 # •`ŽÊ‚Ì‹ÖŽ~‚ð‰ðœ
 @draw_ban = false
 # •`ŽÊ‚ðŠJŽn
 @item_max = $game_party.actors.size
 for i in 0...$game_party.actors.size
   actor = $game_party.actors
   actor_x = i * 160 + 21
   # •àsƒLƒƒƒ‰ƒOƒ‰ƒtƒBƒbƒN‚Ì•`ŽÊ
   draw_actor_graphic(actor, actor_x - 9, 116)
   # HP/SPƒ[ƒ^[‚Ì•`ŽÊ
   draw_actor_hp_meter_line(actor, actor_x,  72, 96, 12)
   draw_actor_sp_meter_line(actor, actor_x, 104, 96, 12)
   # HP”’l‚Ì•`ŽÊ
   self.contents.font.size = 24            # HP/SP”’l‚Ì•¶Žš‚Ì‘å‚«‚³
   self.contents.font.color = actor.hp == 0 ? knockout_color :
     actor.hp <= actor.maxhp / 4 ? crisis_color : normal_color
   draw_shadow_text(actor_x-2, 58, 96, 24, actor.hp.to_s, 2)
   # SP”’l‚Ì•`ŽÊ
   self.contents.font.color = actor.sp == 0 ? knockout_color :
     actor.sp <= actor.maxsp / 4 ? crisis_color : normal_color
   draw_shadow_text(actor_x-2, 90, 96, 24, actor.sp.to_s, 2)
   # —pŒêuHPv‚Æ—pŒêuSPv‚Ì•`ŽÊ
   self.contents.font.size = 12            # —pŒêuHP/SPv‚Ì•¶Žš‚Ì‘å‚«‚³
   self.contents.font.color = system_color # —pŒêuHP/SPv‚Ì•¶Žš‚̐F
   draw_shadow_text(actor_x, 60, 96, 12, $data_system.words.hp)
   draw_shadow_text(actor_x, 92, 96, 12, $data_system.words.sp)
 
   draw_actor_state(actor, actor_x, 100)
 end
end
end
#==============================================================================
# ¡ Window_Base
#==============================================================================
class Window_Base < Window
#--------------------------------------------------------------------------
# œ HPƒ[ƒ^[ ‚Ì•`‰æ
#--------------------------------------------------------------------------
def draw_actor_hp_meter_line(actor, x, y, width = 156, height = 4)
 w = width * actor.hp / actor.maxhp
 hp_color_1 = Color.new(255,   0,   0, 192)
 hp_color_2 = Color.new(255, 255,   0, 192)
 self.contents.fill_rect(x+8, y+4, width, (height/4).floor, Color.new(0, 0, 0, 128))
 draw_line(x, y, x + w, y, hp_color_1, (height/4).floor, hp_color_2)
 x -= 1
 y += (height/4).floor
 self.contents.fill_rect(x+8, y+4, width, (height/4).ceil , Color.new(0, 0, 0, 128))
 draw_line(x, y, x + w, y, hp_color_1, (height/4).ceil , hp_color_2)
 x -= 1
 y += (height/4).ceil
 self.contents.fill_rect(x+8, y+4, width, (height/4).ceil , Color.new(0, 0, 0, 128))
 draw_line(x, y, x + w, y, hp_color_1, (height/4).ceil , hp_color_2)
 x -= 1
 y += (height/4).ceil
 self.contents.fill_rect(x+8, y+4, width, (height/4).floor, Color.new(0, 0, 0, 128))
 draw_line(x, y, x + w, y, hp_color_1, (height/4).floor, hp_color_2)
end
#--------------------------------------------------------------------------
# œ SPƒ[ƒ^[ ‚Ì•`‰æ
#--------------------------------------------------------------------------
def draw_actor_sp_meter_line(actor, x, y, width = 156, height = 4)
 w = width * actor.sp / actor.maxsp
 hp_color_1 = Color.new(  0,   0, 255, 192)
 hp_color_2 = Color.new(  0, 255, 255, 192)
 self.contents.fill_rect(x+8, y+4, width, (height/4).floor, Color.new(0, 0, 0, 128))
 draw_line(x, y, x + w, y, hp_color_1, (height/4).floor, hp_color_2)
 x -= 1
 y += (height/4).floor
 self.contents.fill_rect(x+8, y+4, width, (height/4).ceil , Color.new(0, 0, 0, 128))
 draw_line(x, y, x + w, y, hp_color_1, (height/4).ceil , hp_color_2)
 x -= 1
 y += (height/4).ceil
 self.contents.fill_rect(x+8, y+4, width, (height/4).ceil , Color.new(0, 0, 0, 128))
 draw_line(x, y, x + w, y, hp_color_1, (height/4).ceil , hp_color_2)
 x -= 1
 y += (height/4).ceil
 self.contents.fill_rect(x+8, y+4, width, (height/4).floor, Color.new(0, 0, 0, 128))
 draw_line(x, y, x + w, y, hp_color_1, (height/4).floor, hp_color_2)
end
#--------------------------------------------------------------------------
# œ ƒXƒe[ƒg‚Ì•`‰æ
#--------------------------------------------------------------------------
alias xrxs_bp7_draw_actor_state draw_actor_state
def draw_actor_state(actor, x, y, width = 120)
 xrxs_bp7_draw_actor_state(actor, x, y, width) if @draw_ban != true
end
#--------------------------------------------------------------------------
# œ HP ‚Ì•`‰æ
#--------------------------------------------------------------------------
alias xrxs_bp7_draw_actor_hp draw_actor_hp
def draw_actor_hp(actor, x, y, width = 144)
 xrxs_bp7_draw_actor_hp(actor, x, y, width) if @draw_ban != true
end
#--------------------------------------------------------------------------
# œ SP ‚Ì•`‰æ
#--------------------------------------------------------------------------
alias xrxs_bp7_draw_actor_sp draw_actor_sp
def draw_actor_sp(actor, x, y, width = 144)
 xrxs_bp7_draw_actor_sp(actor, x, y, width) if @draw_ban != true
end
end
#==============================================================================
# ž ŠO•”ƒ‰ƒCƒuƒ‰ƒŠ
#==============================================================================
class Window_Base
#--------------------------------------------------------------------------
# œ ƒ‰ƒCƒ“•`‰æ by ÷‰ë Ý“y
#--------------------------------------------------------------------------
def draw_line(start_x, start_y, end_x, end_y, start_color, width = 1, end_color = start_color)
 # •`ŽÊ‹——£‚ÌŒvŽZB‘å‚«‚ß‚É’¼ŠpŽž‚Ì’·‚³B
 distance = (start_x - end_x).abs + (start_y - end_y).abs
 # •`ŽÊŠJŽn
 if end_color == start_color
   for i in 1..distance
     x = (start_x + 1.0 * (end_x - start_x) * i / distance).to_i
     y = (start_y + 1.0 * (end_y - start_y) * i / distance).to_i
     self.contents.fill_rect(x, y, width, width, start_color)
   end
 else
   for i in 1..distance
     x = (start_x + 1.0 * (end_x - start_x) * i / distance).to_i
     y = (start_y + 1.0 * (end_y - start_y) * i / distance).to_i
     r = start_color.red   * (distance-i)/distance + end_color.red   * i/distance
     g = start_color.green * (distance-i)/distance + end_color.green * i/distance
     b = start_color.blue  * (distance-i)/distance + end_color.blue  * i/distance
     a = start_color.alpha * (distance-i)/distance + end_color.alpha * i/distance
     self.contents.fill_rect(x, y, width, width, Color.new(r, g, b, a))
   end
 end
end
 
#--------------------------------------------------------------------------
# œ ‰e•¶Žš•`‰æ by TOMY
#--------------------------------------------------------------------------
def draw_shadow_text(x, y, width, height, string, align = 0)
 # Œ³‚̐F‚ð•Û‘¶‚µ‚Ä‚¨‚­
 color = self.contents.font.color.dup
 # •Žš‚ʼne•`‰æ
 self.contents.font.color = Color.new(0, 0, 0)
 self.contents.draw_text(x + 2, y + 2, width, height, string, align)
 # Œ³‚̐F‚É–ß‚µ‚Ä•`‰æ
 self.contents.font.color = color
 self.contents.draw_text(x, y, width, height, string, align)
end
end
[/rgss]

and

[rgss]#==============================================================================
# â–  Spriteset_Battle
#------------------------------------------------------------------------------
# This class contains the set of sprites used in the Scene_Battle class, such
# as the enemies, actors, battle background, and any pictures being displayed
#==============================================================================
 
class Spriteset_Battle
#--------------------------------------------------------------------------
# ● initialize
#--------------------------------------------------------------------------
def initialize
@viewport1 = Viewport.new(0, 0, 640, 480)
@viewport2 = Viewport.new(0, 0, 640, 480)
@viewport3 = Viewport.new(0, 0, 640, 480)
@viewport4 = Viewport.new(0, 0, 640, 480)
@viewport2.z = 101
@viewport3.z = 200
@viewport4.z = 5000
@battleback_sprite = Tilemap.new(@viewport1)
@battleback_sprite.tileset = RPG::Cache.tileset($game_map.tileset_name)
for i in 0..6
autotile_name = $game_map.autotile_names
@battleback_sprite.autotiles = RPG::Cache.autotile(autotile_name)
end
@battleback_sprite.map_data = $game_map.data
@battleback_sprite.ox = $game_map.display_x / 4
@battleback_sprite.oy = $game_map.display_y / 4
@enemy_sprites = []
for enemy in $game_troop.enemies.reverse
@enemy_sprites.push(Sprite_Battler.new(@viewport1, enemy))
end
@actor_sprites = []
@actor_sprites.push(Sprite_Battler.new(@viewport2))
@actor_sprites.push(Sprite_Battler.new(@viewport2))
@actor_sprites.push(Sprite_Battler.new(@viewport2))
@actor_sprites.push(Sprite_Battler.new(@viewport2))
@weather = RPG::Weather.new(@viewport1)
@picture_sprites = []
for i in 51..100
@picture_sprites.push(Sprite_Picture.new(@viewport3,
$game_screen.pictures))
end
@timer_sprite = Sprite_Timer.new
update
end
#--------------------------------------------------------------------------
# ● Dispose the battle spriteset
#--------------------------------------------------------------------------
def dispose
@battleback_sprite.tileset.dispose
for i in 0..6
@battleback_sprite.autotiles.dispose
end
@battleback_sprite.dispose
for sprite in @enemy_sprites + @actor_sprites
sprite.dispose
end
@weather.dispose
for sprite in @picture_sprites
sprite.dispose
end
@timer_sprite.dispose
@viewport1.dispose
@viewport2.dispose
@viewport3.dispose
@viewport4.dispose
end
#--------------------------------------------------------------------------
# ● Update the battleset sprite
#--------------------------------------------------------------------------
def update
@battleback_sprite.update
@actor_sprites[0].battler = $game_party.actors[0]
@actor_sprites[1].battler = $game_party.actors[1]
@actor_sprites[2].battler = $game_party.actors[2]
@actor_sprites[3].battler = $game_party.actors[3]
for sprite in @enemy_sprites + @actor_sprites
sprite.update
end
@weather.type = $game_screen.weather_type
@weather.max = $game_screen.weather_max
@weather.update
for sprite in @picture_sprites
sprite.update
end
@timer_sprite.update
@viewport1.tone = $game_screen.tone
@viewport1.ox = $game_screen.shake
@viewport4.color = $game_screen.flash_color
@viewport1.update
@viewport2.update
@viewport4.update
end
end
 
[/rgss]

The actual ABS need a minor fix. After giving commands the names shrink. But I'd like another script to include that will change the actual monster graphics, to point to the charsets instead and animated.
 

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