Member
Join Date: Oct 2013
Posts: 46
|
I'm trying to create a magic item that when equipped gives a penalty to a skill. The skill in question is Listen. I tried to mess around with things but I just am not getting the proper coding. Here is what I tried.
if (field[gIsEquip].value <> 0) then #competencebonus[hero.child[kListen].field[Pentaly].value -= 1] endif The error I am getting says incorrect parameter count for macro reference. Does anyone know what I might be doing wrong for this to not work? Last edited by saintaurik; March 30th, 2023 at 10:01 AM. Reason: typo |
#1 |
Senior Member
Join Date: Mar 2013
Location: Melbourne, Australia
Posts: 1,124
|
That macro has to be in the format:
#competencebonus[pick, bonus] Without checking I'd say that should be: #competencebonus[hero.child[kListen], -1] Current RPG's: Pathfinder (GM), Pathfinder (Player), Gamma World (GM, Pathfinder homebrew). HeroLab: 3.5 & Pathfinder. HL User Files for PF: Greyhawk Setting, Gamma World (WIP). DM and player of D&D since 1980. Last edited by Dami; March 30th, 2023 at 10:56 PM. |
#2 |
Member
Join Date: Oct 2013
Posts: 46
|
Thanks Dami for helping. It does compile however it does not give the penalty to the listen skill when the item is equipped. Maybe I am missing a setting or something?
|
#3 |
Senior Member
Join Date: Mar 2013
Location: Melbourne, Australia
Posts: 1,124
|
Maybe it doesn't like the penalty... or something else on the character already gives a Listen competence bonus. I can't find an item in d20 to use as a reference - if you can think of any item that applies a penalty, try looking at how that's coded.
Current RPG's: Pathfinder (GM), Pathfinder (Player), Gamma World (GM, Pathfinder homebrew). HeroLab: 3.5 & Pathfinder. HL User Files for PF: Greyhawk Setting, Gamma World (WIP). DM and player of D&D since 1980. |
#4 |
Senior Member
Join Date: Jan 2011
Location: Quebec, QC, Canada
Posts: 469
|
Timing of your script?
|
#5 |
Senior Member
Join Date: Jul 2010
Posts: 3,151
|
Are you including a line of code to only activate if the item is equipped? The entire script should look like this:
Code:
~ If not equipped get out now! doneif (field[gIsEquip].value <> 1) #competencebonus[hero.child[kListen], -1] Also make sure there aren't other competence penalties being applied by other things as they won't stack. If it still won't work, please provide the data file and I'll take a look. Last edited by Sendric; April 2nd, 2023 at 06:13 AM. |
#6 |
Thread Tools | |
Display Modes | |
|
|