Looking forward to further developments!
Awesome!!!
Thank You!!
Looking forward to further developments!
Awesome!!!
Thank You!!
GenericActionsLayers.ext - V1.1 - Feature - if you have AdvantagesPA.ext from Advantages Extension loaded then you will have access to the last stored pointer data (cone, circle, rectangle) - FGU provides no way to track or no what pointer shapes are currently in image so have to do this wierd logic to track it myself. As I already do it in this free extension I simply check to see if the function to retrieve it is available on the image. If it is found and data is returned for the last stored pointer data (cone, circle, rectangle) then and it will append "PTRcone" or "PTRcircle" or "PTRsqr" to the current asset name being placed. If it finds the asset in the cache for the current last stored pointer shape it will place that asset on "Generic Actions Ptr" named layer (before the one going to "Generic Actions" layer is placed so that it will be overlayed with the original named asset - layers being layers after all) with the appropriate scale and orientation for the last stored pointer shape. To get rid of the last stored pointer shape YOU MUST use the clear last pointer data map toolbar button - otherwise the last shape placed (visible any longer or not) will be removed. All of this only works if you have "5E: Advantages Pointer Areas" extension loaded. Otherwise, ignore this version update completely. See end of txt file for more details.
Its a TOOL - so obviously you can do what you want with it. The below example actually wipes out the default runs for fireball here I did - which you can tell I was showing a cone and my webm have almost nothing to do with matching what I'm doing :)
https://www.fantasygrounds.com/forum...3&d=1689104869
V1.2 - Feature - new option "Generic Action Layer debug sent to chat" defaulted to "off". When "on" this will send debug information to chat about name lookups and what assets they found if any.
Prevent questions on what is being looked up and what it found. Turn this on and find out for yourselves.
[EDITED IMPORTANT NOTE]
wonderful found another undocumented function - this will solve my scaling issue I think.
local tImageSize = {};
tImageSize.w, tImageSize.h = Interface.getAssetSize(sAsset);
Removed my directions on scaling asset before use.
GenericActionsLayer.ext - V1.3 - Bug/Feature - added corrected scaling for taking into account assets with differing width and height definitions - also added it to debug optional chat output for when FGU bug fails to scale or what the corrected scaling to new width and height values was, if any was done. Added a new option "Generic Action Layer scale for width and height of an asset under a token" defaulted to "2". This allows the previous hardcoded scaling for assets placed behind tokens to be set by user. Valid choices are 1.5, 2, 2.5, and 3. Previously this was 2 only.
This corrects a problem with assets that did not have the same height and width.
Updated video...
https://www.youtube.com/watch?v=8GURalFTFSQ
GenericActionsLayer.ext - V1.4 - Feature - full support of all effects with a hook that replaces the old one with EffectManger.addEffect.
This fully supports all effects added into the CT.
I thought I'd try something and.. well... coolio :)
PC: "They're somewhere in that direction!!!!!"
(and no you can't see arrow until it enters vision of light source - dimly see in the dim then see it as it is close)
https://www.fantasygrounds.com/forum...9&d=1689261177
Here is a painful lesson I'll pass on. If you ever delete your layers yourself - insure your map layers are locked as if you hamhandedly delete the wrong layer your map can dissapear. If its in a module with no changes you can simply refresh it to recover. If however, you had any local changes or it was a local map. Woe be to you for not backing things up!!!
Lesson given.
GenericActionsLayer.ext - V1.5 - Feature - another hook added for onPowerCast. Also, resolved pointer layers now being always on the bottom and added some logging for when no name match is found.
"Maybe" a workaround to this bug of the scaling is to bring up the webm in the Asset window that you are going to place as it actually displays those assets in the Asset window (and I suppose manges to get into the file and get the missing data?). If you bring up every asset you plan to use in the asset window at least once before you start placing assets in lua code then it "appears" to work. Though i've not done enough through testing to state this unequivocally.
Yep running through every webm asset you plan to use through the Asset window so it displays seems to insure any future use will work. Annoying but I can do that before I use stuff with webm placements I suppose.
New pre game prep I suppose to open every webm asset I might use (under campaign/Generic Actions or data/Generic Actions directories) in the Assets window so they play through.
Also, if you refresh the asset folder you have to go play them all again as the webm data is lost by the refresh.
GenericActionsLayer.ext - V1.6 - Bug/Feature - for effect the name will first strip off "[%w%p%s]*:" (everything before : ) from the name before it processes it. This was because a lot of AE5E data had effects with the actual name with some description in front of it ending in a semi-colon. Now put Effects on their own layer "Generic Actions Effects". Duplicate names will always use the last one added into the cache and the campaign/images directory has been fixed so it will always be last so that its assets override the FGU/images directory assets. New option "Manually delete Generic Actions Ptr layer" defaulted to "off". If "on" this will allow map assets under Generic Actions Ptr layer to remain till layer is manually deleted in map UI or the option is turned back on and normal auto deletes start taking effect again. This is only layer not tied to a token location so only one that can stick around. Added "Asset:" to all layer options to keep them together. New map button to "Create visible CT token effects on map in Generic Actions Effects Layer". When selected it will display all matching effect assets on CT tokens currently displayed on host CT. Will also tell how many assets it checked (not same as placed). It will delete the Generic Actions Effects layer and Generic Actions Ptr layer (as this one can be placed with an effect) before it tries to place anything - providing it finds any CT entries for the map the button was selected from.
Also, my here files above (if you don't know don't worry about it) example assets were updated with more stuff following the rules I've written in the .txt file. Which I'm all so sure you've read... sure.
https://www.youtube.com/watch?v=f1kRcQsOi6c
GenericActionsLayer.ext - V1.7 - Bug - now clean the name as other FGU functionality does to remove things after and including "(", "*", and "-" as some names have comments and extraneous things after them. Also remove anything before a ":". Also remove the special characters "€", "$", or "#" that AE5E can put on effects in case they reach this level of the code.
Bug - Yep GenericActionsLayer.ext is not showing the effects added into the DB in the CT - no idea why. May take a while to figure out. They are added in by all indications just not into the CT. And only some of them.
Still issues with CT display of certain effects. Not solved yet. Seems to happen with no extensions also.
GenericActionsLayer.ext - V1.8 - Bug - Action buttons have cast buttons divided into attacks and saves. The cast attack will actually trigger two call backs which can cause name conflicts. I've now distinguished these by appending "Cast" to end of name when its a cast trigger (watch chat you'll see two messages generated - one for cast - one for attack). If you have the debug option on then you'll see what names are being looked up including their defaults.
This will change a few names (maybe) for you if you've already defined a cast attack button. I've updated my "here" cache of examples as I flesh them out for my current campaign with the updated naming.
So people know how I make assets for this extension.
https://www.youtube.com/watch?v=gZco54Xy_cA
GenericActions.ext - V1.46:
GeneircActionsLayer.ext - V1.9:
- Conflict - upped my load order from 99 to 150 to prevent having onDamage code stomped by someone else - I call the original code so won't stomp them.
New stuff not delivered yet... a preview before I test it on Monday's game...
https://www.youtube.com/watch?v=b2AljJKfy4I
Also a playlist with all videos on layers I've made to date - in order of lastest to oldest (as they go out of date the next day though have some useful info in each)
https://www.youtube.com/watch?v=b2Al...JFTxN9LNyJeLZ2
An explanation I made that I don't wish to repeat :)
First you have to realize FGU is not giving me access to much in doing any of this - and I'm using a combination of undocumented calls and my own AdvatagesPA.ext (Advantages) for PTRs (cone/circle/rectangle). Layers are always behind tokens and can not be brought above them. Hence, the scaling and clearing anytime anything moves or happens except with PTRs (options and new stuff I'll show in video I made last night shortly), though PTRs again is also a series of kludges because FGU never tells you when they are placed, when they are in image, or when they are removed (hence AdvantagesPA where I already track the data of the last thing placed). And if that's not enough, the triggers I have access to in order to get these things to pop up are bizarre in some cases - specifically when doing PC action button clicking. You can see this in chat messages - click on a pure weapon attack - you get one trigger (one chat message) - click on a power cast attack or power cast save - and you get two triggers (two chat messages) for the attack and one for the save - click on NPC sheet/CT or PC sheet save and you get... Well its a pain and even I can't remember. So don't confuse the "cast" suffix with anything other than allowing me to separate the names (which can conflict) in attacks where you get two of them - and of course adding that also means... ugh. In the end, this is all just so I can get things to work "good enough" and your best bet is just to not try to understand which names will be looked up in any given situation and have debug on so you can literally SEE which are being looked up or failing to be found. So that is first part.
Second part...
Is covered in bottom of .txt file in forums which I advise you to read. Short story if I'm remembering right is Attack/Save triggers will only have a run asset placed (scaled between two tokens) and the heal/damage will have a run and target token asset placed, and effects will just have a token asset place. As this is just a TOOL you will have to figure out what you like to have appear - in my examples I tend to show a run for the attack and again for the damage but that is purely to show you and you can have the run only appear during attack or only during damage or on both depending on what name matches you have defined. So don't look for LOGIC in a TOOL as its that way because I have no access to anything and have to make it so the assets are temporary. Though I provide a button to show all current effects visible on host CT at any time - provide ability to leave PTRs out till you manually delete or put them back on (as they are not tied to tokens so won't care if something moves away from on top of them).
AND of course the stuff in the video I'm now going to post - which is all new and not to be delivered till after my Monday's game and I see how this all works or what player issues make me come up with yet more kludges. And trust me - this is the klugiest riskiest extension yet. Before this I considered AdvantagesPA my riskiest :)
As far as the ranges - anything with a <underbar>%d following the name will be considered only applied when token is > than its reach to target and will pick the closest defined matching one to scale and place. Again - only if you choose to define it. So optionally you have a name - which can have melee or ranged appended - and a potential PTR<shape> appended after that - and a Keep appended after that (new stuff) - and on top of all that, a <underbar>%d number appended to that. Oblivously lot of name potentials. Use debug to see what its trying to look for.
So ignoring all this - I just look to see if I want a run applied - if so I have ranged or ranged_30 or whatever. And usually define a melee name to go with it. See examples I post in dropbox - if you don't know that that is again - read the forum thread at bottom where I started talking about all this its referenced in there. If I have an effect then its usually where i have just the name or a PTR or both. And if I have a PTR I use keep sometimes if applicable (new). And use debug to show me when I'm not sure. TOOL. User it as you see fit.
You can also make a .mod to hold your assets you just have to make sure they go in the asset diretories I'm looking for - in this example (which I actually use for myself) I zipped up these files and renamed the zip to mod to create it. Key point is it has to be a directory strating with "images" (in FGU app the asset window has buttons up top - this is the one I'll look in) and then the name has to be "Data" (which is where FGU app puts things from its images directory - see it as folder name in Assets window). I put it in Data instead of Campaign so that anything I want to locally override I can simply put in the campaigns/<name of campaign>/images directory.
Attachment 58306
Generic Actions Layer Extension - V1.10 - Features - New "Self" appended to any effect name so that the target (normal name) and source (self name) can be separated. This new "self" name cannot be extracted from CT effect so the display all effects map button will only find non "self" name matches. Not sure what to do about that for now (I'm just making a non self name where required - still not perfect). If you add "Keep" to end of any asset name it will be stored as a separate layer "GA_<name>_<source name>". This new name will check vs any delete node operation to see if it has is an "%.effects.%id" node path and then determine the CT node and label value from that - then form and check the name vs existing layer names and remove any match. How I plan to use this to keep my lazy DM ways is for example - my player Cirrus will do a Fog Cloud spell (I use advantagesPA extension) by using a ptr shape of circle to place where they want the fog cloud - then select targets and apply the effects which will trigger an asset name match on FogCloudPTRCircleKeep.webm and place that 20ft cloud scaled to circle placed in a map layer called GA_fogcloud_Cirrus. When the concentration effect expires or is deleted the layer will be found and also be deleted. The other default layer names have also been shortened so they can be seen (limited MAP UI to display name no way to see full name). The new names are "GA" , "GA Ptr", and "GA Effect". Also when a PTR Keep asset is placed it will check if the original name matches an NPC name and if it does it will place that NPC in the CT and at the center of the PTR. And when that PTR Keep asset is removed it will also check for the matchin NPC and remove it completely also. As I plan to use it - I will have for example a Fog Cloud NPC that has an AURA effect on it - so that when the Fog Cloud effect is reset (without changing duration of course unless you have duplicate effects allowed) it will appear to move the Fog Cloud Asset and the NPC associated with it (invisible). And when effect is removed it will remove the asset and the NPC (including its aura effects on anything). I do this by also using AURA and Equipped Effect Extension for most of these keep type of NPCs. While Fog Cloud NPC does not require AURA as I define it to have a trait defined as Fog Cloud and a custom effect defined as "Fog Cloud; LIGHT: 20/20 darkness". My Flaming Sphere NPC however requires AURA as I have a trait defined as Flaming Sphere and a custom effect defined as "Flaming Sphere; (C); AURA: 5 all; Flaming Sphere; SAVEA: [SDC] DEX (H)(M); SAVEE: [SDC] DEX (H)(M); SAVEDMG: 2d6 fire". The Keep naming option is just a tool and provides you ways to do lots of things. For instance, I may have an invisible assistant GM PC that has a number of traits and custom effects which allow me to trigger keep PTRs asset placement based on pretty much anything I want and simply remove them by removing the effect from my dummy PC (or NPC). Of course, the downside of tools are they allow you to do truly stupid things. I suspect some nut will have 1000 targets and trigger assets and NPCs for each one of them until their map runs out of memory and drops dead. Back up your projects which include your maps IMHO or suffer the consequences.
You can watch new video if you want a clue as to what all this means. But I'm much to invovled in prepping my game with all this stuff to bother with more explanation. Play with it. For sure I'm adding emotes for my players also - but not bothering to explain - you have the Tool - you choose how to use it. Or not. It's "good enough" given the amount of kludging an workarounds I've had to do just to get this much working.
GenericActions.ext - V1.47 - Bug - invisible flanking tokens were giving flanking advantage. Fixed.
GenericActionsLayer.ext - V1.11 - Bug - Display effect assets button was deleting PTRs instead of just effects. Fixed. Other general fixes.
Actually used the new GenericActionsLayer.ext and VLC sounds in a live session.
https://www.youtube.com/watch?v=jq-gXm8yxq4
GenericActionsLayer.ext - V1.12 - Feature - if (P) appears in effect name and it happens to trigger a Keep generic actions asset then it will treat that asset as permanent until the effect itself is deleted. Personally, I can see so many uses for this I'm not going to bother to enumerate them. For sure my examples will have a WayPointSelfKeep.webm and a WayPointSelfPTRCircleKeep.webm that I tested with - but that is truly only a trivial use I can see for this power.
FYI - using paint.net (free app on web I downloaded) and https://pixelied.com/convert/png-converter/png-to-webp to convert all my .png to .webp as some helpful people informed me in discord that .webp takes much less space than .jpg and .png (transparencies).
I should note the debug does not show the name searched before a "self" name - but it is there. And for cast - even though the name Ranged and Melee is not used the point the asset will be placed will reflect whether it was a ranged (between tokens) or melee (on token) distance. Latest update in .mod examples shows this in fireball.webm (placed between source and target(s)) and fireballcastptrcircle.webm (put in center of circle). Both are not keep as this is not something that sticks around nor is tied to an effect.
Bravo. I have a simple question. Apologies if missed this somewhere.
I noticed it parses chat for attacks, ect.. not just effects.
I use AD&D 2e (aka classic dnd ruleset) - In the short time i played with this i managed to get it working when clicking an effect with the matching name of the web and/or animated asset. Aka i got a nice cute light wounds working on targets, as well as a fireball. I simply emulated what i saw in the video, which was to make a generic assets folder loaded with various image assets, and match the name with the effect string.
However I noticed you were shooting bows and swinging swords and vola, it was parsing chat or (n) and checking for a matching named asset. Aka you had it working somehow with attacks, damage and others.
I have the debug on - only time i see it check is when an effect goes off. Damage and attack is no mass.
Im mainly just curious at this point how you did that. If there is some instructions i missed, by all means let me know. Im reading the txt - almost positive it’s the string matching, but just want to be sure. Don’t expect miracles.
Thanks, great work.
happy labor day
As its technically only supported in 5E I assume because the functions I listed at bottom of .txt file that trigger these things are not supported in your ruleset. To be honest I'm shocked it works at all. But I guess some rulesets did not go off the rails completely on rewriting how CORE and things work. So you get partial support by pure luck. Not by my intention - just by luck. So unless using 5E you'll have to take what you get - sorry.
Creating an effect and having it parse for the matching name when said effect fires === good enough for me.
In this case, I just made an effect for Cure Light Wounds called 'curelightwounds' (Heal wasn't triggering the check). Works great.
I don't need it to get too fancy. The fact that it can place something on the image when I click a button is awesome, not to mention the self-cleaning mechanics.
I'll poke around deeper with it and see what else works.
In any event, thanks you.
This is/has always been, a very nice extension and has sure grown a lot since I stopped playing 5e.
I was surprised to see a piece of it pop up in the extension list when I opened up my AD&D game.
Class DnD Ruleset (AD&D 2e)
Love it - even without 80% of the features working.
Only 'effects' trigger an asset check, so in the case of things like cure light wounds, which is simply a 'HEAL' - I made an additional effect 'i.e. CureLightWounds' that I can trigger to get a visual -
Event hooks for Damage, Heal, Save and Cast - don't get raised in this ruleset - but Effect does.
Only thing that's a bummer is the placement and scaling of rays-like effects, like lightning bolts.
With assets like this, it doesn't scale or place the asset correctly (the direction the asset is placed is always a straight line through the token across the x axis) - not adjusted to the correct angle, a line from caster to target.
Additionally it does not scale it properly.
But things that just apply the asset at the token seem fine and scaled correct.
To learn more, I loaded up 5e to try out the full set of capabilities and learn more about it, really robust.
IF I had one wish for this, it would simply be to support the angle/placement computation for ray-like assets.
Just out of curiosity, Is there something I can bring up to the author of the ruleset to make it more compatible with this?
This is just badass.
That's strange because what I'm referring too, worked when I used it in 5e, but not in 2e. Attachment 58764.
I'm probably missing something in the videos or chat, it is a lot to take.
Funny thing is, I had this working in 5e last night, now I'm getting the same result as the image, ;)
Could it be I need to include SELF to give it an origin point to target ? I'll keep poking at it, obviously user error and I missed something in the various conversations.
You do realize I have a examples in the mod I provide somewhere above. You can just look at those if you want to see how the "ray" needs to be oriented. But if memory serves its left to right on x axis of asset. Then the scale is done based on distance between tokens. And of course, you read up on the range differences you can provide if you don't feel scaling one fits your needs. Again - see the dropbox mod I provided. Can't remember the link so I leave that to you as an excerise on how to properly explore this thread - particularly the last 5-10 pages.
I did not know this - I'll keep trying.
I just wanted to add this:
5e vs. 2e -
Here is my lightning bolt working in 5e. I hit CAST and it parses, places and scales correctly.
Attachment 58768
Here it is when I try to add it as an EFFECT.
Attachment 58769
This last image is the result I get in CLASSIC DND Ruleset, no matter what I do. As I was saying before, non of the Event Triggers, like HEAL, SAVE, DAMAGE, ect. get raised in this ruleset.
The only one that seems to work is EFFECT. When you click an EFFECT from powers, or add one manually via the Tracker and manually trigger a rescan from the image, it will work.
But with rays, it places it like the following.
Attachment 58767
IF it can't work with this ruleset, that's fine, but Id sure like to know what I'm doing wrong if it does.
I'll leave it at that for now.
Happy labor day.
I should add - I use : https://github.com/Jules-Bens-Aa/JB2A_DnD5e
Nice collection.
As I always say in all of my extensions - they are for 5E. Where I can see they can partially work in other rulesets I open them up for them but in no way EVER will you ever see in print ANYWHERE that I support anything other than 5E in my extensions. Its the only one I use and the only one I plan to ever support.
As for why things don't work in other rulesets - they tend to do their own things outside of CORERPG standard coding sometimes (a lot of the time) and if I opened up something because it was pure CORE calls its by no means stating it will work in any of them. Look at the text file for this extension for dirt level details - or look at code as all my code is open and not in the vault nor will it ever be.
What does this mean? It means it only works in 5E. But might, if your lucky, have aspects that work in other ones. And that I will be putting 0 effort into supporting those that do not - they vary from non 5E ruleset to non 5E ruleset on what calls they support that I use. Do I wish all rulesets respected the CORERPG standard coding contract? Sure. But they don't. Hence why I don't support them at all.
Why do I open some of my extensions to those other rulesets? Because some parts do work and I was asked. But I still state here - and in all my page 1 extensions - its 5E only. But secretly, in the .txt file - I may say it might work in some other things. No support if they don't :)
Not a problem at all. I was just thrown off when you said “rays work, create your asset correctly” (verbatim).
I’ve been a developer for > 20 years, believe me I understand everything you said and why you chose to unlock it.
Furthermore, I tend to document and heavily comment my source as well ... just for it too not be read through .
Therefore, I try to make an effort to read through everything when someone has taken the time to lay it out such as this.
If you ever have time to poke at it, that is great … if not, that’s absolutely fine as well.
I can tell you, with debugging on, Its definitely falling into the logic of putting it on the screen and attempting to scale/place it ... its just missing something vital or its a sequence issue.
In any event, just curious.
Anyways SilentRuin, thank you again for your help/explanations.
As a developer - you understand that the callbacks I listed in the .txt file are not being called in the all the rulesets outside of 5e. And as I said - feel free to modify the code for your own use to make it call things in whatever world you are running in. I'm not so tight fisted with my code that I don't allow people to do what they want with it. Ideally you could even make an extension of your own that exist on top of mine to override parts to make it do what you want it to do where you want it to do. But for some reason people never want to do that.
If you have a 5E issue feel free to let me know. The other rulesets are "unsupported" unless they happen to call the CORERPG things I'm calling. And any 5E specific things they will not support at all. Hence the blanket "unsupported" statement outside of 5E.
Either way good luck on what you decide to do.
Note to self:
Something in FGU or extension (other than mine that I use) has changed in the last month that caused a longbow attack on something with fairy fire effect
on it to generated 3 dice for attack (1 dice roll then an advantage dice roll) when it should have just been the advantage dice roll. Can't duplicate in local client.Quote:
# Faerie Fire (Blue); (C); GRANTADVATK; LIGHT: 0/10 0000FF; 'Deactivate invisibility