Back again. So, I've managed to get the basics of the amulet working. When equipped, the amulet applies the ghost touch property to everything the creature is carrying. My problem is that I only want it to reduce the equipment's weight to zero when the wearer is incorporeal. I'm having problems with the requirement in the if/then statement. What I have so far is as follows:
Code:
if (field[gIsEquip].value <> 0) then
foreach pick in hero from MyGear
perform eachpick.assign[Ability.iGhostTch]
nexteach
if (#hasability[raIncorpor] <> 0) then
foreach pick in hero from MyGear
eachpick.field[gWeight].value = 0
nexteach
endif
endif
That *should* work, but for some reason it doesn't. It should be setting the weight of equipment to 0 for an incorporeal creature, but it doesn't. I'm not sure what I did wrong in the second "if/then" statement. I don't know what the proper condition should be to tell the script to look at whether the hero has the incorporeal ability.
Thoughts? Thanks!