Jump to content


Photo

Thorn Mail

effect

  • Please log in to reply
24 replies to this topic

#1 Tsukihime

Tsukihime

    Advanced Member

  • Ace Member
  • 7,120 posts
  • LocationToronto
  • RM Skill - Coder

Awards Bar:

Users Awards

Posted 07 October 2012 - 10:39 PM

Effect: Thorn Mail
-Tsukihime

This script adds "thorn mail" effect to your armors.
When a battler attacks you, the enemy will receive damage in return.

Download

Script: Download here
Required: Effect Manager

Usage

Tag your armors with

<eff: thorn_mail x>
Where x is the amount of damage that will be inflicted.
Note that you can use a formula (without spaces) with the following keywords:

user - the person that is attacking you
self - you

<eff: thorn_mail user.def>
This will deal damage equal to the attacker's def.

Edited by Tsukihime, 09 March 2016 - 10:54 PM.

All of my work can be found on my website:

banner200x40.png

You can follow me on any of these platforms:

logo_facebook40x40.pnglogo_twitter40x40.pnglogo_youtube40x40.pnglogo_patreon40x40.pnglogo_instagram40x40.png

Go here for Bugs and Requests.
 
Want to become a beta tester for my plugins before they are released to the public?

#2 Galv

Galv

    Forum Defender

  • Staff Manager/Global Mod
  • 5,607 posts
  • LocationAustralia
  • RM Skill - Jack of All Trades

Awards Bar:

Users Awards

Posted 07 October 2012 - 11:07 PM

Guessing someone has played League of Legends? (dunno if thornmail is anywhere else haha)

I'm really liking all these effects you've got going. Nice job.

gs-banner_zpsfc59b073.pngp7GQmH4.png 2hjKrWv.png


#3 Tsukihime

Tsukihime

    Advanced Member

  • Ace Member
  • 7,120 posts
  • LocationToronto
  • RM Skill - Coder

Awards Bar:

Users Awards

Posted 07 October 2012 - 11:23 PM

Nope, though it might be called something else in some other game.
This was to test the new armor effects I've added to the effect manager.
All of my work can be found on my website:

banner200x40.png

You can follow me on any of these platforms:

logo_facebook40x40.pnglogo_twitter40x40.pnglogo_youtube40x40.pnglogo_patreon40x40.pnglogo_instagram40x40.png

Go here for Bugs and Requests.
 
Want to become a beta tester for my plugins before they are released to the public?

#4 nameokh

nameokh

    Member

  • Ace Member
  • 13 posts

Posted 08 October 2012 - 03:42 AM

I think a perfect skill, but I can also assign it to an enemy like FF12 elementals?

#5 Tsukihime

Tsukihime

    Advanced Member

  • Ace Member
  • 7,120 posts
  • LocationToronto
  • RM Skill - Coder

Awards Bar:

Users Awards

Posted 08 October 2012 - 08:51 AM

Not yet.
All of my work can be found on my website:

banner200x40.png

You can follow me on any of these platforms:

logo_facebook40x40.pnglogo_twitter40x40.pnglogo_youtube40x40.pnglogo_patreon40x40.pnglogo_instagram40x40.png

Go here for Bugs and Requests.
 
Want to become a beta tester for my plugins before they are released to the public?

#6 Xypher

Xypher

    Advanced Member

  • Ace Member
  • 946 posts
  • RM Skill - Jack of All Trades

Posted 24 October 2012 - 06:01 AM

Is there any way to get a states version of this?

#7 Tsukihime

Tsukihime

    Advanced Member

  • Ace Member
  • 7,120 posts
  • LocationToronto
  • RM Skill - Coder

Awards Bar:

Users Awards

Posted 24 October 2012 - 08:03 AM

I think you just have to write

alias :state_effect_thorn_mail_guard :armor_effect_thorn_mail_guard

Under it.
Otherwise you will have to copy the definition

def state_effect_thorn_mail_guard
   #copy from armor effect
end

Or separate it into its own method and just have each type call it.

Edited by Tsukihime, 24 October 2012 - 08:03 AM.

All of my work can be found on my website:

banner200x40.png

You can follow me on any of these platforms:

logo_facebook40x40.pnglogo_twitter40x40.pnglogo_youtube40x40.pnglogo_patreon40x40.pnglogo_instagram40x40.png

Go here for Bugs and Requests.
 
Want to become a beta tester for my plugins before they are released to the public?

#8 Xypher

Xypher

    Advanced Member

  • Ace Member
  • 946 posts
  • RM Skill - Jack of All Trades

Posted 25 October 2012 - 08:53 AM

Using the alias worked, thanks.

#9 ekomega

ekomega

    Advanced Member

  • Ace Member
  • 268 posts

Posted 16 November 2012 - 04:11 PM

I know you don't do compatibility... but I noticed with your Thornmail and Vampire weapon scripts, they don't popup the reflected damage or vampire healing with Yanfly's popup scripts (although the damage/healing is noted in the text box). Since you don't have a popup script of your own, I was hoping there was an easy solution. Any help? Thanks!

#10 Tsukihime

Tsukihime

    Advanced Member

  • Ace Member
  • 7,120 posts
  • LocationToronto
  • RM Skill - Coder

Awards Bar:

Users Awards

Posted 16 November 2012 - 07:35 PM

There is no easy solution.
If you added yanfly's popups, you will be getting one popup for EVERY effect. This means that if you had 10 effects, you will get 10 different popups.

Yanfly's popups are not flexible in the sense that it displays as soon as there is something to display.
That is not intuitive because if you took 200 damage, your shield absorbed 100 damage, and you reflected 50 damage, it would be ugly to see yourself get hit for 200, heal for 100, and then somehow reflect 50 by healing another 50?

Edited by Tsukihime, 16 November 2012 - 07:37 PM.

All of my work can be found on my website:

banner200x40.png

You can follow me on any of these platforms:

logo_facebook40x40.pnglogo_twitter40x40.pnglogo_youtube40x40.pnglogo_patreon40x40.pnglogo_instagram40x40.png

Go here for Bugs and Requests.
 
Want to become a beta tester for my plugins before they are released to the public?

#11 ekomega

ekomega

    Advanced Member

  • Ace Member
  • 268 posts

Posted 17 November 2012 - 01:02 AM

I can see your point, if you use a lot of your modification scripts. Although, I'm wondering if it really looks that bad. Do you have a screenshot? :P Some people like seeing lots of numbers.

If you get hit with thornmail, there's a popup on you for damage and on the enemy for damage. And for vampire, it's also damage on enemy and healing on you. Those don't sound so bad, as the popups are on different targets. Mana Shield added in to that mix would get confusing. But you could do popups for the others and not mana shield, if you wanted...

Anyway, thanks for the response.

Edited by ekomega, 17 November 2012 - 01:02 AM.


#12 Tsukihime

Tsukihime

    Advanced Member

  • Ace Member
  • 7,120 posts
  • LocationToronto
  • RM Skill - Coder

Awards Bar:

Users Awards

Posted 17 November 2012 - 06:52 AM

I did a quick test the other day since someone also requested it and it looked really bad.

First, there is a random null popping up.
Second, thorn mail popups aren't working properly: if the attacker took damage from thorn mail, it wouldn't show up. I imagine this is because the default engine doesn't support anything like this and therefore there was no need to implement it.

Posted Image

And third it just isn't intuitive.
Here, I did 50 damage, and OF that 50 damage I absorbed 10.
These popups make it look like I did 60 damage.

It is trivial to make the popups: simply assign values to the result (eg: result.hp_damage, result.hp_drain, result.mp_damage, result.critical, etc)

  def armor_effect_thorn_mail_guard(user, armor, effect)
    return if user == self
    damage = eval(effect.value1[0])
    user.hp -= damage
    user.perform_collapse_effect if user.dead?

    user.result.hp_damage = damage # new
    @result.effect_results.push("%s takes %s damage!" %[user.name, damage])
    @result.success = true
    make_damage_popups(user) # new
  end

But it's not working for thorn mail.

Edited by Tsukihime, 17 November 2012 - 06:55 AM.

All of my work can be found on my website:

banner200x40.png

You can follow me on any of these platforms:

logo_facebook40x40.pnglogo_twitter40x40.pnglogo_youtube40x40.pnglogo_patreon40x40.pnglogo_instagram40x40.png

Go here for Bugs and Requests.
 
Want to become a beta tester for my plugins before they are released to the public?

#13 ekomega

ekomega

    Advanced Member

  • Ace Member
  • 268 posts

Posted 17 November 2012 - 10:09 AM

This is very clear, thank you.

#14 Ctelin Ajira

Ctelin Ajira

    Member

  • Ace Member
  • 11 posts

Posted 17 May 2013 - 11:53 AM

How do I get thorn mail to deal the same damage the attacker dealt?



#15 Tsukihime

Tsukihime

    Advanced Member

  • Ace Member
  • 7,120 posts
  • LocationToronto
  • RM Skill - Coder

Awards Bar:

Users Awards

Posted 17 May 2013 - 12:19 PM

Use @result.hp_damage for the formula
All of my work can be found on my website:

banner200x40.png

You can follow me on any of these platforms:

logo_facebook40x40.pnglogo_twitter40x40.pnglogo_youtube40x40.pnglogo_patreon40x40.pnglogo_instagram40x40.png

Go here for Bugs and Requests.
 
Want to become a beta tester for my plugins before they are released to the public?

#16 Omen613

Omen613

    Advanced Member

  • Ace Member
  • 32 posts
  • RM Skill - Jack of All Trades

Posted 17 May 2013 - 02:10 PM

Any chance you could tweak this to work on states as well?

 

Love your scripts.



#17 estriole

estriole

    Advanced Member

  • Ace Member
  • 1,999 posts
  • LocationIndonesia
  • RM Skill - Coder

Posted 20 May 2013 - 10:08 PM

I think you just have to write
 

alias :state_effect_thorn_mail_guard :armor_effect_thorn_mail_guard

Under it.
Otherwise you will have to copy the definition

def state_effect_thorn_mail_guard
   #copy from armor effect
end

Or separate it into its own method and just have each type call it.

@omen: hime already answer that question



#18 Audrey

Audrey

    SHRED IT DEWDDD

  • Ace Member
  • 178 posts
  • RM Skill - Jack of All Trades

Posted 15 June 2013 - 12:59 PM

Is there any way I could either have it so I tag skills that I want to be included to cause response from the thorn armor, a tag to un-included skills from causing a response,

or that I can have it so only skills with Same As Attack applied cause a response?

'Cause the way you have it, all physical skills cause a reaction.

I have several physical spells like Jagged Rock where the power is determined by the user's MAT and the enemy's DEF, but it is counted as a physical attack. This is to be effected by things such as Damage from Physical Skills and whatnot.


4.jpg

 

The Archive Cleric

48% Strength, 23% Bloodlust, 37% Intelligence, 42% Spirit, 28% Vitality and 12% Agility!

Spoiler

My personal character subclasses are 

Cleric * Shaman * Soldier


#19 onikuma

onikuma

    Advanced Member

  • Ace Member
  • 41 posts

Posted 17 January 2014 - 04:19 PM

Anyway to get this working with Yanfly Engine Ace - Ace Battle Engine v1.22? The damage doesn't pop up.



#20 tiagoms

tiagoms

    Advanced Member

  • Ace Member
  • 40 posts

Posted 08 June 2014 - 05:20 PM

There is no way to put PopUp?





0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users