Scripting Question
I am pretty sure I've done this before, but for the life of me I can't remember how.
I am trying to set up an Adjustment that allows you to select a DamageRes from a drop down in an Adjustment, then use a perform hero.assign[DamageRes.xxx] where xxx is the chosen damage type. For the life of me I can't get a DamageRes or a DamageType to be selected from an Adjustment . . . Any ideas? Or am I wrong in thinking this is possible from an Adjustment? :confused::confused::confused: |
You mean like on the adjustment menu you have your custom expression like
component.DamageType or component.DamageType & (DamageRes.dtCold|DamageRes.dtFire|DamageRes.dtLig htnin|DamageRes.dtPoison) and your script looks something like this first/100 Code:
~ If we're disabled, do nothing & |
I knew there was a way. For the life of me I couldn't remember it and I couldn't find where I had done it before.
Thanks. I'm just builing a bunch of spell adjastments for myself like mage Armor, Shield, Absorb Elements, etc. |
Well, I finally got around to trying out the scripting you presented and I have similar issues to what I was already having.
component.DamageType & (DamageRes.dtCold|DamageRes.dtFire|DamageRes.dtLig htnin|DamageRes.dtPoison) That gives my a list of everything, probably includign what I want if I could find it. :) component.DamageType This me no options at all. I also tried: component.DamageRes and got nothing. When you have a moment or two, could you try create an Adjustment and see what you get. Maybe my HL is messed up . . . |
Interesting, I just tried putting together a quick adjustment with the Custom Expression of
Code:
component.DamageType & (DamageRes.dtCold|DamageRes.dtFire|DamageRes.dtLightnin|DamageRes.dtPoison) Hope this helps.... - Bob |
Selecting all things from the drop down worked. LW must have made a change. I don't remember ever having to select that before . . .
I could be wrong though. I used the following for Absorb Elements: Quote:
|
Anyone following this conversation, free tip, you can get the Combined Damage types (like bludgeoning, piercing or slashing from nonmagical weapons) via component.DamComType
and your push/pull tags are DamComRes.? for resistance DamComImm.? for immunity my personal catch-all damage resistance adjustment goes like this: Custom Expression: (component.DamageType | component.DamComType) Restrict First List to: All Things My code, which I run at first/100 but can be run anywhere early: Code:
~ If we're disabled, do nothing & |
@dungeonguru good info! :)
|
All times are GMT -8. The time now is 07:09 AM. |
Powered by vBulletin® - Copyright ©2000 - 2024, vBulletin Solutions, Inc.
wolflair.com copyright ©1998-2016 Lone Wolf Development, Inc. View our Privacy Policy here.