RPTools.net

Discussion and Support

Skip to content

It is currently Sat Aug 19, 2017 4:09 am 




Forum rules


Discussion regarding lmarkus001's framework only. Other posts deleted without notice! :)



Reply to topic  [ 22 posts ]  Go to page 1, 2  Next

Previous topic | Next topic 

  Print view

Author Message
 Offline
Kobold
 
Joined: Sun Jun 15, 2008 10:28 pm
Posts: 24
 Post subject: Area of Effect Macros
PostPosted: Sat Jan 08, 2011 1:17 am 
Any chance someone has developed some AOE macros? Specifically looking for something that does Inspire Courage on all nearby PCs (or better yet, visible PCs). Also things like Channel Positive Energy (I play Pathfinder).

Mass selecting PCs and toggling their modset seems to take a LONG time to process and often asks me each time for each PC about a variable (like bard level). Any help is appreciated as my coding skills are primitive at best.


Top
 Profile  
 
User avatar  Offline
Site Admin
 
Joined: Mon Jun 12, 2006 12:20 pm
Posts: 12078
Location: Tampa, FL
 Post subject: Re: Area of Effect Macros
PostPosted: Sat Jan 08, 2011 3:10 am 
Jazlizard wrote:
Any chance someone has developed some AOE macros? Specifically looking for something that does Inspire Courage on all nearby PCs (or better yet, visible PCs). Also things like Channel Positive Energy (I play Pathfinder).

I don't know of any. Wrathgon is planning to add some type of template system to his spell manager, but that will merely choose which tokens should have the modsets applied; it won't be anything that constantly monitors the distance from token A to token B and takes action based on the result.

Quote:
Mass selecting PCs and toggling their modset seems to take a LONG time to process and often asks me each time for each PC about a variable (like bard level). Any help is appreciated as my coding skills are primitive at best.

It's best to have each player update their own modsets. That way the execution time is spread out over the entire group. And if you're changing them on a half-dozen tokens and a player is editing a token, your change may be lost when they save their changes.


Top
 Profile  
 
 Offline
Kobold
 
Joined: Sun Jun 15, 2008 10:28 pm
Posts: 24
 Post subject: Re: Area of Effect Macros
PostPosted: Sat Jan 08, 2011 5:24 pm 
Yup, that's probably what I'll do.

Is there anyway to have it look at a certain token for the bard level instead of having to input it all the time? That would speed things up a bit.


Top
 Profile  
 
 Offline
Great Wyrm
 
Joined: Tue May 26, 2009 7:51 pm
Posts: 2060
Location: Philadelphia, PA
 Post subject: Re: Area of Effect Macros
PostPosted: Sat Jan 08, 2011 5:58 pm 
It wouldn't know unless the framework added in a property to hold all of the characters classes and foreach thru each token looking for a Bard. Problem with that is that if there are multiple Bards it would not know. Or, the Spell Manager could automatically apply these types of things. Personally, I like having the ability to control what tokens receive the mods and which ones do not.


Top
 Profile  
 
User avatar  Offline
Site Admin
 
Joined: Mon Jun 12, 2006 12:20 pm
Posts: 12078
Location: Tampa, FL
 Post subject: Re: Area of Effect Macros
PostPosted: Sat Jan 08, 2011 6:16 pm 
Jazlizard wrote:
Is there any way to have it look at a certain token for the bard level instead of having to input it all the time?

Yes, but you'd have to modify the predefined modset. Basically, the modset uses a variable, Bard_Level I think, that is undefined hence the popup dialog asking for the value.

But you could change the modset so instead of using Bard_Level it used getProperty("Level", tokenID). But I don't know what to put in for tokenID and you wouldn't want to hard-code it or it wouldn't work for other bards. So the popup is probably the best way to handle it.

(I suppose you could assume that the bard's ability is also going to affect the bard. In which case you could make a list of all selected tokens and check each one to see what classes they have and then take the one that's a bard. But now it doesn't work if there's more than one bard selected, nor does it work in this FW since the FW doesn't keep track of classes, only CR.)


Top
 Profile  
 
User avatar  Offline
Giant
 
Joined: Mon May 04, 2009 2:44 pm
Posts: 214
 Post subject: Re: Area of Effect Macros
PostPosted: Sat Jan 08, 2011 8:41 pm 
The area area of effect thing is easy enough, but I don't use lmarkus' framework so I was trying to figure out with Jaz on how to do this. What I'm not sure is where the bonus would be applied.

I tried looking through to figure it out, but Linday's code is way over my head.

If someone could point out to me what to add a value to so the bonuses work properly, then I can help with the rest.

Skester.


Top
 Profile  
 
 Offline
Great Wyrm
 
Joined: Tue May 26, 2009 7:51 pm
Posts: 2060
Location: Philadelphia, PA
 Post subject: Re: Area of Effect Macros
PostPosted: Sun Jan 09, 2011 12:40 pm 
It is all stored on the property ActiveMods JSON on the token. Look thru the macros for applying the ActiveMod and that is where you can see how the JSON is applied. I am not that good with coding JSON, so can't really help. You can also take a look at Wrathgons old 11g version of his Spell Manager as IIRC it has a way to add Active Mods based on the spell being cast.


Top
 Profile  
 
User avatar  Offline
Great Wyrm
 
Joined: Fri Mar 28, 2008 11:30 pm
Posts: 1865
Location: Layfayette Hill, PA
 Post subject: Re: Area of Effect Macros
PostPosted: Fri Jan 14, 2011 5:50 pm 
Jazlizard wrote:
Any chance someone has developed some AOE macros? Specifically looking for something that does Inspire Courage on all nearby PCs (or better yet, visible PCs).
Also things like Channel Positive Energy (I play Pathfinder).

Mass selecting PCs and toggling their modset seems to take a LONG time to process and often asks me each time for each PC about a variable (like bard level). Any help is appreciated as my coding skills are primitive at best.


Fundamental approach
. Try to never modify a token that someone else could modify. So, GMs should modify NPCs, and Players should modify their own tokens. The primary reason is if two of you modify at the same time, one of your changes will not occur (and this conflict is really easy to encounter, for example if a player selects their token and starts to move but does not drop it, then anything you do to it will not take hold).

Channel Energy: This exists in the framework, if you choose to channel positive energy to living creatures, all players that have a token in range get a pop-up dialog that they can use to apply healing to the tokens they select (there has to be some human interaction here to make appropriate choices).

Mass application of a mod-set. If you have a mod-set you apply frequently, and the "variable" amount is actually stable (like bard level), then just create a new mod-set that hard codes the bard level. The really easy way to do that for the Bard Inspire Courage is to Edit the version in my framework and rename it to "CharacterNames Inspire Courage" and then change the variable Bard_Level to a fixed integer. When you save, you will now have a new mod-set (it becomes new because you gave it a new name/identifier). Now when you apply that to multiple tokens, you won't be prompted and the application will go faster (although not as fast as having all the players apply it themself... plus this keeps them engaged and knowing what is going on).

_________________
D&D3.5 / Pathfinder Framework


Top
 Profile  
 
User avatar  Offline
Great Wyrm
 
Joined: Fri Mar 28, 2008 11:30 pm
Posts: 1865
Location: Layfayette Hill, PA
 Post subject: Re: Area of Effect Macros
PostPosted: Mon Sep 19, 2011 10:27 am 
Coming soon...

An AE targeting macro that can apply damage and/or apply active-mods!

_________________
D&D3.5 / Pathfinder Framework


Top
 Profile  
 
User avatar  Offline
Site Admin
 
Joined: Mon Jun 12, 2006 12:20 pm
Posts: 12078
Location: Tampa, FL
 Post subject: Re: Area of Effect Macros
PostPosted: Mon Sep 19, 2011 4:13 pm 
Ooo, cool idea!

So are you planning on a list of dropdowns with "typical" damage types (like 5d6 or 3d8?) and then a separate dropdown that lists active mods? That could be really handy for spells that include both (such as Unholy Blight) or swarm creatures (those that have both hp damage and poison come to mind).

I'm not sure how to make this really flexible though. You'll want to be able to allow a save so that damage isn't applied, only half is applied, or full is applied. And it might need to take Evasion into account if it's a Reflex save.

The active mods are similar because I can see needing only a single mod in most cases, but some might require more (such as the blasphemy or color spray spells, which have varying effects depending on the HD of the target).

It'll be interesting to see what you come up with. I've thought about this before and decided it was a pretty big project... :)


Top
 Profile  
 
User avatar  Offline
Deity
 
Joined: Tue Nov 10, 2009 6:11 pm
Posts: 7789
Location: Bay Area
 Post subject: Re: Area of Effect Macros
PostPosted: Mon Sep 19, 2011 4:58 pm 
I would create the spell effects like your EBT and use the summon button to call them in. Seems like the simplest integration with what you have right now.

_________________
Downloads:


Top
 Profile  
 
User avatar  Offline
Great Wyrm
 
Joined: Fri Mar 28, 2008 11:30 pm
Posts: 1865
Location: Layfayette Hill, PA
 Post subject: Re: Area of Effect Macros
PostPosted: Wed Sep 21, 2011 3:33 pm 
I just wanted to whine a bit...

Building HTML Frames is WAY more time consuming than the simple Wiki: input ()dialog! On the plus side, The HTML Frame is cleaner looking and can float so can stay up all the time.

Meanwhile, back to the grind, ick. A VERY PRELIMINARY teaser...

ImageImage

_________________
D&D3.5 / Pathfinder Framework


Last edited by lmarkus001 on Thu Sep 22, 2011 10:42 pm, edited 1 time in total.

Top
 Profile  
 
 Offline
Great Wyrm
 
Joined: Tue May 26, 2009 7:51 pm
Posts: 2060
Location: Philadelphia, PA
 Post subject: Re: Area of Effect Macros
PostPosted: Wed Sep 21, 2011 4:36 pm 
Looks great! Is there any way you can use JSON for the passing variable? This way I can work out a way to tie Wrathgon's Spell Manager to this?

_________________
Image
Time-Zone information UTC -5


Top
 Profile  
 
User avatar  Offline
Great Wyrm
 
Joined: Fri Mar 28, 2008 11:30 pm
Posts: 1865
Location: Layfayette Hill, PA
 Post subject: Re: Area of Effect Macros
PostPosted: Wed Sep 21, 2011 4:52 pm 
You mean like:

Code:
{
    
"processTarget""Fire in the Hole",
    
"range""20",
    
"difficulty""10",
    
"caster_level""1",
    
"cl_bonus""0",
    
"save1""reflex",
    
"sr""1",
    
"saveresult1""halfdmg",
    
"modset1""",
    
"ms_save1""na",
    
"modset2""",
    
"ms_save2""na",
    
"save2""reflex",
    
"saveresult2""halfdmg",
    
"id""C0A801076801D181B023000080800100"


8)

_________________
D&D3.5 / Pathfinder Framework


Top
 Profile  
 
User avatar  Offline
Site Admin
 
Joined: Mon Jun 12, 2006 12:20 pm
Posts: 12078
Location: Tampa, FL
 Post subject: Re: Area of Effect Macros
PostPosted: Wed Sep 21, 2011 6:36 pm 
lmarkus001 wrote:
You mean like:

Heh-heh, yeah. ;)

You might consider requiring that the incoming data already be properly structured for your use. For example, the incoming JSON could contain an object that has the range and other fields set up as necessary for use in the getTokens function.

And any field which might even remotely be used to hold more than one value should be an array. From the sample you posted I'm thinking of the "save1" actually being "saves" and the "id" field being an array of IDs, for example.

I'm thinking something like:

Code:
{
    
"processTarget""Fire in the Hole",
    
"range": { range20metric"ONE_ONE_ONE", ... },
    
"difficulty""10",
    
"caster_level""1",
    
"cl_bonus""0",
    
"sr""1",
    
"saves": [
        [ 
"reflex"1"halfdmg" ],
        [ 
"will"1"sickened" ]
    ],
    
"id": [ "C0A801076801D181B023000080800100" ]

I'm thinking that the saves entry would be one array for each possible save. Prior to rolling the saves invoke a "hook" UDF (that runs in the same scope) that normally does nothing. For some spells it might want/need to do extra processing. For example, spells like Unholy Blight need to know a creature's alignment and whether they are outsiders.

Each row in the save array is one save type. The second value is 0="no new roll" and 1="new roll". This allows a single Will save roll to be used multiple times because the third field is a macro that is called to process the saving throw. So the "halfdmg" macro would be passed true/false whether the save succeeded and the token ID of the current token. It applies damage as appropriate based on Evasion and similar feats. The second one makes a new roll (the second element == 1) and passes the true/false of that roll and the token IDs to the "sickened" macro (which applies the states as needed). If the second parameter == 0, it means the same d20 roll of the previous save gets used again. This allows a single Will save to be checked multiple times to see what affect it has. (Hm, maybe overkill. Maybe the roll result and the calculated DC would be enough if passed to the macro? The macro could process the incoming data however it wants.)

By using macros for those fields instead of modsets, more complex work can be done. (Although your modsets can do an awful lot as it is, so maybe just turning a modset on/off would be enough?)

Well, maybe that save stuff is overkill. But it'd be cool for it to be extensible by simply defining new macros when a new spell effect came along...


Top
 Profile  
 
Display posts from previous:  Sort by  
Reply to topic  [ 22 posts ]  Go to page 1, 2  Next

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:

Who is online

In total there is 1 user online :: 0 registered, 0 hidden and 1 guest (based on users active over the past 5 minutes)
Most users ever online was 243 on Sun Nov 04, 2012 6:14 am

Users browsing this forum: No registered users and 1 guest





cron

Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group

Style based on Andreas08 by Andreas Viklund

Style by Elizabeth Shulman