• Please note: In an effort to ensure that all of our users feel welcome on our forums, we’ve updated our forum rules. You can review the updated rules here: http://forums.wolflair.com/showthread.php?t=5528.

    If a fellow Community member is not following the forum rules, please report the post by clicking the Report button (the red yield sign on the left) located on every post. This will notify the moderators directly. If you have any questions about these new rules, please contact support@wolflair.com.

    - The Lone Wolf Development Team

Make a weapon use a different skill

basselope

Member
Does anyone know if it is possible to create a weapon that uses a different skill? If so, do you know how to do it? I have been able to create every other aspect of the weapon and the skill and even an edge that relies upon the skill. I just can't get it to show on the character sheet as associating with it. Now, I know I could just print out the character sheet and put a line through it and write in the correct value, but I would prefer not to.
 
I would do this with a mechanic that searches for the weapon, and then changes its skill. When coming up with how to change the die so that it can have a d14, d16, d18, d20, d22, or d24 Fighting skill I figured out how to do this.

http://forums.wolflair.com/showthread.php?t=53040

Make it use whatever skill you want it to use, so change Fighting to whatever you want it to be.

The trickiest part will be the "foreach pick in hero from.. " because that really depends on what you are looking for. You can make it look for a specific ID for a specific weapon, or if you ware going for a class of weapons you can make it look for those. If you have multiple weapons, like maybe several types of lightsabers you would be best served either using a tag or even easier is to have a similar ID syntax that only changes at the end. So for different lightsabers, you might have weapon ID that are these: wpLIGHTred, wpLIGHTblu, wpLIGHTgrn, wpLIGHTyel. The wildcard that looks for them would be "wpLIGHT?".

Phase Final
Priority 10000

Code:
var finalbonus as number
var thisbonus as number
var finaldie as string
var finaltext as string
var bonustext as string
var dieNumber as number

finalbonus = hero.child[skFighting].field[trtNetRoll].value 
thisbonus = 0
finaldie = ""
finaltext = ""
bonustext = ""
dieNumber = #trait[skFighting]


~ Cap die number at 12
if (dieNumber >= 6) then
      dieNumber = 6
endif

~ Double the dieNumber so that it will be a die
dieNumber = dieNumber * 2
finaldie = "d" & dieNumber

foreach pick in hero from WeapMelee
      bonustext = ""
      thisbonus = finalbonus
      thisbonus += eachpick.field[wpBonus].value
      thisbonus += eachpick.field[wpPenalty].value

      if (thisbonus > 0) then
           bonustext = "+" & thisbonus
      endif

      if (thisbonus < 0) then
           bonustext = thisbonus
      endif

      finaltext = finaldie & bonustext
      eachpick.field[wpNetAtk].text = finaltext
nexteach
 
Last edited:
That is a little advanced for me, so I'll have to play around with it.

However, thanks for the advice! I can't wait to try it out.
 
What I'm trying to do is a Zen Archery setup for a player. I have been able to create the skill Zen Archery to work off of Spirit. I have also been able to duplicate some other Edges that had different requirements to work with Zen Archery instead. Where I'm having a problem is when I purchase a Bow, it uses the Shooting skill. I have tried creating a separate Bow just for use with this skill, let's call it a Zen Bow just for convenience. However, I am not sure how to get it to use the Zen Archery skill instead of Shooting.

Does that clarify a little bit?

Also, thanks for your help.
 
OK, this one was easy. I just tested it to make sure that I am not pulling things out of my rear.

Inside the Zen Archery edge that lets you use the zen archery skill, make an eval script

Phase: Final
Priority: 10000

Code:
var finalbonus as number
var thisbonus as number
var finaldie as string
var finaltext as string
var bonustext as string
var dieNumber as number

finalbonus = hero.child[skZen].field[trtNetRoll].value 
thisbonus = 0
finaldie = ""
finaltext = ""
bonustext = ""
dieNumber = #trait[skZen]


~ Cap die number at 12
if (dieNumber >= 6) then
      dieNumber = 6
endif

~ Double the dieNumber so that it will be a die
dieNumber = dieNumber * 2
finaldie = "d" & dieNumber

foreach pick in hero from WeapRange
   if (eachpick.tagis[Weapon.Bow] = 1) then
      bonustext = ""
      thisbonus = finalbonus
      thisbonus += eachpick.field[wpBonus].value
      thisbonus += eachpick.field[wpPenalty].value

      if (thisbonus > 0) then
           bonustext = "+" & thisbonus
      endif

      if (thisbonus < 0) then
           bonustext = thisbonus
      endif

      finaltext = finaldie & bonustext
      eachpick.field[wpNetAtk].text = finaltext
   endif
nexteach

You might have to change the skill tag from skZen to whatever you have it as. If you DO have it as skZen, it is done for you. :) It is in two places towards the start of the script. One for the die rating, the other for any modifiers to it (for example, d12 +1 has a +1).
 
For clarification, the above script will look through Ranged Weapons that have the Special Trait of "Bow Weapon".
 
Back
Top