Senior Member
Join Date: Nov 2012
Posts: 208
|
I have weapons defined like this:
<thing id="wpUnarm" name="Unarmed Strike" description=" " compset="Melee" holdable="no"> <tag group="WepDamage" tag="1"/> <tag group="WepCat" tag="wcSimple"/> <tag group="WepProp" tag="Bludg"/> <tag group="WepProp" tag="OffHand"/> </thing> and an Armory list like this: <portal id="arMelee" style="tblNormal"> <table_dynamic component="Gear" showtemplate="arWpnPick" choosetemplate="arWpnThing" buytemplate="BuySizCash" selltemplate="SellCash"> <list><![CDATA[ component.WeapMelee & !Hide.Weapon ]]></list> <candidate inheritlist="yes"><![CDATA[ !Equipment.Natural & !component.MagicStaff & !User.HexbladeWp &!Helper.FeatHack ]]></candidate> <description/> <headertitle><![CDATA[ @text = "Melee Weapons" ]]></headertitle> <additem><![CDATA[ @text = "Add New Melee Weapons" ]]></additem> </table_dynamic> </portal> Now I want to make the display of some of the weapons based on if a specific Hero Tag is present (like Hero.IsSpecial). How can I do this? I tried using <containerreq phase="Initialize" priority="10">Hero.IsSpecial</containerreq> in the weapon definition, but the effect I got was that - in this example the tag Hero.IsSpecial was present only if a special class (which is part of houserules) was at least of level 10 - when I leveled up the character to level 10 the weapon still was not there. Only when I leveled some more - or saved the character and reloaded - the weapon appeared. What am I doing wrong? Or is there a better way to do this? Thanks in advance. Best regards, MagicSN |
#1 |
Senior Member
Lone Wolf Staff
Join Date: May 2005
Posts: 13,215
|
See the !Hide.Weapon part of the list expression? That's what's set up to let you hide weapons.
|
#2 |
Senior Member
Join Date: Nov 2012
Posts: 208
|
Quote:
Thanks. MagicSN |
|
#3 |
Senior Member
Volunteer Data File Contributor
Join Date: Jan 2011
Location: Nowhere, Virginia
Posts: 3,633
|
Quote:
Code:
foreach pick in hero from BaseWep where "thingid.?" perform eachpick.assign[ the tag ] nexteach RavenX Pronouns: She/Her Please do not PM me to inquire about datafiles I coded "for personal use" such as Exalted, World of Darkness, AD&D, or Warhammer 40K Roleplaying. I appreciate your interest, but I do not own the Intellectual Property rights to these game systems. Nor do I have permission from any of the Publishers to distribute the data files. As such, I cannot distribute the work I have done with community on these files. They are "for personal use" only. Thank you. I am far too busy these days to answer emails. If you message me here there is no guarantee I will get back to you at all. |
|
#4 |
Senior Member
Join Date: Nov 2012
Posts: 208
|
Quote:
foreach pick in hero from WeapMelee perform eachpick.assign[Helper.Disable] perform eachpick.assign[Hide.Weapon] nexteach Instead all Weapons where still there. I tried the same with WeaponBase, but this had no different result. Any ideas? Thanks. Best regards, MagicSN |
|
#5 |
Senior Member
Lone Wolf Staff
Join Date: May 2005
Posts: 13,215
|
What list expression are you using on your table?
Also, are these bootstrapped weapons, or user-added weapons that you're testing with? User-added picks may never be hidden on the table they were added to. Unarmed strike is presumably bootstrapped to all characters, so this shouldn't be a problem for that weapon. |
#6 |
Senior Member
Join Date: Nov 2012
Posts: 208
|
Quote:
The remaining issue is with a houseruled spec where I would want the user-added weapon only to appear if the Dragon Descendant Spec is chosen for the character in question. You see my table in the first post. And here is the weapon: <thing id="wpDrClaw" name="Half-Dragon: Claw" description=" " compset="Melee" holdable="no"> <tag group="WepDamage" tag="1d6p"/> <tag group="WepCat" tag="wcMartial"/> <tag group="WepProp" tag="Versatile"/> <tag group="WepProp" tag="Slashing"/> <tag group="WepProp" tag="Light"/> <tag group="WepProp" tag="Finesse"/> <pickreq thing="ppFgtDrag"/> </thing> The weapon is not bootstrapped. The matter is about the Armory, that it should not appear there, so that it is not even selectable for a character with the wrong spec. Currently I have it shown there only as proficient with the spec, but it would be nicer, if it would not appear at all, if the character has the wrong spec. Thanks again! MagicSN |
|
#7 |
Senior Member
Lone Wolf Staff
Join Date: May 2005
Posts: 13,215
|
I'd use a prereq to prevent them from selecting it without the prerequisite ability.
|
#8 |
Senior Member
Join Date: Nov 2012
Posts: 208
|
|
#9 |
Senior Member
Lone Wolf Staff
Join Date: May 2005
Posts: 13,215
|
Normally, if an ability gave you claws, I'd just bootstrap it - the user wouldn't need to add the claws separately from the ability.
|
#10 |
|
|