[RESOLVED] [XP] Healing Weapon script

Started by callmedan, August 04, 2017, 11:14:43 pm

Previous topic - Next topic

callmedan

August 04, 2017, 11:14:43 pm Last Edit: August 05, 2017, 09:43:43 am by callmedan
Introduction
Hello! I'm looking for a healing weapon script. Because several people misunderstood it so I'd like to say no, it's not absorb/vampiric weapon.
My English is not really good so I would try my best to explain what I need.
Thanks a ton!  :)

What I would like it to do.
The healing weapon works just like normal weapons. It damages the enemy but it also heals player who equipped it x HP each attack turn (In my game, player equipped healing weapon gains 10 HP each attack turn).

How I would like it to work

  • The script use actor ID and weapon ID to define the healing weapon.

  • It has a module so that I could list the healing weapons IDs.



Scripts I'm using now

  • Weather script by Ccoa

  • Multiple Fogs by Game_Guy

  • Heretic's Modular Passable scripts + Super Event Sensor

  • Particle Engine by arevulopapo

  • MOG Animated Panorama XP V2.1

  • Damage Images by Game_Guy

  • Two-Handed Weapons by RPG Advocate


KK20

There's a script in Tons of Add-ons that consumes actor's HP/SP with a normal weapon attack (HP/SP Crush, in Part 2). As the script's description states (in bold):
Quote
#   This add-on allows you to make weapons consume HP/SP for each attack. The
#   attack will not be executed if there are not enough HP or SP. The actor can
#   use up all SP and/or all HP (except 1) for an attack to succeed. If you use
#   negative values in the configuration, the stats will be restored instead of
#   consumed.



Other Projects
RPG Maker XP Ace  Upgrade RMXP to RMVXA performance!
XPA Tilemap  Tilemap rewrite with many features, including custom resolution!

Nintendo Switch Friend Code: 8310-1917-5318
Discord: KK20 Tyler#8901

Join the CP Discord Server!

callmedan

Quote from: KK20 on August 05, 2017, 02:55:28 am
There's a script in Tons of Add-ons that consumes actor's HP/SP with a normal weapon attack (HP/SP Crush, in Part 2). As the script's description states (in bold):
Quote
#   This add-on allows you to make weapons consume HP/SP for each attack. The
#   attack will not be executed if there are not enough HP or SP. The actor can
#   use up all SP and/or all HP (except 1) for an attack to succeed. If you use
#   negative values in the configuration, the stats will be restored instead of
#   consumed.



Thank you! Btw, Is it possible to make the consumed/restored HP number show up in battle scene?

KK20

Just need to add one line to the method in the script:

      current_battler.hp -= reqs[0]
      current_battler.sp -= reqs[1]

      current_battler.damage = (reqs[0] != 0 ? reqs[0] : (reqs[1] != 0 ? reqs[1] : current_battler.damage)) #<===== This line

      @status_window.refresh

Will probably not display the correct amount if you have a poison state or some other script that heals/damages the attacking battler since they will most likely overwrite the damage value.

Other Projects
RPG Maker XP Ace  Upgrade RMXP to RMVXA performance!
XPA Tilemap  Tilemap rewrite with many features, including custom resolution!

Nintendo Switch Friend Code: 8310-1917-5318
Discord: KK20 Tyler#8901

Join the CP Discord Server!

callmedan