RMRK is retiring.
Registration is disabled. The site will remain online, but eventually become a read-only archive. More information.

RMRK.net has nothing to do with Blockchains, Cryptocurrency or NFTs. We have been around since the early 2000s, but there is a new group using the RMRK name that deals with those things. We have nothing to do with them.
NFTs are a scam, and if somebody is trying to persuade you to buy or invest in crypto/blockchain/NFT content, please turn them down and save your money. See this video for more information.
[VX] How can you make a battler only take one damage per attack?

0 Members and 1 Guest are viewing this topic.

***
Rep:
Level 69
RMRK Junior
The effect I am going for is like the metal slime in Dragon Warrior..  how do I make it so that he only takes 1 dmg per attack.  I have it so that no magic has any effect on them, and weapon efficiency= E as well. (E's in all my state efficiency), thier defense is around 30..

Certain attacks hit them for like 200, I don't want them to work like that, they should also be 1 hp or a miss.  Anyone know how to fix that?

*
my name is Timothy what's yours
Rep:
Level 79
Hello
2014 Best IRC Quote2014 Zero to Hero2014 Most Missed Member2012 Zero To HeroSecret Santa 2012 ParticipantContestant - GIAW 9For frequently finding and reporting spam and spam bots2011 Zero to Hero
Do you mean with skills or even physical attacks? I wrote a snippet to cancel out variance on specified skills and items, but that's not what you want.
So, you want, on a certain enemy, damage to be applied exactly as the base value? Either wait for me to conjure up a snippet or tinker with the enemy's defense stat until you find the right spot.
it's like a metaphor or something i don't know

***
Rep:
Level 69
RMRK Junior
Yeah that would be great. The only thing is that at the end game content, certain skills should be able to damage them normally.  Such as you learn Dragonstrike at lvl 50,  and every other attack/skill still does 1 dmg to enemy, however dragonstrike hits normally.  Is that possible?

*
my name is Timothy what's yours
Rep:
Level 79
Hello
2014 Best IRC Quote2014 Zero to Hero2014 Most Missed Member2012 Zero To HeroSecret Santa 2012 ParticipantContestant - GIAW 9For frequently finding and reporting spam and spam bots2011 Zero to Hero
Very possible. This snippet will make it so specified items and skills cause no variance. So if you want only 1 damage with your skill, set the base damage to 1 and it'll deal 1 damage.
Code: [Select]
#===============================================================================
#
# Specified No Variance (1.0)
# By Pacman - 13/8/2011
# Paste above main.
#
#===============================================================================
#
# This allows you to choose certain skills and items that do not have variance
# applied to the damage when used. To specify such a skill or item, place a
# tag - \no_variance - in the notebox. This means that when it is used on an
# enemy (or ally), it will deal the direct base damage of the skill or item.
# This requires no editing or configuration.
#
#===============================================================================

#==============================================================================
# ** RPG::UsableItem
#------------------------------------------------------------------------------
#  Data class for skills and items. Used as a superclass of skills and items,
# and as a subclass of BaseItem.
#==============================================================================

class RPG::UsableItem < RPG::BaseItem
  #--------------------------------------------------------------------------
  # * Calculate whether to apply variance or not
  #--------------------------------------------------------------------------
  def no_variance
    @no_variance = !self.note[/\\NO_VARIANCE/i].nil? if @no_variance.nil?
    return @no_variance
  end
end

#==============================================================================
# ** Game_Battler
#------------------------------------------------------------------------------
#  This class deals with battlers. It's used as a superclass of the Game_Actor
# and Game_Enemy classes.
#==============================================================================

class Game_Battler
  #--------------------------------------------------------------------------
  # alias listing
  #--------------------------------------------------------------------------
  alias novar_make_obj_damage_value make_obj_damage_value
  #--------------------------------------------------------------------------
  # * Calculation of Damage Caused by Skills or Items
  #     user : User of skill or item
  #     obj  : Skill or item (for normal attacks, this is nil)
  #    The results are substituted for @hp_damage or @mp_damage.
  #--------------------------------------------------------------------------
  def make_obj_damage_value(user, obj)
    if obj.no_variance                          # If tag is present
      damage = obj.base_damage                  # Straight damage
      if obj.damage_to_mp                       # If applied to mp
        @mp_damage = damage                     # Set mp damage
      else                                      # If applied to hp
        @hp_damage = damage                     # Set hp damage
      end
    else
      novar_make_obj_damage_value(user, obj) # Apply accordingly
    end
  end
end
it's like a metaphor or something i don't know

***
Rep:
Level 69
RMRK Junior
Now that I'm looking at the script.. I think that my idea and your snippet are backwards.  I would like to edit the notebox
in the enemy tab, because the way it LOOKS right now is that you set this to your skills to base damage of one.. which will be counter productive because it should only affect certain enemies, not certain skills.  Say if I put this on the skill,
Flame, with a base damage of one with your snippet in the note box..  then no matter what enemy I use it on.. it will do base dmg of one with no variance..  wouldn't that effect all enemies in the same way?  Which means all enemies would take 1 dmg from the ability..  when I only want one dmg to a certain enemy (Metal Slime)...   am I understanding this correctly?

*
my name is Timothy what's yours
Rep:
Level 79
Hello
2014 Best IRC Quote2014 Zero to Hero2014 Most Missed Member2012 Zero To HeroSecret Santa 2012 ParticipantContestant - GIAW 9For frequently finding and reporting spam and spam bots2011 Zero to Hero
Yes, it was a misunderstanding on my part.
I'll have your script done tonight.
it's like a metaphor or something i don't know

***
Rep:
Level 69
RMRK Junior
Thank you so much man, no rush its a very small part in my project.  Thanks for your help.  I asked on another forum, but how do you add a custom menu option in the actual menu..  like where it says Item and status and equip.. I'm very confused on it and looked through quite a few scripts and cant quite get my head around it.  Perhaps you have soemthing already made thats easy to follow?

*
my name is Timothy what's yours
Rep:
Level 79
Hello
2014 Best IRC Quote2014 Zero to Hero2014 Most Missed Member2012 Zero To HeroSecret Santa 2012 ParticipantContestant - GIAW 9For frequently finding and reporting spam and spam bots2011 Zero to Hero
Funnily enough, I have a script specifically designed for doing just that.
Your snippet will be done in about an hour or two.
it's like a metaphor or something i don't know

*
my name is Timothy what's yours
Rep:
Level 79
Hello
2014 Best IRC Quote2014 Zero to Hero2014 Most Missed Member2012 Zero To HeroSecret Santa 2012 ParticipantContestant - GIAW 9For frequently finding and reporting spam and spam bots2011 Zero to Hero
Well, this does it for enemies.
Code: [Select]
#===============================================================================
# No Variance - Enemies
# Pacman, 31th August 2011
# Paste above main, below materials. Preferably near the top of your custom
# script list.
# To give an enemy no variance when an attack, skill or item is used against
# them (i.e., the skill or item's base damage or the actor's attack is used),
# place the tag \no_variace in their notebox.
# To assign an enemy a global damage (taken whenever it is attacked), put the
# tag \global_damage[NUMBER] where NUMBER is the amount of damage you wish to
# give it whenver it is attacked in the notebox.
#===============================================================================

#==============================================================================
# ** RPG::Enemy
#------------------------------------------------------------------------------
#  Data class for enemies.
#==============================================================================

class RPG::Enemy
  #--------------------------------------------------------------------------
  # * Determine if Variance is to be applied
  #--------------------------------------------------------------------------
def no_variance
return (self.note[/\\NO_VARIANCE/i] != nil)
end
  #--------------------------------------------------------------------------
  # * Determine Global Damage setting
  #--------------------------------------------------------------------------
def global_damage
return self.note[/\\GLOBAL_DAMAGE\[(\d+)\]/i] != nil ? $1.to_i : nil
end
end

#==============================================================================
# ** Game_Enemy
#------------------------------------------------------------------------------
#  This class handles enemy characters. It's used within the Game_Troop class
# ($game_troop).
#==============================================================================

class Game_Enemy < Game_Battler
def make_attack_damage_value(attacker)
if self.enemy.global_damage != nil
@hp_damage = self.enemy.global_damage
elsif self.enemy.no_variance
@hp_damage = attacker.atk
else
super(attacker)
end
end
def make_obj_damage_value(user, obj)
if self.enemy.global_damage != nil
if obj.damage_to_mp
@mp_damage = self.enemy.global_damage
else
@hp_damage = self.enemy.global_damage
end
elsif self.enemy.no_variance
if obj.damage_to_mp
@mp_damage = obj.base_damage
else
@hp_damage = obj.base_damage
end
else
super(user, obj)
end
end
end

#===============================================================================
#
# END OF SCRIPT
#
#===============================================================================
Anything else?
it's like a metaphor or something i don't know

***
Rep:
Level 69
RMRK Junior
Ok, so I put the script into the game, it works great!  Thank you so much!  but how would I make certain skills turn off the no variance and hit the monster normally, ie.  at lvl 50 get the skill dragonstrike and whoops ass? (only dragonstrike or whatever skill i deem necassary should hit normally.

***
Rep:
Level 69
RMRK Junior
The Pac Menu looks super cool, however, I already use Yanflys Menu System Option, and Simple Sort Inventory, which is why I believe it doesn't work.  I loaded it into a new game and it looks good, however I would rather the original menu just with another selectable..  one that will display a new window that depicts skills and the actor that knows them, and the level of the skill:


Skill   \  Actor  \   Level

Lockpicking  \  Ralph  \    5  (this value would be game variable[x])

Is there a snippet that can do that? Maybe within the Pac Menu??

*
my name is Timothy what's yours
Rep:
Level 79
Hello
2014 Best IRC Quote2014 Zero to Hero2014 Most Missed Member2012 Zero To HeroSecret Santa 2012 ParticipantContestant - GIAW 9For frequently finding and reporting spam and spam bots2011 Zero to Hero
I would rather the original menu just with another selectable..  one that will display a new window that depicts skills and the actor that knows them, and the level of the skill:


Skill   \  Actor  \   Level

Lockpicking  \  Ralph  \    5  (this value would be game variable[x])

Is there a snippet that can do that? Maybe within the Pac Menu??
No. It would have to be a custom-made scene.

And as for your 'make dragonstrike own at level 50', I hope you mean the actor level, because I've already started writing it.
it's like a metaphor or something i don't know

***
Rep:
Level 69
RMRK Junior
Well, not only would it be dragonstrike, but a select more moves as well, the snippet should work with skills not actors, I would like to recieve the certain skills at lvl 50 through leveling, so:

If you learn (skills from 5 different actors)

Dragonstrike
Merciless Charge
Heavenly Strike

I would like those certain skills to effect it:

So I would imagine it would look something like this:

If the skill "[Skill: 012] Dragonstrike" is used, damage is normal.

as well as the other skills mentioned above.. not sure if these are the names I will use, but I hope you get the idea.

Thank you for all your help by the way, absolutely wonderful.


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

As for my other question..  How would I make a scene, I can pretty much draw the window,  I just have no idea how to make it on the menu, cancel with the cancel button..  etc. :(



*
my name is Timothy what's yours
Rep:
Level 79
Hello
2014 Best IRC Quote2014 Zero to Hero2014 Most Missed Member2012 Zero To HeroSecret Santa 2012 ParticipantContestant - GIAW 9For frequently finding and reporting spam and spam bots2011 Zero to Hero
As much as it seems on the contrary, that would be a lot of tedious work, and though I would like to help you, I have a lot of stuff on my hands.
Your other thing seems simpler (the menu option), and if you posted your current code I could whip something up to include it.
it's like a metaphor or something i don't know