Lone Wolf Development Forums  

Go Back   Lone Wolf Development Forums > Hero Lab Forums > HL - Pathfinder Roleplaying Game
Register FAQ Community Today's Posts Search

Notices

Reply
 
Thread Tools Display Modes
stuartwaring
Member
 
Join Date: Jan 2015
Location: Wellington, NZ
Posts: 91

Old November 29th, 2015, 05:14 PM
My character has a legendary item, which has (amongst others) the foe-biting ability. Although it appears on the specials tab, are the any plans (from LW or Community) to add it to the in-play area so that it can be activated (a la Power Attack) so it modifies the damage etc automatically?

I could do it myself, but being as they are non-duplicatable, that seems like a lot of work as i have little spare time at the moment!

Thanks
Stuart
stuartwaring is offline   #1 Reply With Quote
Togainu
Senior Member
 
Join Date: May 2014
Posts: 292

Old November 29th, 2015, 06:05 PM
I don't think this ability can be done as an activate-able. The ability doubles the damage done. Meaning that the entire roll + modifiers is multiplied. The system doesn't know what the dice result was.

So a roll of 1d6+5 doesn't become a 2d6+10. It becomes a (1d6+5)*2 and this becomes even worse when you also have abilities like flaming on it where it becomes (1d6(weapon)+1d6(flaming)+5)*2.

To see the different results you would get from it you can check here: http://anydice.com/program/720e

Last edited by Togainu; November 29th, 2015 at 09:29 PM. Reason: added link to sample
Togainu is offline   #2 Reply With Quote
stuartwaring
Member
 
Join Date: Jan 2015
Location: Wellington, NZ
Posts: 91

Old November 29th, 2015, 11:31 PM
I had interpreted it as rolling everything twice, but I see that you are right, as written. Of course statistically the average is still the same, but you do not get the Gaussian curve. I still think it would be wothwile me having a go at writing the code, I'd I get chance simply to make it easier to remember to use it, as I am constantly using the in play tab, but rarely look at specials in game.
stuartwaring is offline   #3 Reply With Quote
ShadowChemosh
Senior Member
Volunteer Data File Contributor
 
Join Date: Jan 2010
Location: Chicago, IL (USA)
Posts: 10,729

Old November 30th, 2015, 10:22 AM
Quote:
Originally Posted by Togainu View Post
So a roll of 1d6+5 doesn't become a 2d6+10. It becomes a (1d6+5)*2 and this becomes even worse when you also have abilities like flaming on it where it becomes (1d6(weapon)+1d6(flaming)+5)*2.
Actually I could totally make it display this way actually. I can't guarantee that the math works when rolled on the iPad. I think I have tried to do a multiplier on the iPad for weapons and it didn't like it.

But could totally make it display (1d6+1d6 fire+5) * 2.

@stuartwaring if you want to give this a go I would recommend looking at the deprecated "Vital Strike" Feat I did in the Basic Pack. You can still find it in the editor as it has script logic to break apart the weapon values into pieces so that I could double it for Vital and Mythic Vital strike. That would give you a good starting point to work from.

Hero Lab Resources:
Pathfinder - d20pfsrd and Pathfinder Pack Setup
3.5 D&D (d20) - Community Server Setup
5E D&D - Community Server Setup
Hero Lab Help - Hero Lab FAQ, Editor Tutorials and Videos, Editor & Scripting Resources.
Created by the community for the community
- Realm Works kickstarter backer (Alpha Wolf) and Beta tester.
- d20 HL package volunteer editor.
ShadowChemosh is offline   #4 Reply With Quote
stuartwaring
Member
 
Join Date: Jan 2015
Location: Wellington, NZ
Posts: 91

Old November 30th, 2015, 12:29 PM
@ShadowChemosh - I just had the same idea, but couldn't figure out a way to edit the livename.

I am looking at your script and i can see what it is doing, but of course I don't want to change the number of dice or the bonuses - i just need to wrap the whole thing in those brackets and add in the multiplication.

Looking at the debug tasks for the rapier, i can see the livename is dealt with in the render phase, and its priority, but i do not know enough about the location of the weapon's livename (is it in BaseWep??) in order to edit it.

I want to use this kind of statement
Code:
doneif (field[abilActive].value = 0)

~checks if the weapons are legendary and equipped
if (hero.child[iMagWeapon].field[gIsLegend].value <> 0 ) then 
if (hero.child[iMagWeapon].field[gIsEquip].value <> 0) then

~Changes the damage shown
hero.child[iMagWeapon].field[livename].text = "(" & hero.child[iMagWeapon].field[wDamage].value & ") x2"
endif
endif
The issue is I am really not sure if the fields/children are correct (almost certainly not as it compiles, but nothing changes when i activate the ability!)

of course i could be going about it arse about face

Last edited by stuartwaring; November 30th, 2015 at 12:44 PM.
stuartwaring is offline   #5 Reply With Quote
stuartwaring
Member
 
Join Date: Jan 2015
Location: Wellington, NZ
Posts: 91

Old November 30th, 2015, 03:15 PM
I now have it sort of working - it works for my primary weapon, but if i add a different legendary weapon it no longer works.

Really stuck on this now!

Code:
doneif (field[abilActive].value = 0)

    	  var iX    as number
~     iX=0

      ~ Loop through all weapons on the hero except Touch Attacks
      ~ and any Ammunition.
         ~ Assume one handed damage
        iX = 0
        ~ If two handed weapon set to two-handed damage
        If (hero.child[iMagWeapon].tagis[wClass.TwoHanded] <> 0) Then
          iX = 1
        ~ If one handed and used in two hands then damage is two-handed
        ElseIf (hero.child[iMagWeapon].tagis[wClass.OneHanded] + hero.child[iMagWeapon].tagis[Hero.MainHand] + hero.child[iMagWeapon].tagis[Hero.OffHand] = 3) Then
          iX = 1
        ~ If used in off-hand
        ElseIf (hero.child[iMagWeapon].tagis[Hero.OffHand] - hero.child[iMagWeapon].tagis[Hero.MainHand] = 1) Then
          iX = 4
        Endif

    
~checks if the weapons are legendary and equipped
if (hero.child[iMagWeapon].field[gIsLegend].value <> 0 ) then 
if (hero.child[iMagWeapon].field[gIsEquip].value <> 0) then

~Changes the damage shown
hero.child[iMagWeapon].field[wFixDamage].text = "(" & hero.child[iMagWeapon].field[wDamageTbl].arraytext[iX] & ") x2"


endif
endif
any clues as to why it works with a rapier but not a battle axe or light mace???
stuartwaring is offline   #6 Reply With Quote
stuartwaring
Member
 
Join Date: Jan 2015
Location: Wellington, NZ
Posts: 91

Old November 30th, 2015, 03:24 PM
Also noted that if it is flaming, it displays as (1d6+21 plus 1d6 fire) x2 plus 1d6 fire.

any idea why the "plus 1d6 fire) appears twice?

Edit Figured out a way to stop it

Code:
hero.child[iMagWeapon].field[wDamExtra].text = ""
Note the script is running in the Render phase, so it is only a visual thing.

Last edited by stuartwaring; November 30th, 2015 at 05:02 PM. Reason: fixed flaming issue
stuartwaring is offline   #7 Reply With Quote
ShadowChemosh
Senior Member
Volunteer Data File Contributor
 
Join Date: Jan 2010
Location: Chicago, IL (USA)
Posts: 10,729

Old November 30th, 2015, 04:49 PM
Quote:
Originally Posted by stuartwaring View Post
I now have it sort of working - it works for my primary weapon, but if i add a different legendary weapon it no longer works.
This is because you are using "hero.child" instead of a foreach loop. So hero.child goes and gets your the "very" first iMagWeapon (custom weapon gizmo) on the character. That is it just the very first one.

Foreach loop does a Loop finding "each" weapon or Pick on the hero and does your change to each one. That would be the reason the VS feat script was doing the foreach loop so that I did the change to the Number of Weapons the character has (ie from one weapon to MANY weapons).

In your case you may wish to look for a specific tag in the foreach loop for weapons that have the foe-biting Ability. As really that is all you care about. Check the tags on the Weapon to see if any say "Foe-Biter" ability tag.

Hero Lab Resources:
Pathfinder - d20pfsrd and Pathfinder Pack Setup
3.5 D&D (d20) - Community Server Setup
5E D&D - Community Server Setup
Hero Lab Help - Hero Lab FAQ, Editor Tutorials and Videos, Editor & Scripting Resources.
Created by the community for the community
- Realm Works kickstarter backer (Alpha Wolf) and Beta tester.
- d20 HL package volunteer editor.
ShadowChemosh is offline   #8 Reply With Quote
ShadowChemosh
Senior Member
Volunteer Data File Contributor
 
Join Date: Jan 2010
Location: Chicago, IL (USA)
Posts: 10,729

Old November 30th, 2015, 04:53 PM
Quote:
Originally Posted by stuartwaring View Post
Also noted that if it is flaming, it displays as (1d6+21 plus 1d6 fire) x2 plus 1d6 fire.

any idea why the "plus 1d6 fire) appears twice?
The background component must be adding it to the display text.... Hmmm

You could loop through all the Extra Weapon arrays and set to blanks so that they are not added in again by the background component. I would do this in the Render timing really early.

Hero Lab Resources:
Pathfinder - d20pfsrd and Pathfinder Pack Setup
3.5 D&D (d20) - Community Server Setup
5E D&D - Community Server Setup
Hero Lab Help - Hero Lab FAQ, Editor Tutorials and Videos, Editor & Scripting Resources.
Created by the community for the community
- Realm Works kickstarter backer (Alpha Wolf) and Beta tester.
- d20 HL package volunteer editor.
ShadowChemosh is offline   #9 Reply With Quote
stuartwaring
Member
 
Join Date: Jan 2015
Location: Wellington, NZ
Posts: 91

Old November 30th, 2015, 05:01 PM
Quote:
Originally Posted by ShadowChemosh View Post
This is because you are using "hero.child" instead of a foreach loop. So hero.child goes and gets your the "very" first iMagWeapon (custom weapon gizmo) on the character. That is it just the very first one.

Foreach loop does a Loop finding "each" weapon or Pick on the hero and does your change to each one. That would be the reason the VS feat script was doing the foreach loop so that I did the change to the Number of Weapons the character has (ie from one weapon to MANY weapons).

In your case you may wish to look for a specific tag in the foreach loop for weapons that have the foe-biting Ability. As really that is all you care about. Check the tags on the Weapon to see if any say "Foe-Biter" ability tag.
I was using a foreach loop, but that didnt work either, hence my attempt to change it to this. I could try and reinstate the foreach loop, but would I be searching in BaseWep for the Foe-Biting tag?

I also tried deleting the rapier, and it wouldnt apply to another weapon then either, hence my confusion!

I also fixed the 1d6 plus fire thing - see edited post
stuartwaring is offline   #10 Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -8. The time now is 10:00 AM.


Powered by vBulletin® - Copyright ©2000 - 2024, vBulletin Solutions, Inc.
wolflair.com copyright ©1998-2016 Lone Wolf Development, Inc. View our Privacy Policy here.