PDA

View Full Version : Effects coding question



kaernunnos
August 23rd, 2019, 12:18
Do effects that accept (N) or (D) allow for a character level adjustment? For example, can I do
RESIST: 2 + CL for the Paladins Retributive strike resistance to damage effect?

Gwydion
August 23rd, 2019, 13:01
I think you can do that as follows: RESIST: 2[LVL]

However, I believe it would use your total level for the bonus though. See the wiki almost at the very bottom:

https://www.fantasygrounds.com/wiki/index.php/PFRPG2_Effects

Ckorik
August 23rd, 2019, 14:57
More like this?

Retributive Strike; RESIST: 2+[LVL]

*if* that works it would only work from the action tab - set the duration to 1 - expire on single usage. If it doesn't work - use the same line but hard code the level variable - some things are just easier to hard code, then change it on level up.

Kelrugem
August 23rd, 2019, 15:07
I think you can do that as follows: RESIST: 2[LVL]

However, I believe it would use your total level for the bonus though. See the wiki almost at the very bottom:

https://www.fantasygrounds.com/wiki/index.php/PFRPG2_Effects

Just tested it: [CL] exists in Pathfinder 2, too :) This reads the CL of the spell class from which that effect comes from :) (it is not in the wiki as for 3.5e/PF1, too, but in both rulesets [CL] seemingly exists besides [LVL]; secret effects one finds by writing extensions :D) (if needed in your situation :) )

EDIT: Oh, it does not exist, Trenloe? Just tested it, seems to work :) (but I am not playing PF2, so maybe I misunderstand something and I do it wrong? I can provide a picture, [LVL] takes the total level and [CL] only the CL of the corresponding spellclass)

EDIT2: But adding something to it seems not to work (or I do not know the syntax), so it was probably about that and not [CL] directly :) (but maybe still useful for someone to know the existence of [CL])

EDIT3: okay, there is seemingly a syntax for adding something already, see Trenloe's post below :) (I thought there has to be some but I didn't remember the syntax anymore)

Trenloe
August 23rd, 2019, 15:07
Thanks for pointing out the need for this. It is in the current ruleset - use [+-]X [other tag] - for example: 2 [LVL] (note the space between 2 and [) would give 2 + level.

Logged as RS2.042 for clarification and addition in future release.

Roboconn
August 23rd, 2019, 15:14
Is there a way to name an effect so when it is applied to a creature it just reads as its name instead of the adjustment coding. An example is could I name and effect rage and when applied it just reads as Rage instead of AC:-1; DMG:2

Ckorik
August 23rd, 2019, 15:24
Is there a way to name an effect so when it is applied to a creature it just reads as its name instead of the adjustment coding. An example is could I name and effect rage and when applied it just reads as Rage instead of AC:-1; DMG:2

You can name the effect like this:
Rage; AC:-1; DMG: 2

That way you can always tell what ability put the effect on.

Trenloe
August 23rd, 2019, 15:32
Is there a way to name an effect so when it is applied to a creature it just reads as its name instead of the adjustment coding. An example is could I name and effect rage and when applied it just reads as Rage instead of AC:-1; DMG:2
Nope. You can either use the pre-defined (in the ruleset code itself) conditions or the effects, there's not a way to hide custom effects. You can do as Ckorik mentions - put a description in front of the effects.

Trenloe
August 23rd, 2019, 15:33
Release 5 will have some changes to the PC specific effects. See the details here:

https://www.fantasygrounds.com/wiki/index.php/PFRPG2_Effects#PC_Specific_Notes

Trenloe
August 23rd, 2019, 15:37
Do effects that accept (N) or (D) allow for a character level adjustment? For example, can I do
RESIST: 2 + CL for the Paladins Retributive strike resistance to damage effect?
Actually, there is already code in the ruleset to do this - but it's not obvious. You could do this:

2 [CL]

kaernunnos
August 23rd, 2019, 19:26
Actually, there is already code in the ruleset to do this - but it's not obvious. You could do this:

2 [CL]

Will do. Thanks for the help!

darrenan
August 23rd, 2019, 19:46
The documentation is a little confusing. In the left (PC tag) column you show the H, X, - outside the braces, and in the Notes column examples you show it inside the braces. Does either form work? For example, the X line has [3LVL] as an example. But a few lines above for CL you have 2 [CL] as the example. Is the latter example addition rather than multiplication?

If the [tag]+X form is supported, then why do we need the confusing space version (which most people will confuse with multiplication)?

Trenloe
August 23rd, 2019, 20:09
The documentation is a little confusing. In the left (PC tag) column you show the H, X, - outside the braces, and in the Notes column examples you show it inside the braces. Does either form work?
Yes, it is confusing. That's based on the standard documentation. I briefly thought about changing it, but couldn't come up with a quick change that wouldn't be equally confusing - but using square brackets twice is confusing - hence why I provided the examples. Use the examples as the actual form needed.


For example, the X line has [3LVL] as an example. But a few lines above for CL you have 2 [CL] as the example. Is the latter example addition rather than multiplication?
Yes, the latter is for multiplication.


If the [tag]+X form is supported, then why do we need the confusing space version (which most people will confuse with multiplication)?
[tag]+X is new (available in release 5) and is less confusing. But I've kept the old form for backwards compatibility.

Trenloe
August 23rd, 2019, 20:22
The documentation is a little confusing.
I've made some changes. Hopefully it's a little less confusing! :)

Ckorik
August 24th, 2019, 01:57
This is awesome - the revised examples are *much* clearer now also - THANK YOU!

Trenloe
August 24th, 2019, 01:59
This is awesome - the revised examples are *much* clearer now also - THANK YOU!
Glad it's better all round now! :)

MaxAstro
August 24th, 2019, 22:57
Is there any reason to use CL instead of LVL? I can't think of any situation where there would actually be a difference in PF2e...