SBABS Squad Based Action Battle System
Ver 3.4
by Jaime 'Near Fantastica' Webster Not DerVVulfman
Introduction
This is a version 3 of Near Fantastica's ABS system. There is a lot of features in this battle system, and Near Fantastica did his best to outline it within the topic he originally posted.
"I will say this I built it and I will have to spend a few months testing everything it can do..." - Near Fantastica
Features
Status Effects
Enemy Ai
Squad Based Movement
Ally Ai
Range Weapons
Ammo System
Range Spells
By the poster
I didn't create the script, and as of now the links that Near Fantastica put up are down (and he can't get to them) and his RMXP system is down. Given that he posted the original (though broken) demo links here, there should be no problem to post the script.
However as I didn't create the script, I cannot offer support.
Instructions
Paste the scripts below Scene_Debug or above Main (your choice), import your 'Arrow' and 'Magic Balls' graphics into the Graphics\Characters directory (see the Graphics section below), and create your enemy events as directed.
How to Battle / Controls
[codebox] E ? Change Lead Forward
R ? Change Lead Backwards
T ? Waits Leader
Y ? Waits Allies
U ? Gathers Allies
I ? Dash
O ? Sneak
P ? Toggle Hud
F ? Melee Attack
G ? Range Attack
H ? Skill Key 1
J ? Skill Key 2
K ? Skill Key 3
L ? Skill Key 4
N ? Wide Follow
M ? Close Follow[/codebox]
Enemy A.I / Added to the Enemy Events
[codebox]Name
Name Of the Enemy in The Data Base
------------------------------------------------------------------------
Behavior
Passive = 0 ? The Event (Enemy) will only attack when attacked
Aggressive = 1 ? The Event will attack when one of its Detection level are set true
Linking = 2 ? Event will only attack when another Event is attacked with in its Detection level
Aggressive Linking = 3 ? Event will attack when either Aggressive or Linking is true
------------------------------------------------------------------------
Detection
Sound = range ? The range of sound the enemy can hear inactive if set to zero
Sight = range ? The range of sightthe enemy can see inactive if set to zero
------------------------------------------------------------------------
Aggressiveness
Aggressiveness = Level ? The high number the less Aggressive the Event
------------------------------------------------------------------------
Movement
Speed = Level ? The movment Speed of the event when engaged
Frequency = Level ? The movment Frequency of the event when engaged
------------------------------------------------------------------------
Trigger
Erased = 0 ? The event will be erased on death
Switch = 1 ? The event will be trigger Switch[ID] on death
Varible = 2 ? The event will be set the Varible[ID] = VALUE on death
Local Switch = 3 ? The event will trigger Local_Switch[ID] on death[/codebox]
When done it should look like this in the EVENT COMMAND list...
Quote:@>Comment: ABS Event Command List
@>Comment: Name Ghost
@>Comment: Behavior 1
@>Comment: Sound 2
@>Comment: Sight 5
@>Comment: Aggressiveness 1
@>Comment: Speed 4
@>Comment: Frequency 5
@>Comment: Trigger 3 1
ABS CONSTANTS
If you Want your actors to change to a different sprite when they die Then use Dead Display....
If you Setup range attacks you need to make a ELEMENT called Ranged and enter the ID of that ELEMENT into the RANGE_ELEMENT_ID...
If you Setup range weapons you need to setup the RANGE_DISPLAY...
[codebox]#======================================
# ? ABS CONSTANTS
#======================================
# ? DEAD_DISPLAY is the sprite that is displayed when an actor is dead
# ? DEAD_DISPLAY[Data_Base_Actor_ID] = ["Character_Set_Name", X of sprite, Y of sprite]
#---------------------------------------------------------------------------
$DEAD_DISPLAY = {}
$DEAD_DISPLAY[1] = ["189-Down01", 2, 0] #Actor 1
$DEAD_DISPLAY[2] = ["189-Down01", 6, 1] #Actor 2
$DEAD_DISPLAY[7] = ["190-Down02", 8, 0] #Actor 7
$DEAD_DISPLAY[8] = ["191-Down03", 4, 1] #Actor 8
#---------------------------------------------------------------------------
# ? RANGE_ELEMENT_ID is which element the range is set to
#---------------------------------------------------------------------------
$RANGE_ELEMENT_ID = 17 #Element 17
#---------------------------------------------------------------------------
# ? RANGE_DISPLAY is the setup for range weapons
# ? RANGE_DISPLAY[Data_Base_Weapon_ID] =
# ["Character_Set_Name", New Animation Id, Item Id of Ammo]
#---------------------------------------------------------------------------
$RANGE_DISPLAY = {}
$RANGE_DISPLAY[17] = ["Arrow", 4, 33] # Weapon 17[/codebox]
NOTE BY DERVVULFMAN:
As you can see, you tell the system that the Ranged Weapon uses the 'Arrow' graphic in the...
[coded]$RANGE_DISPLAY[17] = ["Arrow", 4, 33][/coded]... line of code.
Near Fantastica left out of the instructions that you have to edit the 2nd page of the script to name the Ranged MAGIC graphic (aka 'Magic Balls'). The statement that identifies the 'Magic Balls' graphic is on or around line 612, in the refresh method of the Game_Ranged class:
[codebox] def refresh(event)
moveto(event.x, event.y)
case @type
when "Magic"
@character_name = "Magic Balls.png"
when "Weapon"
display = $RANGE_DISPLAY[@attack]
@character_name = display[0]
end
end[/codebox] The .png extension is not required. It coulda been merely "Magic Balls" and it woulda worked fine. :)
Ally Ai:
The ally Ai works but its not the smartest things I have ever built... That being said you cant change it very much but you cant turn it off and on... set the flag to True or false
[coded]$ABS.set_ally_ai( flag )[/coded]
HUD:
[coded]$ABS.hud_pc[/coded]
If true the Player has control of the HUD with the [P] key by default...
If false the Developer has control of the HUD
[coded]$ABS.hud[/coded]Sets the State of the HUD when the Developer has control...
Graphics:
You Need 2 graphic files to use this ABS by default they can be found below: "Arrow" and "Magic Balls"
Known Problems:
Early versions of RMXP, and Japanese versions used an older RGSS10##.dll that caused their games to crash on start up.
EDIT by DerVVulfman:
The system was originally developed when RMXP was not available for the English/Western world, and as such required the use of the $defaultfonttype and $defaultfontsize values (very popular globals some years ago). As we all now use the Officially Distributed English Versions, I 'commented' these lines out to prevent problems. ;)
Credit
Prexus - Thanks for the wonderful graphics
Cybersam - Thanks for the Keyboard Script