View Single Post
zarlor
Senior Member
 
Join Date: Nov 2010
Location: Metairie, LA, USA
Posts: 1,819

Old December 3rd, 2013, 05:58 AM
Let's see, the closest similar code snippet I have is at pre-traits/5000 with the following:

Code:
foreach pick in container where "thingid.skKnow"
   if (compare(lowercase(eachpick.field[domDomain].text),"arcane") <> 0) then
      perform eachpick.field[trtRoll].modify[+,1,"Your Edge Name"]
   endif
nexteach
So obviously you need to change the +, 1 to -,1 and otherwise you should just be able to remove the if and endif lines completely, since you want it to apply to all of them. So something like:

Code:
foreach pick in container where "thingid.skKnow"
      perform eachpick.field[trtRoll].modify[1,1,"Name of the thing that does this"]
nexteach

Lenny Zimmermann
Metairie, LA, USA

Data files authored (please let me know if you see any issues with any of these if you have/use them):
Official (In the downloader)
50 Fathoms, Deadlands: Hell On Earth, Deadlands: Noir, East Texas University, Necessary Evil (requires Super Powers Companion), Pirates of the Spanish Main, Space 1889 (original file by Erich), Tour of Darkness, Weird War II, Weird Wars: Rome
Coming Eventually
Evernight (LWD has completed their review but I have some fixes to make first... although Pinnacle mentioned this might get an overhaul to SWADE so I may just wait for that first. If you just HAVE to have this now, though, just PM me)
zarlor is offline   #2 Reply With Quote