Jump to content

Recommended Posts

Interesting idea, Jacquerel, but I think I'll just restore altered parts of the script to their original state and stick to it. It's imperfect with these respawning enemies, but I checked SAS and however tempting it seems to be, it doesn't support ranged weapons and items usable as weapons or in the field - at least the current version does, so it's completely useless to me, despite its admirable simplicity and effectiveness. I'm pretty advanced with my project, more advanced than with anything I've ever worked on by now, so major changes in aspects as crucial as combat system are off the table. Besides, in my project enemies drop no items, it's just that it's not very player-friendly to have respawning enemies placed near passages to other maps, and make player fight them immediately as he reenters the map.

But thanks for trying to help, I appreciate it. I really do :)

 

Another question: is it possible to make some tiles impenetrable by projectiles? Shooting through walls, cabinets, columns and other stuff that's supposed to block bullets is ridiculous and bothers me quite a lot.

Edited by Grim Tuesday

Share this post


Link to post
Share on other sites

@Grim: I managed to make things through in vlads by adding a move route of 37 before the trajectory, maybe this can be done a similar way?

 

A tip, press ctrl + F in the scripts for this integer.

RPG::MoveCommand.new

Then just dig around and find where the paths are.

 

At the begining of each patch, add this

	    RPG::MoveCommand.new(37),

On top of what may look like this.

	    RPG::MoveCommand.new(12),
    RPG::MoveCommand.new(12),
    RPG::MoveCommand.new(12),
    RPG::MoveCommand.new(12),
    RPG::MoveCommand.new(12),
    RPG::MoveCommand.new(12),
    RPG::MoveCommand.new(10),
    RPG::MoveCommand.new(10),
    RPG::MoveCommand.new(10),
    RPG::MoveCommand.new(10),
    RPG::MoveCommand.new(10),
    RPG::MoveCommand.new(10),
    RPG::MoveCommand.new(10),
    RPG::MoveCommand.new(10),
    RPG::MoveCommand.new(10),
    RPG::MoveCommand.new(10),
    RPG::MoveCommand.new(10),
    RPG::MoveCommand.new()]

I wish you luck. Keep in mind, this may be wrong since I'm going by my experience with Vlads ABS.

Share this post


Link to post
Share on other sites
I have a question, err, is there a way to make that when an enemy die, it doesn't actually fade, but instead it activates an self-switch?

 

 

@ RaiMaker

 

in my project I did exactly that

(because I wanted to change the enemy graphic to a defeated enemy graphic

and because I wanted to be able to pic up trophies upon the enemy)

 

1) you go to execute_enemy_defeated_process (should be in line 5437)

 

2) and add anywhere $game_self_switches[[$game_map.map_id, self.id, "B"]] = true in the definition

 

however there is a bug: if you go to another map and return to the map where you killed the enemy

you can hit the event a few more times although it's dead. maybe someone could fix this

 

 

Nobody has a solution for this problem ?

Share this post


Link to post
Share on other sites

http://forums.rpgmakerweb.com/index.php?/topic/14218-mordor-3/

 

This is an ongoing project using the Xas .5 Hero system for RPG Maker VX Ace.

 

I have spent quite a few months working with and tweaking the scripts.  While they are a bit difficult to understand, once you understand the contruction and relationships it gets much easier.

 

 

 

 

 

Another question: is it possible to make some tiles impenetrable by projectiles? Shooting through walls, cabinets, columns and other stuff that's supposed to block bullets is ridiculous and bothers me quite a lot.

 

Yes: I controlled this more by the behavior of the projectile than the terrain.  My characters projectiles do not go through walls while the enemies do.  (This is for game play purposes).

 

Why does my projectile not fire through a wall?  Because it has this command in the tool

move forward

move forward

move forward

move forward

self.erase

 

Make sure to Check the box: Skip if cannot move

 

This means the projectile will move forward until it either runs out of move commands OR when it hits a wall it will be unable to move so it will self.erase

 

 

 

 

 

 

I have a question, err, is there a way to make that when an enemy die, it doesn't actually fade, but instead it activates an self-switch?

 

Yes: The enemy should contain this  Note: <Active Switch = 105>

The number is the switch to activate upon death

 

*That would be a regular switch not necessarily a self, but that switch can trigger  any event

Edited by mordor

Share this post


Link to post
Share on other sites

I know this question might be noob but could someone please tell me how to create a fully functional skill in XAS please? I've been reading tutorials on xasabs.wordpress but I just couldn't understand anything, it seems as if he is working on a different script and not XAS itself, thanks for your help

 

http://www.youtube.com/watch?v=mpWZ76FFSxg&feature=youtu.be

 

This is one of the more difficult tasks.  However, the complexity allows for extremely powerful programming.  You can link skills together or make projectiles that bounce, explode, split apart, heal, add states, create area of effect, movement path, speed etc.

 

There is a designated map called "Tool".  It is tied together with the "Skill" database.

 

So skill #1 in the database will automatically correlate to Event ID #1 on the tool map.

This can be changed by a note tag on the skill database <Event ID = 39> (Uses Tool ID 39 instead)

 

Consider the "Tool" the projectile.  It controls the sounds effect, graphic, speed, & movement.

Consider the "Skill" additional settings.  (Mana consumption, casting time, 8 direction attack etc)

 

Tool movement commands (Example)

Script: touch_attack(true)       :  This script activates touch attack which means

Sound Effect                              if you touch the projectile or mob it will be viewed as a hit

Animation

1 Step Forward                       : The movement of the projectile (Just straight forward for a simple fireball etc)

1 Step Forward

1 Step Forward

Self.erase                               : This is an important command which erases the projectile

Edited by mordor

Share this post


Link to post
Share on other sites

Tools can also be things like potions.

 

Tool ID 8: This tool only contains the animation to be used when a potion is used.

Skill  ID 8:

<Ally Damage>
<User Invincible>                : can not take harm
<Piercing>
<Sunflag = 55>
<Duration = 60>                 : time to use
<Pose = _Item>                  : image "pose" while using item
<Area = SQUARE>             : effect area
<Range = 2>
<Target Invunerable = 8>   : immunity (I set this very low so you can't be invincible spamming potions)
<Item Cost = 1>                  : item consumption
<Impact Time  = 40>
<Ignore Knockback>          : disable the ability to be pushed back tiles while using

 

If you want to modify the potions affect it should be done in the Skills Damage area.  Set it to HP Recover and the amount of healing.

 

*** I removed potions from my game and replaced them with just Heal / Mana Restore skill hotkeys.  This way they never need to be selected they are always available via hot key.

 

*** Healing Skill Calculation

a.mat * 0.4 + v[41]

Variance 20 Critical Yes

 

This means the skill will heal more based on your magic attack.  It will also add Variable 41 which is a custom bonus healing skill.

You will do within +-20% of the total and it can crit.

Share this post


Link to post
Share on other sites

VX Mods to XAS Hero .5+  ( This is NOT a hotkey script)  This is modifying the original code to encode input keys

directly into the game.  This is just adding input triggers that already existed in the code.  I just specified which key would

perform which skill.

 

 

XAS

Module XAS Button

#VX Mod Hotkey Heal F5 (Skill 27) --------------------------Sets F5 to HEAL
  HEAL = Input::F5

 

 

 

class Game_Player < Game_Character
  include XAS_BUTTON
 
  #--------------------------------------------------------------------------
  # â— Update Action Command
  #--------------------------------------------------------------------------  
  def update_action_command
      update_check_battler_equipment if can_check_battler_equipment?
      update_dash_button
      update_auto_target_shoot
      update_combo_time
      update_action_1_button
      update_action_2_button
      #VX Mod
      update_heal #------------------------------Update process for all hot keys
      update_syphon
      update_sleep
      update_slow
      update_teleport
      update_skill_button
      update_item_button
      update_change_leader_button
      update_charge_button
  end

 

 

 
  # VX Mod: Check for Trigger F5 (Heal Skill ID 27)
  def update_heal
      if Input.trigger?(HEAL) #-------------------Use skill HEAL which is ID 27 as indicated below
        action_id = 27
        shoot(action_id)
      end         
      update_shield_button
    end


VX Mod Crit DMG:  The original calculation was dmg *3.  You can enter any custom formula you want.

* Variable 20 just gets updated with the luk stat every time you enter town.  The correct foruma would be to use the

actors luk stat directly.  I don't really code so I'm not sure how to enter it.  (  self.luk ) will result in the enemies stat not the player.

 

Game Battler

 

#VX Mod - Critical Dmg Formula + (Luck / 4)
  def apply_critical(damage)
    damage += rand($game_variables[20]) / 4
  end


 

 

 

 

 

XAS - This is the "Basic dmg calculation only

#1: Evasion was removed from the .5 version.  I created a simple forumla that if the Actors AGI

was higher than a random comparison vs the enemies agility the player evades.  In that case the char is invul for .5 second and the dmg calcuation will not occur.

 

#2:  The original dmg formula had no variance ATK x 4 - Enemy DEF x 2.

damage = ((attacker.battler.atk / 1.5 + rand(attacker.battler.atk) / 5) - (self.battler.def / 2)).truncate

This formula does 66% of your ATK + a random amount of your attack  / 5

It then subtracts the enemies def x2.

 

The result is just less than 1 dmg point per ATK in comparison to the mob.

 

#3: There was no minimum dmg in the original formula

  damage = (attacker.battler.atk / 10).truncate if damage < (attacker.battler.atk / 10)

This formula ensures a mob with 400 attack will do at minimum 40 dmg

 

 

# â— Execute Attack Damage
 #--------------------------------------------------------------------------       
 def execute_attack_damage(attacker)
     if self.battler.agi > (rand(attacker.battler.agi) * 10)
        self.battler.invunerable_duration = 30
        self.battler.result.missed = true
        return
      else
     self.battler.result.missed = false
     # VX Basic Attack Damage Formula Mod to randomize dmg
     damage = ((attacker.battler.atk / 1.5 + rand(attacker.battler.atk) / 5) - (self.battler.def / 2)).truncate
     # Original Dmg Calculation damage = 0 if damage < 0
     # minimum dmg = 10% of ATK stat
     damage = (attacker.battler.atk / 10).truncate if damage < (attacker.battler.atk / 10)
     self.battler.result.hp_damage = damage
     #self.battler.result.critical   
     self.battler.hp -= damage.abs
     end
 end

Edited by mordor

Share this post


Link to post
Share on other sites

Pathing issue found:

 

How enemies work in XAS Hero

 

The first page of an event mob is typically the behavior when it's not aggro.  The mob has a sensor range (Self switch D).  The sensor range is set on the enemy notes.      <Sensor Range = 6>

 

When Self Switch D becomes active the mob performs the actions to the secondary page (or one triggered by self switch D)

 

I changed my projectiles to "through" on the tools page.  This means they will go through walls.

 

This is why:  Otherwise when an enemy detects a  projectile it will attempt to avoid it, creating poor pathing.

Edited by mordor

Share this post


Link to post
Share on other sites

 

I have a question, err, is there a way to make that when an enemy die, it doesn't actually fade, but instead it activates an self-switch?

@ RaiMaker

 

in my project I did exactly that

(because I wanted to change the enemy graphic to a defeated enemy graphic

and because I wanted to be able to pic up trophies upon the enemy)

 

1) you go to execute_enemy_defeated_process (should be in line 5437)

 

2) and add anywhere $game_self_switches[[$game_map.map_id, self.id, "B"]] = true in the definition

 

however there is a bug: if you go to another map and return to the map where you killed the enemy

you can hit the event a few more times although it's dead. maybe someone could fix this

Nobody has a solution for this problem ?

 

 

A different solution was provided.  Here is another variation.

*Note: Inserting commands into the defeat process would affect ALL enemies unless

specific conditions where written.

 

Adding this line into the defeat process or other areas will call upon a common event each time

$game_temp.reserve_common_event(16)

 

 # â— Execute Enemy Defeaed Process

  #--------------------------------------------------------------------------         

   def execute_enemy_defeated_process

       # Kill Counter

       $game_temp.reserve_common_event(16)

       $game_variables[19] = rand(50)

       self.battler.defeated = true

       self.through = true

       @knock_back_duration = 121

       enemy = $data_enemies[self.battler.enemy_id]

       @collapse_duration = 120

       execute_gain_exp_gold(enemy)  

       execute_active_switch(enemy)

       execute_defeated_animation(enemy)

       execute_defeated_sound_effect(enemy)

       execute_final_shoot(enemy)

     end

 

So what can common event 16 do?

I use it to count mobs into a variable

I use it for a Skill Mastery to gain (hp / mp based on the skill level)

It can randomly add gold/exp

 

 

 

 

 

 

 

 

It also compliments this code

---------------------------------------------------------------------------------------------------------------

 

 

# â— Update Exp Gold Pop

  #--------------------------------------------------------------------------              

  def update_exp_gold_pop

      return unless XAS_DAMAGE_POP::DAMAGE_EXP_GOLD_POP

      exp_pop = @character.battler.exp

# VX Mod Variable 19 is a one in 50 chance to triple Gold/Exp

      if $game_variables[19] == 1

        exp_pop = @character.battler.exp * 3

      end

      gold_pop = @character.battler.gold

      if $game_variables[19] == 1

        gold_pop = @character.battler.gold * 3

      end

 

      case @character.collapse_duration

           when 110

                enemy = $data_enemies[@character.battler.enemy_id]

                @character.make_treasure(enemy)       

           when 80

             if exp_pop != 0

                word = XAS_WORD::EXP

                @character.battler.damage = word + " " + exp_pop.to_s

                @character.battler.damage_pop = true

                @character.battler.damage_type = "Exp"

             end  

           when 40

             if gold_pop != 0

                word = $data_system.currency_unit

                @character.battler.damage = word + " " + gold_pop.to_s

                @character.battler.damage_pop = true

                @character.battler.damage_type = "Gold"

             end               

      end

 

 

# â— Execute Gain Exp Gold

  #--------------------------------------------------------------------------           

  def execute_gain_exp_gold(enemy)  

      exp = self.battler.exp

      if $game_variables[19] == 1

        exp *= 3

      end

      case XAS_BA::EXP_TYPE

         when 0

            actor = $game_party.members[0]

            actor.gain_exp(exp)

         when 1

            for i in 0...$game_party.members.size

               actor = $game_party.members           

               actor.gain_exp(exp)

            end   

         when 2  

            exp = exp / $game_party.members.size

            for i in 0...$game_party.members.size

               actor = $game_party.members           

               actor.gain_exp(exp)

            end              

      end

      

      gold = self.battler.gold

      if $game_variables[19] == 1

      gold *= 3

      end

      $game_party.gain_gold(gold)

      if $game_variables[19] == 1

      $game_variables[18] += (self.battler.exp * 3)

      else

      $game_variables[18] += (self.battler.exp)

      end

  end

 

Variable 19 is randomized in the first defeat process each time.  Then when it comes times process Gold/Exp if the variable = 1 it provides triple gold/exp.  It also plays a sound effect which is done in the common event.

 

Game Variable 18 is "Available exp".  I created a system to use the available exp to purchase stats which increase after each purchase.  An exp system similar to Asheron's Call and a few others.

 

 

 

 

*******************************************************************************************************

 

A note about using Enemy Graphic changes

 

I use image changes to indicate when a mob is going to use some special attacks.  The slimes for instance grow in size or change color before special attacks.  This is done in the enemy's event page alongside movement.

 

*******************************************************************************************************

 

*Projectile and Skill issue

When using the Script Touch Attack the mob is attacking nearly every frame.  What prevents the actor from being hit 60 times a second is the invul frames in between attacks.  An error I came across is projectiles will go right through the actor if the mob is attacking next to it.

 

This is due to the invul still being active from the previous attack.  There are several corrections for this.

#1 Use all special attacks and control the delay

#2 Turn off the touch attack and add a wait statement: touch_attack(false)

 

I cut down the wait to 75 frames by modifying the xas script.  It's fairly fluent with slightly over 1 second for a mobs special which provides time to avoid attacks by movement.

 

This is actually used in more advanced game such as Rift, NeverWinter

It's essentially a mob trigger or indicator

Edited by mordor

Share this post


Link to post
Share on other sites

Can anyone help me?

 

I am trying to make an action based off of a Shield. I was able to do it in RMXP using HIT ID and the Shield's Action ID but the Shield doesn't use an Action ID... Or atleast I don't think so. Sorry for reviving an old topic but thanks.

Share this post


Link to post
Share on other sites

This system looks amazing but I am missing the Party script or have I overseen omething?
The 0.6b Version is the most up to date Version available right? In the Video I saw the party being controlled by an AI...
The Xasabs.com site is down too X_X

Share this post


Link to post
Share on other sites

I'm completely stuck... So i set up XAS in my own game. I went to go test it and everything worked just fine.. Accept that I noticed how in the demo you can use combos when attacking, but when i started mine up it just hit once...

Share this post


Link to post
Share on other sites

I'm completely stuck... So i set up XAS in my own game. I went to go test it and everything worked just fine.. Accept that I noticed how in the demo you can use combos when attacking, but when i started mine up it just hit once...

Seems like you haven't install it completely. You need to copy the Skills too.

In the Demo skills 1-3 are responsible for the combos. That's why they are called Sword A, B & C.

Anyway I ended up inserting my game on the demo instead the other way around because it's faster that way.

Edited by XrosBlader821

Share this post


Link to post
Share on other sites

How would I go about creating a multi-level charge ability

 

for example,

 

I have a lightning god character, who equips different lightning bolts.

as you level up, switches activate and unlock higher-tiered abilities,

 

example:

 

basic attack is thunderbolt- character uses the thunderbolt like a spear

Lv1 charge would have the character throw a lightning bolt

Lv2 charge would have the character throw a larger lightning bolt that causes additional aoe

Lv3 charge would have the character throw a massive spear of lightning that causes massive AOE damage

 

these would get unlocked when the skills are unlocked through a skill-tree type system.

Share this post


Link to post
Share on other sites

You need to set them up via variables. XAS does not use much of the common events, so you can access these higher tiered skills when such value of the skills are met.

Share this post


Link to post
Share on other sites

What i meant was this....

 

You charge your attack, it reaches the first "charge" level,

is there a way, so that if you keep charging, you can reach the second charge level? then the third

 

Like this

no charge ===> Lv1 charge ===> Lv2 charge ===> Lv3 charge.

I dont want to add skills or replace the lv1 with the lv2, I just want it so that when the amount of charge reaches the appropriate number

 

Is there a way to do this.

 

best way of describing this is the spell charge system from fable, where the longer you hold a spell, the more powerful it gets.

Share this post


Link to post
Share on other sites

A wee bit of necroposting. Anyone knows of a good way to set any enemy hp on the current map to a specific value / kill them outright from script? I'm trying to figure out ways to emulate two enemies having a battle with each other within the XAS system. 

I already have a prototype of two enemies hitting each other with a variable on the outside that keeps track of every time one of the mobs hits. very clunky and very stupid as it takes ages to setup and takes up a lot of variable/switch slots. 

Share this post


Link to post
Share on other sites

A wee bit of necroposting. Anyone knows of a good way to set any enemy hp on the current map to a specific value / kill them outright from script? I'm trying to figure out ways to emulate two enemies having a battle with each other within the XAS system. 

 

I already have a prototype of two enemies hitting each other with a variable on the outside that keeps track of every time one of the mobs hits. very clunky and very stupid as it takes ages to setup and takes up a lot of variable/switch slots. 

Having come to this topic to see some news on the still offline (and complete disappearance of xasabs.com), I found myself reading this, which got me thinking.

You could technically set up enemies designed to attack each other through the use of skills that they use/shoot toward each other. I'm not sure about advanced movement, but at the very least you could probably make them attack each other. I'd set up separate enemies and skills for this though, it could be messy otherwise, afterall, you don't actually need multiple enemies for it in the database, you could program 1, then assign it to multiple events.

I hope I helped in some way.

 

In any case, has anyone heard anything about xasabs.com? It seems to have totally disappeared with no trace it even existed (even the url isn't in use anymore).

 

Sorry if this counts as a necropost.

Share this post


Link to post
Share on other sites

 

A wee bit of necroposting. Anyone knows of a good way to set any enemy hp on the current map to a specific value / kill them outright from script? I'm trying to figure out ways to emulate two enemies having a battle with each other within the XAS system. 

 

I already have a prototype of two enemies hitting each other with a variable on the outside that keeps track of every time one of the mobs hits. very clunky and very stupid as it takes ages to setup and takes up a lot of variable/switch slots. 

Having come to this topic to see some news on the still offline (and complete disappearance of xasabs.com), I found myself reading this, which got me thinking.

You could technically set up enemies designed to attack each other through the use of skills that they use/shoot toward each other. I'm not sure about advanced movement, but at the very least you could probably make them attack each other. I'd set up separate enemies and skills for this though, it could be messy otherwise, afterall, you don't actually need multiple enemies for it in the database, you could program 1, then assign it to multiple events.

I hope I helped in some way.

 

In any case, has anyone heard anything about xasabs.com? It seems to have totally disappeared with no trace it even existed (even the url isn't in use anymore).

 

Sorry if this counts as a necropost.

 

 

 Yep - I've been looking myself as well, nothing to be found apart from a scattershot of members who know how to use the script, there's virtually no support or updates.

Edited by Dymdez

Share this post


Link to post
Share on other sites

Greetings again! Here I am once again necroposting!

I'm thinking once I'm a wee bit more experienced with some of it's workings I'll make some guides ^-^ A lot of me learning how scripts work has come from trying to reverse engineer XAS, lmao, and by that I don't mean to say I know what I'm doing nor ever will understand all of it. Just that I think since I'm using it for my own project since like a year+ back, I'll have some nice thingies to share I hope, eventually ^^

I've come upon another question. However I fear it's either the developers of XAS or myself who's closest to an anwer here....But how does Shield skill take up ct? I've tried looking at everything that happens when the shield is activated, I tried looking at what CT_COST_SHIELD is referring to, and I still can't find where XAS deduces ct when you hold up your shield. 

Why do I want to? well. I'm trying to make it so that you can always block unless you go below a certain amount of ct. I can make it work BUT this also means the ct doesnt get set lower, what I really need is a way to adress the ct directly and modify it.

Made sense?

Share this post


Link to post
Share on other sites

It is being taken care of the x_charge_action and the tags.

 

 

 

 def refresh_shield_number
     @shield_number = 0
     @s_item = 0
     @shield_number_sprite.bitmap.clear
     return if @shield == nil
     if @shield.note =~ /<Action ID = (\d+)>/
         action_id =  $1.to_i    
         skill = $data_skills[action_id]
         if skill != nil
            if skill.note =~ /<Item Cost = (\d+)>/
               item_id = $1.to_i 
               if item_id != nil
                  @s_item = $data_items[item_id]
                  @shield_number = $game_party.item_number(@s_item)              
               end
             end
         end    
     end  
     return if @s_item == 0
     cost_split = @shield_number.to_s.split(//)
     for r in 0..cost_split.size - 1 
         number_abs = cost_split[r].to_i 
         src_rect = Rect.new(@number_cw * number_abs, 0, @number_cw, @number_ch)
         @shield_number_sprite.bitmap.blt(@number_sc  *  r, 0, @number_image, src_rect)        
     end         
     xf = ((cost_split.size * @number_sc) / 2)
     @shield_number_sprite.x = SHIELD_HUD[0] + NUMBER[0] - xf
     @shield_number_sprite.y = SHIELD_HUD[1] + NUMBER[1]  
 end    

 

 

 

You can add a tag for the cost as was delivered there. In your demo, you can see that there's no tag for it, so you'll have to make your own. If you check the cost of all CT (as Guard is a skill I believe), the code lies here:

 

 

 

  #--------------------------------------------------------------------------
  # â— Check CT Cost?
  #--------------------------------------------------------------------------  
  def check_ct_cost?(skill) 
      return true if $game_system.ct_system == false
      return true if self.battler.is_a?(Game_Enemy)
      if skill.note =~ /<CT Cost = (\d+)>/
         ct_cost = $1.to_i
         if ct_cost != nil
            return false if self.battler.ct < ct_cost
            self.battler.ct -= ct_cost
         end
      end   
      return true  
  end 

 

 

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

  • Recently Browsing   0 members

    No registered users viewing this page.

×
Top ArrowTop Arrow Highlighted