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.

GTBS v1.5.1.4 - A FFT Styled Battle System (5/19/2010)

Gubid":1fzf0eqr said:
Twytchums, actually that wouldnt be hard to do.  You will have to update 2 sections of code.  First is def update_battlers(if you are using xp) or def process_battlers(vx) and find the death stuff, which adds the actor to the $game_system.tactics_dead array.  As you notice in the code when the GTBS::REMOVE_BATTLERS is true, then the battlers are added to a different thing.  There is also a if statement for Game_Enemy vs Game_Actor.  Just update the Game_Enemy method to do the Remove_Battlers function all the time.  Then update Sprite_Battler_GTBS when it checks for !battler.collapsed? and battler.dead?, and have it again, always perform the remove_battlers thing when a Game_Enemy. 
Sorry, I'm really bad with scripting...  What exactly is it that I have to do?
I can't seem to find this stuff anywhere.
 
Hey, this is going to sound like a really stupid question, but i can;t make heads or tails of the battles. i get to the point with the 6 blue squares, and when i click on them the characters get placed, but i have no idea what i do after that. if i double select one of them an image appears above it, but if i do the same with another one, it crashes. help!
 
GubiD, i was willing to make my isometric (ISO) battlegrounds with panoramas, but it doesn't works since its scrolling looks buggy... when the camera scrolls down, the panorama just shift its position, looks randonly but its not totally, there is any way to "fix" the panorama thing? (I was adding the panorama to the child map since the rootmap/mother does not show in the screen if there is a panorama...)

Twytchums":2am0df60 said:
Gubid":2am0df60 said:
Twytchums, actually that wouldnt be hard to do.  You will have to update 2 sections of code.  First is def update_battlers(if you are using xp) or def process_battlers(vx) and find the death stuff, which adds the actor to the $game_system.tactics_dead array.  As you notice in the code when the GTBS::REMOVE_BATTLERS is true, then the battlers are added to a different thing.  There is also a if statement for Game_Enemy vs Game_Actor.  Just update the Game_Enemy method to do the Remove_Battlers function all the time.  Then update Sprite_Battler_GTBS when it checks for !battler.collapsed? and battler.dead?, and have it again, always perform the remove_battlers thing when a Game_Enemy. 
Sorry, I'm really bad with scripting...  What exactly is it that I have to do?
I can't seem to find this stuff anywhere.

he actually all the points you have to take to make an script to make it all works as you want... but if you dont know how to do... its a problem...
 
you dity boy Gubid, why havent you told that the RMXP mode were actually a fucken million times better?! O.o Its awesome!!!!!!!

there is ANYWAY to do the "heigh effect" in the VX? i havent figured it out yet...  I could change to XP but there is a SINGLE VX script that "ties" me to the game =\... maybe i chang to XP =\

Forget it, ive realized how to do it actualy (those damn strange  numbered tiles)
 
Hey this script looks great, first off, but I haven't downloaded it yet because I'm at work currently. I'm just wondering, is it possible to have items that increase things like movement? (Similar to FFT's battle boots that raise the move of the person who has the item equipped by 1?) I haven't read the entire thread yet so if you answered th is already let me know.

Script's pretty cool and I'm trying to incorporate it into my game. I managed to get into a battle, I'm using the 'slime' character sets and a few others. I can more just fine, but when either the enemies or the actors go to attack, I get this error and I don't know how to fix it.

Script 'Bitmap/AnimObj' line 164: NoMethodError occurred.
Undefined method 'name for nil:NilClass

Maybe this is related or maybe not, but I just realized that while actors seem to be chosen because of the 'character' part in the database, I'm not sure how exactly enemy data(as far as the characters that show up on the map) is selected, is this explained somewhere or can someone explain this to me?
 
Hi there GubiD,

First off, absolutely fantastic script!  Fans of classic tactical games such as FFTactics and Shining Force who are fed up with the lack of innovation and depth of modern gaming have new hope because of your diligent work!

Just a simple question: Is there a way to add sound effects to the "User Animation?" Say I want to add a "grunt" sound when a goblin swings his weapon before the "clang" sound when it connects with its target (target animation).
Since all units use the same ANIM ATTACK! animation, this really isn't possible.  Thanks!
 
Silencher":2tfgwujb said:
Hey this script looks great, first off, but I haven't downloaded it yet because I'm at work currently. I'm just wondering, is it possible to have items that increase things like movement? (Similar to FFT's battle boots that raise the move of the person who has the item equipped by 1?) I haven't read the entire thread yet so if you answered th is already let me know.

Script's pretty cool and I'm trying to incorporate it into my game. I managed to get into a battle, I'm using the 'slime' character sets and a few others. I can more just fine, but when either the enemies or the actors go to attack, I get this error and I don't know how to fix it.

Script 'Bitmap/AnimObj' line 164: NoMethodError occurred.
Undefined method 'name for nil:NilClass

Maybe this is related or maybe not, but I just realized that while actors seem to be chosen because of the 'character' part in the database, I'm not sure how exactly enemy data(as far as the characters that show up on the map) is selected, is this explained somewhere or can someone explain this to me?

The enemy is explained somewhere in the script itself, dont worry about it

the boots of speed you said is possible, but you cant make him move more... the character movement is based on its class, so you need an common event that checks if someone is wearing the boots and change him to another class (same name, same atributes, just another class) with a better movement... there is the HASTE spell but I dont know how it works, same with SLOW spell, I dont know how it works XD

I remember this "problem"
Script's pretty cool and I'm trying to incorporate it into my game. I managed to get into a battle, I'm using the 'slime' character sets and a few others. I can more just fine, but when either the enemies or the actors go to attack, I get this error and I don't know how to fix it.

Script 'Bitmap/AnimObj' line 164: NoMethodError occurred.
Undefined method 'name for nil:NilClass

if im not wrong its because you forgot to "copy" the attack animation and the few others, just go on the script and change the animation for the attack, cast spell ans a few others and you migh solve it... I hope ive helped you Silencher.
 
Yeah you kind of have. Are you saying there is an animation in the demo that I should have copied into my project's animations folder? If so, the demo seems to be empty.

Besides that, where exactly is the script that I need to alter to pick the animation for when someone attacks? =\ I'm really not very script proficient so it was just a task to even get everything over into my own project.

I actually answered both of these myself. I changed the max animations to 150 and that seemed to fix it.
 
Code:
module GTBS  
  #-------------------------------------------------------------
  # Use Heal Pose?
  #-------------------------------------------------------------
  HEAL_POSE = false  
  
  #-------------------------------------------------------------
  # Anim ID for Attack/Special 1&2/Casting/Cast/Heal- Only used for Animated Battlers
  #-------------------------------------------------------------
  # All animations not listed below (Pain/Defend/Walk/Wait/Dead) are auto assigned
  ANIM_ATK = 105
  ANIM_SPEC1 = 106
  ANIM_SPEC2 = 107
  ANIM_CASTING = 108
  ANIM_CAST = 109
  ANIM_HEAL = 110
  
  #-------------------------------------------------------------
  # Doom ANIM ID
  #-------------------------------------------------------------
  DOOM_ANIM_ID = 104
  
  #-------------------------------------------------------------
  # Teleport Animation ID (used when player has teleport state
  #-------------------------------------------------------------
  TELEPORT_ANIM = 2
  
  #-------------------------------------------------------------
  # Non walking animation for all characters/enemies when still? - Must be true when anim_battler
  #-------------------------------------------------------------
  STOPPED_ANIM = true
  
  #-------------------------------------------------------------
  # Use Animated Tiles(used for move/attack/skill tiles)
  #-------------------------------------------------------------
  ANIM_TILES = false
end

in the script "GTBS_ANIMATION CONFIG"

you've only to change these ID's

  ANIM_ATK = 105
  ANIM_SPEC1 = 106
  ANIM_SPEC2 = 107
  ANIM_CASTING = 108
  ANIM_CAST = 109
  ANIM_HEAL = 110
 
Oh you posted right after I modified mine, thanks for telling me anyway maybe someone who had the same problem will get help.  I am using this script in a VX project by the way.

1. Here's something I want to do as an alternative to making individual downed sprites for everyone, I'd like when an actor or neutral dies for the cross grave tile in tile B (which is up from a bush, to the right of a barrel, to the left of a stone grave and down from a tunnel opening) to appear in place of the battler while they are dead, how could I do that?

Could I do the same thing that would be enemy specific? Or could I have enemies simply removed from the map entirely, and if so, how?

2. Have another question. I still don't really understand how the enemies' character sprites work. In particular, I'm wondering how I can use like Actor1, Actor2, etc as a character sprite for -enemies-? Can you tell me that also?

3. Lastly, I tried turning 'remove dead' to true, but when people die it still seems to search for downed battlers, which I don't have which ends my game. in GTBS_Actor/enemy death it says in the notes that that part of the code shouldn't be applicable if Remove Dead is on, but it still seems to be and it doesn't really seem like there is anything in that bit of code that searches to see if it is true or not. How can I fix this?
 
Silencher":ztlvb4qm said:
Oh you posted right after I modified mine, thanks for telling me anyway maybe someone who had the same problem will get help.  I am using this script in a VX project by the way.

1. Here's something I want to do as an alternative to making individual downed sprites for everyone, I'd like when an actor or neutral dies for the cross grave tile in tile B (which is up from a bush, to the right of a barrel, to the left of a stone grave and down from a tunnel opening) to appear in place of the battler while they are dead, how could I do that?

Could I do the same thing that would be enemy specific? Or could I have enemies simply removed from the map entirely, and if so, how?
you can, just make an entire "down_xxx" charset with crosses, one for each, so you may do an special cross for the "special" monstas.

2. Have another question. I still don't really understand how the enemies' character sprites work. In particular, I'm wondering how I can use like Actor1, Actor2, etc as a character sprite for -enemies-? Can you tell me that also?
you need to make the charset (1:1 char) with the same name of the enemy, juts it as far as i know.

3. Lastly, I tried turning 'remove dead' to true, but when people die it still seems to search for downed battlers, which I don't have which ends my game. in GTBS_Actor/enemy death it says in the notes that that part of the code shouldn't be applicable if Remove Dead is on, but it still seems to be and it doesn't really seem like there is anything in that bit of code that searches to see if it is true or not. How can I fix this?
youve found a bug, maybe in the "check" if they are dead you need to put some "if"... i will look for it..

Well... I tried to do it adding an "if $gtbs.remove_dead == false"
  #-----------------------------------------------------------
  # DownSets by Nick - create a battlername_down file for each character to display
  # other than a downed soldier.
  #-----------------------------------------------------------
  # Downsets are only used if you are not using Animated Battlers or Remove Dead
  #-----------------------------------------------------------
  def self.down_graphic(type, battler_name = "")
  if $GTBS.REMOVE_DEAD == false #added "IF" conditioner
    if FileTest.exist?("Graphics/Characters/#{battler_name}_down.png")
      return "#{battler_name}_down"
    else
      if type == "enemy" ; return "192-Down04"
      elsif type == "actor"
        # This little code gets the downset from the prefix.
        pre = battler_name.split("-")[0].to_i
        if pre >= 1 and pre <= 16 ; return "189-Down01"
        elsif pre >= 17 and pre <= 32 ; return "190-Down02"
        elsif pre >= 33 and pre <= 48 ; return "191-Down03"
        else ; return "189-Down01"
        end
      end
    end
  end
  def self.down_x(id, type = "enemy")
    # The X of the downset here. To add enemy, add below "enemy", else add below "else"
    case type
    when "enemy"
      case id
      when 5 ; r = 1
      else ; r = 0
      end
    else
      case id
      when 1 ; r = 0
      when 2 ; r = 1
      when 4 ; r = 2
      when 5 ; r = 1
      when 6 ; r = 2
      when 8 ; r = 1
      else ; r = 0
      end
    end
    return r
  end
  def self.down_y(id, type = "enemy")
    list = []
    # The Y of the downset here. To add enemy, add below "enemy", else add below "else"
    case type
    when "enemy"
      case id
      when 0 ; r = 0
      else ; r = 0
      end
    else
      case id
      when 1 ; r = 0
      when 2 ; r = 2
      when 3 ; r = 3
      when 5 ; r = 1
      when 6 ; r = 1
      when 7 ; r = 3
      when 8 ; r = 1
      else ; r = 0
      end
    end
    return r
  end
  #-----------------------------------------------------------
  # End Downsets by Nick
  #-----------------------------------------------------------
end #the new end to be added
end
and it seens to work, but I migh be forgetting something, maybe the delete char =p I dunno, GUBID HELP US, but when I started the battle just after ive positioned the chars, it just "crashed" and yelled at me he had THIS error

Code:
[b]
 Scene_Battle_TBS - line 258 - event.start
[/b]

GubiD! Ive found something that i didnt understand
Code:
  #------------------------------------------------------------
  # Check Death Action
  #------------------------------------------------------------
  # This section allows you to identify common events upon death for what map 
  # you are fighting on by the id of the actor/enemy
  def self.check_death_action(map_id, type = 0)
    case map_id
    when 1
      return {1=>6} if type == 0 #actors
      return {} #enemy death
    when 3
      return {1=>7} if type == 0 #actors
      return {36=>8}
    else
      return {} if type == 0 #actors
      return {} #enemies
    end
  end
How to use this "return" thing and what is this result in battle (in this case of the "demo")
 
you can, just make an entire "down_xxx" charset with crosses, one for each, so you may do an special cross for the "special" monstas.

This seems like a lot of effort, I'm willing to do it but there's nowhere in the script that I can just default like... 'if actor == dead return: Cross Picture' and 'if neutral == dead return: cross picture' and 'if enemy == dead remove from battle'?

you need to make the charset (1:1 char) with the same name of the enemy, juts it as far as i know.

I'm not sure what you mean by this. Do I need to copy like 'actor 1' and divide it into 6 different charsets that only show the individual characters?
 
hum... maybe not... I really dont know to be honest... I'll search and answer...

you can, just make an entire "down_xxx" charset with crosses, one for each, so you may do an special cross for the "special" monstas.

This seems like a lot of effort, I'm willing to do it but there's nowhere in the script that I can just default like... 'if actor == dead return: Cross Picture' and 'if neutral == dead return: cross picture' and 'if enemy == dead remove from battle'?

This is the only way I've realized to work

Code:
"$"+@battler_name+"_down" if dead? and !animated?

This seens to be that actually you NEED a single sprite in Battler to be you monster, and it need to have the same name as the monster has in database...


FOR THOSE WHO WERE SEARCHING FOR THE HELP WINDOW.
Yeah... I'was searching for the "problem" too... it really dont works! T_T

Code:
script Scene_Battle_TBS (VX)    
line 840    #hide help window
line 841    @windows["help"].visible = true #no diference if you change between true or false T_T

   
 
Hello GubiD!
I've been using your system for a little while now and have had no problems testing it and configuring it to my game. I've only recently come across a small problem.

I often test my game after every few updates that I do. Recently, a problem with battles occured. I changed very little from the last battle test to the current one where the problem occured.
It seems that near the start of the battle, it randomly freezes and the music changes to that of the map that called it leading me to believe the battle ended but with the battle screen still up. I retested several times and it was mostly different points where this happened within the first 3 turns of battle(1 player 1 enemy 1 player).
The little I did change was change events from "place" to "actor1" and "actor2" and had since then tried both. I tried it on a map with a parallel process and one with no events but the enemy and the neccessary placements. I added perhaps 2 skills to the weapon/skills range but other then that, nothing else has changed.

I realize my problem is somewhat vague, so if neccessary, I'll post a demo upon request.
Any help is appreciated.
 
maybe, but just maybe, you are playing with "team mode", if you are, well... team mode do changes the music at each turn, enemy turn has one music and players has another... ive turned it off in my game.
 
http://www.rmxp.org/forums/index.php?to ... 27.new#new

I'm noting this because I'm not 100% sure its just the template I'm using. But basically I made a template to do what I want (a grave that appears when the character is downed) however, it just shows a blank spot when the person is killed. You can hover over the square and it shows the right person, but there is no sprite to represent the person. I'm fairly sure its a problem with the template I made, but.. I guess we'll see.
 
i don't really understand what you just said?

I think the template is fine though, so I'm thinking there is something script related I'm not doing. Any ideas?
 
anyway, I've a question now, ive seen that when you put your target over a an impassable tile it just "jumps up" like it was a higher ground? there is or there is not any "elevation" feature in the isometric battle?
Actually you can do height management in both XP and VX.  They are both setup very closely in that respect.  The only thing that is different is that VX has to use a special tileset that is included in the demo for TileA5 which as displayed in the demo, is just numbers.  These numbers correspond to height, just like in XP.  Anyway, those same features are included in battle as on the map.

I have a question, is it possible to interact with objects on the battle and make them affect the enemy as well? Like for example, I'm standing on a cliff and there's a rock in front of me, at the bottom of the cliff there's an enemy, is it possible that I can roll the rock down at him and kill him with it?
YES!  However its a little tricky.  I dont recall which forum it was that asked, but I wrote a script so that when a switch was changed then if the enemy was in x,y location, then he would take damage etc.  There are a variety of ways to do this, most of which are completely through script.  As for your example, you know the location in which the rock will land.. so if you move to a surrounding location to the event (using 3 separate battle events) when you 'wait' there, you can choose to push the rock off.  If you do, then you can get which actor is at the bottom of the hill if any and apply x amount of damage.  I would recommend something like this..
actor = $scene.occupied_by?(x,y)
Code:
return if actor.nil?
actor.damage = 500
actor.hp -= 500
actor.pop_damage = true
At least that is probably the way I would do it. 
IT's there? Wow I might be blind, I read it over the past few days. I'll check it out again.
Yes although, a very small mention. 
[qoute]Sorry, I'm really bad with scripting...  What exactly is it that I have to do?
I can't seem to find this stuff anywhere.[/quote]
Actually i gave you everything I can do without scripting it for you.  All I can say is read the script closely in the Sprite_Battler_GTBS, Its fairly easy to understand, but if you continue to have problems, let me know.
Hey, this is going to sound like a really stupid question, but i can;t make heads or tails of the battles. i get to the point with the 6 blue squares, and when i click on them the characters get placed, but i have no idea what i do after that. if i double select one of them an image appears above it, but if i do the same with another one, it crashes. help!
Actually there was a bug with the character replacement on the XP system.  I dont believe that occurs in VX.  Anyway, when the next release comes out it will have a little more information on that.
Maybe this is related or maybe not, but I just realized that while actors seem to be chosen because of the 'character' part in the database, I'm not sure how exactly enemy data(as far as the characters that show up on the map) is selected, is this explained somewhere or can someone explain this to me?
Characters use their normal assigned sprite, however enemies use their database name with a $ on it.  So if the enemy is Slime, then the filename for their sprite would be $Slime, as is used in the demo.
[qoute]Just a simple question: Is there a way to add sound effects to the "User Animation?" Say I want to add a "grunt" sound when a goblin swings his weapon before the "clang" sound when it connects with its target (target animation).
Since all units use the same ANIM ATTACK! animation, this really isn't possible.  Thanks![/quote]
You can change what the attack animation is by updating the def animation1 method for the enemy to use its .enemy_id to determine its attack animation. Hope that makes sense.
[qoute]I'm just wondering, is it possible to have items that increase things like movement[/quote] Yes this is possible, however if you wait for a little bit, when I release my FFT Menu System (GTMenu) then it will handle all this and explain how to do it.
1. Here's something I want to do as an alternative to making individual downed sprites for everyone, I'd like when an actor or neutral dies for the cross grave tile in tile B (which is up from a bush, to the right of a barrel, to the left of a stone grave and down from a tunnel opening) to appear in place of the battler while they are dead, how could I do that?
Could I do the same thing that would be enemy specific? Or could I have enemies simply removed from the map entirely, and if so, how?
You can have the system auto return a specific name for all dead actors/enemies if desired, you simply need to update the def character_name method for the game_actor and game_enemy with something like this..
return "cross_image" if dead?
.. for enemies
return "dead_#{self.enemy_id}" if dead?
Lastly, I tried turning 'remove dead' to true, but when people die it still seems to search for downed battlers, which I don't have which ends my game. in GTBS_Actor/enemy death it says in the notes that that part of the code shouldn't be applicable if Remove Dead is on, but it still seems to be and it doesn't really seem like there is anything in that bit of code that searches to see if it is true or not. How can I fix this?
this would actually be a bug.  The likely problem is that they are now 'dead' so as such the character_name method for the battler returns their dead name.  I will correct this in the next release.
$name_down, when you select just "one" image here you select the full set, when you "drop it" like an event it should be able to select just one
He is saying that if the enemy name is slime.. then the down version of it would be $slime_down and like that if it where Frog then it would be $Frog_down.  For characters it uses the current charactername + _down.

Sorry I have been gone for awhile guys.  Been way busy at work and havent had much time to work on stuff.  Anyway, gots to run.  Later!
 
Hi there GubiD,

First off, absolutely fantastic script!  Fans of classic tactical games such as FFTactics and Shining Force who are fed up with the lack of innovation and depth of modern gaming have new hope because of your diligent work!

Just a simple question: Is there a way to add sound effects to the "User Animation?" Say I want to add a "grunt" sound when a goblin swings his weapon before the "clang" sound when it connects with its target (target animation).
Since all units use the same ANIM ATTACK! animation, this really isn't possible.  Thanks!
 

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