The RPG Maker Resource Kit

RMRK RPG Maker Creation => Requests => Script Request => Topic started by: joy on July 13, 2009, 05:16:40 AM

Title: [REQUEST] Mod to DBS, add states to mob select, actor graphics to battle process
Post by: joy on July 13, 2009, 05:16:40 AM
<DBS Mod for mob state icons, damage pops and actor graphics at processing>
AKA Joy's never satisfied.
<07-13-2009>




Summary
Alrighty..hate to ask for more scripting help, but the more I look at this DBS the more I'd like to improve it. What I need done is a bit of reshuffling (which in a pinch I could do on my own), and a few new features to the DBS (which I'm nowhere near decent enough to do).

The first and hopefully easiest bit is just adding state icons to the mob targeting screen, I'm using Zifee's icon animation in the main battle window to cycle through multiple states and would like this to work in this instance as well, but it's not a huge priority, just icons will work if it has to.

Second, and there is a script for this in it's basic form by Vixotic on Rpgmakervx.net. However, it will not work on it's own with the third bit I'll explain in a bit. I need a basic damage/healing pop-up for both mobs and actors (explained more in the next paragraph). Just a number pop up with basic healing or damage color ability.

The third bit involves a major change to the battle processing window (where battle info messages appear with damage, skills, ect.). I'd like to add a window including the actor battlefaces (from a script Moogle Warrior did for me) in a row where the top of the battle message window was, also shortening the info window to two lines. The battle faces would need to be where the aforementioned damage pop-up for actors would show up on the approriate actor. I would also like the functionality to flash the image when that actor is hit or attacks and drop the opacity when the actor has fallen. This window would only be active during damage/skill processing.

Let me know if anyone might be willing to give this a shot, I think it would really add some shine to the battle system in OotM.

Features Desired

Mockups
(https://rmrk.net/proxy.php?request=http%3A%2F%2Fimg.photobucket.com%2Falbums%2Fv648%2Fjoymason%2Frpgmaker%2FProject%2FScreenBattle-08.png&hash=8ca30a4b2a47b138e1f073938664df0908df64b9)
How my main screen currently looks. I'm using zifee's icon animation and a custom snippet Moogle Warrior whipped up for the face display, included below images.

(https://rmrk.net/proxy.php?request=http%3A%2F%2Fimg.photobucket.com%2Falbums%2Fv648%2Fjoymason%2Frpgmaker%2FProject%2FBattleMock-02.png&hash=d87f9fcc8cc4a3d04f64227828ae7e432976bc15)
A mock-up of how I'd like the select target screen to look, only change here is that it displays the mob's status effects.

(https://rmrk.net/proxy.php?request=http%3A%2F%2Fimg.photobucket.com%2Falbums%2Fv648%2Fjoymason%2Frpgmaker%2FProject%2FBattleMock-01.png&hash=46d5a133e2969ad794b415f5077fb2c004e34134)
The big one, this illustrates the kind of setup I'd like, with damage/healing pops on both mobs battlers and on the correct face for actors. The battle info window would be reduced to two lines.

Current Scripts

[spoiler=Animated Icons by Ziifee]=begin ************************************************************************
  * State Icon Animation Ver2.00
      Actor states will animate and cycle through multiple icons rather
      than display a limited amount.
     
      Script by ziifee
=end # ************************************************************************

module StateAnime
  # * Settings
  NOR = 0             # "Normal" state icon. Use icon index number from Iconset.
  SPE = 50            # Icon change speed. (1 second = 60)
end

#==============================================================================
# ? StateIcons
#==============================================================================

class StateIcons
  #--------------------------------------------------------------------------
  # ? ??????????
  #--------------------------------------------------------------------------
  attr_reader   :x                        # X ??
  attr_reader   :y                        # Y ??
  attr_reader   :bitmap                   # ?????? (??????)
  #--------------------------------------------------------------------------
  # ? ?????????
  #--------------------------------------------------------------------------
  def initialize(icons, x, y, bitmap)
    @icons  = icons.empty? ? [0] : icons
    @x , @y = x , y
    @bitmap = bitmap
    @index  = 0
  end
  #--------------------------------------------------------------------------
  # ? ?????????????????
  #--------------------------------------------------------------------------
  def change?
    return true if @icons.size > 1
    return false
  end
  #--------------------------------------------------------------------------
  # ? ???????
  #--------------------------------------------------------------------------
  def icon
    icon = @icons[@index]
    @index = (@index + 1) % @icons.size
    return icon
  end
  #--------------------------------------------------------------------------
  # ? ??
  #--------------------------------------------------------------------------
  def dispose
    @bitmap.dispose
  end
end

#==============================================================================
# ? Window_Base
#==============================================================================

class Window_Base
  #--------------------------------------------------------------------------
  # ? ?????????
  #--------------------------------------------------------------------------
  alias :stateanime_initialize :initialize
  def initialize(x, y, width, height)
    stateanime_initialize(x, y, width, height)
    @stateanime_new   = true
    @stateanime_set   = []
    @stateanime_count = 0
  end
  #--------------------------------------------------------------------------
  # ? ??
  #--------------------------------------------------------------------------
  alias :stateanime_dispose :dispose
  def dispose
    stateanime_dispose
    for state in @stateanime_set do state.dispose end
  end
  #--------------------------------------------------------------------------
  # ? ???????????
  #--------------------------------------------------------------------------
  def clear_stateanime
    for state in @stateanime_set do state.dispose end
    @stateanime_new   = false
    @stateanime_set   = []
    @stateanime_count = 0
  end
  #--------------------------------------------------------------------------
  # ? ??????????????
  #     obj : ???????????????
  #--------------------------------------------------------------------------
  def draw_stateanime(obj, setting = false)
    return if not obj.change? and not setting
    self.contents.clear_rect(obj.x, obj.y, 24, 24)
    self.contents.blt(obj.x, obj.y, obj.bitmap, Rect.new(0, 0, 24, 24))
    draw_icon(obj.icon, obj.x, obj.y)
  end
  #--------------------------------------------------------------------------
  # ? ??????
  #--------------------------------------------------------------------------
  alias :stateanime_update :update
  def update
    stateanime_update
    unless @stateanime_set.empty?
      @stateanime_count += 1
      if @stateanime_count % StateAnime::SPE == 0
        @stateanime_new = true unless @stateanime_new
        for obj in @stateanime_set do draw_stateanime(obj) end
      end
    end
  end
  #--------------------------------------------------------------------------
  # ? ??????? ??
  #--------------------------------------------------------------------------
  def draw_actor_state(actor, x, y, dummy_width = 24)
    clear_stateanime if @stateanime_new
    icons = []
    for state in actor.states
      icons.push(state.icon_index) if state.icon_index > 0
    end
    if icons.empty?
      return if StateAnime::NOR <= 0 # ? ????????
      icons.push(StateAnime::NOR)
    end
    icons.uniq!
    bitmap   = Bitmap.new(24, 24)
    src_rect = Rect.new(x, y, 24, 24)
    bitmap.blt(0, 0, self.contents, src_rect)
    obj = StateIcons.new(icons, x, y, bitmap)
    @stateanime_set.push(obj)
    draw_stateanime(obj, true)
  end
end
[/spoiler]

[spoiler=Custom Battle Faces by Moogle Warrior]#==============================================================================
# Extremely Specialized Battle Face Script, by Moogle Warrior
#------------------------------------------------------------------------------
# This script adds character face graphics to Window_BattleStatus, at the
# cost of the status display.
#
# To use, simply install the script under Materials, and place character
# face images (at 112 x 24 or less, though it won't get cut off if they're
# bigger) in a subfolder in "Graphics" (named "Battle Faces" by default).
# To change the name of the folder to check, see line 50.
#
# Image names should be a three-digit number corresponding to the character's
# ID in the database (i.e. "001.png" for the first database slot).
#
# NOTE: The script will return an error if it can't find the requested image.
# This is normal RGSS behavior. Please make sure images are in their
# proper place before testing! wink.gif
#==============================================================================
class Window_BattleStatus
def draw_item(index)
rect = item_rect(index)
rect.x += 4
rect.width -= 8
self.contents.clear_rect(rect)
self.contents.font.color = normal_color
actor = $game_party.members[index]
draw_actor_bface(actor.id, 0, rect.y)
draw_actor_name(actor, 142, rect.y)
    draw_actor_state(actor, 114, rect.y, 48)
draw_actor_hp(actor, 210, rect.y, 90)
draw_actor_mp(actor, 310, rect.y, 70)
end
def draw_actor_bface(id, x, y)
bitmap = Cache.bface(id)
self.contents.blt(x, y, bitmap, bitmap.rect)
end
end
# Slight cache extension
module Cache
def self.id_to_name(id)
if id < 10
filename = "00" + id.to_s
elsif id < 100
filename = "0" + id.to_s
end
return filename
end
def self.bface(id)
filename = id_to_name(id)
# The directory in which the face graphics are stored
load_bitmap("Graphics/Battle Faces/", filename)
end
end
[/spoiler]

Games its been in




Did you search?
Yup

Where did you search?

What did you search for?
Title: Re: [REQUEST] Mod to DBS, add states to mob select, actor graphics to battle process
Post by: modern algebra on July 13, 2009, 12:56:27 PM
As much as I generally dislike battle systems, I think I will do this, but maybe only in parts. I'm going away Wednesday, so I might not finish.
Title: Re: [REQUEST] Mod to DBS, add states to mob select, actor graphics to battle process
Post by: joy on July 13, 2009, 03:02:10 PM
Thank you so much! just let me know if you need any other information from me.

I need to add a cameo for you in OotM...
Title: Re: [REQUEST] Mod to DBS, add states to mob select, actor graphics to battle process
Post by: modern algebra on July 13, 2009, 08:42:59 PM
haha, not at all :P

Can you post in this topic on Sunday so that I can remember to do this once I get back?
Title: Re: [REQUEST] Mod to DBS, add states to mob select, actor graphics to battle process
Post by: joy on July 13, 2009, 09:13:48 PM
Can do!
Title: Re: [REQUEST] Mod to DBS, add states to mob select, actor graphics to battle process
Post by: modern algebra on July 13, 2009, 09:28:27 PM
Alright, here is the Enemy States script: http://rmrk.net/index.php/topic,33840.0.html

If you want them to be private, just ask. I will usually only take a request if I can release it publicly however. If you would like it to be private, then I will take it down and you can still use it, but I probably won't fulfill the rest of the request.
Title: Re: [REQUEST] Mod to DBS, add states to mob select, actor graphics to battle process
Post by: joy on July 13, 2009, 09:47:47 PM
Nah, I'm not greedy, anyone who wants to can use this stuff so long as it's okay with you.

Tried it out..works like a damned charm, even the animation is perfect. You as -so- the man.
Title: Re: [REQUEST] Mod to DBS, add states to mob select, actor graphics to battle process
Post by: modern algebra on July 14, 2009, 02:32:04 AM
Thanks, I'm glad it worked. It was the easy part of the request :)
Title: Re: [REQUEST] Mod to DBS, add states to mob select, actor graphics to battle process
Post by: joy on July 19, 2009, 03:15:00 PM
It is now Sunday so I'm posting in here as requested.

Oh..and I realized I was a little vague on the damage update. If possible I'd like the numerical data to only show as a damage pop up and get rid of the whole "Actor01 did xxx damage" in the message window. Seems a little redundant.
Title: Re: [REQUEST] Mod to DBS, add states to mob select, actor graphics to battle process
Post by: modern algebra on July 23, 2009, 01:25:42 AM
Alright, thanks for the reminder. I've started working on them but I also have a couple other projects on the go, so I might be a little slow. Hopefully you should see phase 1 by next week.
Title: Re: [REQUEST] Mod to DBS, add states to mob select, actor graphics to battle process
Post by: joy on July 23, 2009, 01:27:58 AM
Totally awesome. Thanks again for taking this man.
Title: Re: [REQUEST] Mod to DBS, add states to mob select, actor graphics to battle process
Post by: modern algebra on August 01, 2009, 12:04:16 AM
Hey joy, sorry for taking so long with this request. I just finished a major project, however, meaning I only have one other major scripting project ahead of me that will take up my time, and part of that is making a damage popup, so that should be done soon.

That being said, my aunt has fallen sick, so I wont be working on anything for the next few days while I go up to visit her.
Title: Re: [REQUEST] Mod to DBS, add states to mob select, actor graphics to battle process
Post by: joy on August 01, 2009, 12:52:23 AM
Not an issue man, I know these things come up.

Hope your aunt gets better.
Title: Re: [REQUEST] Mod to DBS, add states to mob select, actor graphics to battle process
Post by: modern algebra on August 14, 2009, 03:48:33 AM
Damage Popup script is now done - http://rmrk.net/index.php/topic,34323.0.html

When I make the rest of your request, I will make sure that it is compatible and shows up on the actor faces.
Title: Re: [REQUEST] Mod to DBS, add states to mob select, actor graphics to battle process
Post by: joy on October 17, 2009, 06:24:41 PM
Whee..bump

Getting something cool ready for the forum...any chance the last bit of this might happen?
Title: Re: [REQUEST] Mod to DBS, add states to mob select, actor graphics to battle process
Post by: modern algebra on October 17, 2009, 06:28:09 PM
Shoot, I forgot again. If I can find the time, I'll try to start writing it today.
Title: Re: [REQUEST] Mod to DBS, add states to mob select, actor graphics to battle process
Post by: joy on November 06, 2009, 07:29:29 PM
Hey Mod, I ran into a lil problem when implementing your ATS. Figured I'd post it here in case it'd be easier to remedy it with the last bit of this script or not..

Anyways, the issue is that I've resized my default textboxes to be smaller than usual, and that has affected battle message size as well:

(https://rmrk.net/proxy.php?request=http%3A%2F%2Fimg.photobucket.com%2Falbums%2Fv648%2Fjoymason%2Frpgmaker%2FProject%2FTextProb-01.png&hash=4d1abea4d6d8485f78708ce88693317296fd1187)
How the text boxes look normally.

(https://rmrk.net/proxy.php?request=http%3A%2F%2Fimg.photobucket.com%2Falbums%2Fv648%2Fjoymason%2Frpgmaker%2FProject%2FTextProb-02.png&hash=2366c7b75c60adbe891c486f6256175e9443a9ee)
What happens to battle message, doesn't look too nice since my backgrounds end at the normal window height.

Just wondering what might fix this.
Title: Re: [REQUEST] Mod to DBS, add states to mob select, actor graphics to battle process
Post by: joy on November 24, 2009, 04:30:06 PM
Just checking in. Wanting to put out a technical demo here pretty soon, just need this last bit on the scripting side.
Title: Re: [REQUEST] Mod to DBS, add states to mob select, actor graphics to battle process
Post by: modern algebra on December 09, 2009, 03:19:02 AM
OK, I'm sorry I'm so tardy. I haven't forgotten about you. I'm going away until the 18, though, but I will do this edit before Christmas. If I don't, you can scold me. Again, really sorry about the tardiness of all this.
Title: Re: [REQUEST] Mod to DBS, add states to mob select, actor graphics to battle process
Post by: joy on December 09, 2009, 03:25:51 AM
It's alright, it's a fairly minor thing compared to what you've already done for the project. I'll be releasing a tech demo soonish, kinda a christmas gift to who've been waiting on this project.
Title: Re: [REQUEST] Mod to DBS, add states to mob select, actor graphics to battle process
Post by: joy on September 21, 2010, 03:33:58 AM
Any chance of the last part happening? trying to reboot this project and get out a tech demo.
Title: Re: [REQUEST] Mod to DBS, add states to mob select, actor graphics to battle process
Post by: modern algebra on September 21, 2010, 10:34:21 PM
Sure. I thought you were gone so I let it go, but I will get back to work on it now that you're back. Hopefully I can get it done tomorrow. Otherwise, probably not until the weekend.
Title: Re: [REQUEST] Mod to DBS, add states to mob select, actor graphics to battle process
Post by: joy on October 02, 2010, 04:18:18 PM
Any update on this?