View Single Post
Sendric
Senior Member
 
Join Date: Jul 2010
Posts: 3,147

Old March 6th, 2021, 08:06 AM
Quote:
Originally Posted by Bloodwolf View Post
OK. I'm not wrapping my head around it for some reason. I've seen that script and it disables all special abilities for a skeleton. For some reason it just isn't clicking how to make it go from all special abilities to just Supernatural and Spell Like abilities while leaving the Extra abilities active.

My work around was to let it disable all of them and then bring them back through an adjustment category that would let you pick the base dragon type. Crude and extra work but doable.
foreach loops search through all things from a component and then do something to them. The where "" can further define the search. So, using the example above, I'll go through piece by piece:

This searches for all the things on the hero that are specials (BaseSpec is a component tag).

Code:
foreach pick in hero from BaseSpec
It further reduces the list by ignoring those with certain tags as indicated with a "!"

Code:
 where "!SpecSource.Undead & !SpecSource.Skeleton & !thingid.fSimple"
then assigns a tag to each thing found to fit the criteria and exits:
Code:
perform each.assign[Helper.SpcDisable]
   nexteach
The piece you'll be most interested in is the where "" section. You'll want to include the tag that appears on things with "Ex" with a "!" in front of it. Off the top of my head, it might look something like:

Code:
where "!AbilType.Extra"
Sendric is offline   #1116 Reply With Quote