League of Extraordinary FoundryVTT Developers

LOE

League of Extraordinary FoundryVTT Developers

Join the community to ask questions about League of Extraordinary FoundryVTT Developers and get answers from other members.

Join
CCalego11/30/2021

API doc topics

Give me some ideas for what areas of the foundry core API would benefit from a wiki documentation page. I'm looking for what would be most useful to do next.
DTDaniel Thorp11/19/2021

Discord Permission Issue

Oh, I think you also need a Typescript role
BBadIdeasBureau11/3/2021

item to actors script

I have this macro for updating actors in a compendium with spells from a compendium of spells (i.e. replacing by name any spells on the actors, so I can push my improvements to spell automation onto the monsters in my compendium). It works, but I'm wondering if I can make it more efficient - currently, it's doing an individual update per actor, and that feels like it should be possible to batch into a single update (which would also allow me to construct the update list by getting an extended index with the items for the monsters, and not have to getDocument on each monster). There's definitely a bunch of smaller improvements that can be made as well - this is slightly sketchy code and I'm out of practice. ```js let pack = game.packs.get("DDBImports.spells") let index = pack.index...
Cccjmk10/26/2021

compendium errors upgrading to v9

hmm im not entirely sure how this will work though.. because I did just a quick smell test to my module under v9, and it broke on the compendium settings which is absolutely core to the module 😛 and I'm not sure if whatever I do to fix it will work on 0.8.x
CCalego10/23/2021

Blind Chat Messages

Anyone have good examples of creating a chat message that should only be visible to a connected GM, but might be created by any connected client?
Wwyrmisis10/14/2021

createEmbeddedDocuments issue

I'm going to throw my code in a thread so I don't clutter this channel up with a wall of text
Cccjmk10/9/2021

Compendium loading

hmm ghost, I added some console.time tags here and there to measure the difference between loading only SRD data vs bigger compendiums (I tried the compendiums I have with stuff imported from ddbi) and I noticed that times lower significantly after the first calls on each of the compendium groups, these are cached midway I guess ? I am not aware of how the foundry infrastructure works inside. I mean.. I tried multiple times like this: 1) using only SRD compendiums, Times X 2) using DDBImporter compendiums, Times Y > X...
CCalego10/5/2021

DocumentData shennanegins

TIL: It is possible to update an Actor or Item's data.data with arbitrary information that isn't defined in the system template. This data survives database compaction.
No description
CCalego10/1/2021

flag shenannegins

TIL you can set the flags key on a document to whatever you want to (e.g. a string). This is a sure fire way to completely ruin someone else's day, or your own day when another module un-does this by setting a flag 'correctly'. ```js game.actors.getName('A Character').update({ ['flags']: 'A value'...
CCalego9/29/2021

S3 File Picker Settings

Can someone with an S3 configuration give me a test of the FilePicker settings api and tell me if a file picked on S3 gives an indication that it is on the S3 bucket? You can open console and do this in game: ```js game.settings.register("core", "chooseFoo", {...
WWasp9/1/2021

Tagger Code Review

Would anyone be keen to code review Tagger? I'd like to git better 😄 https://github.com/Haxxer/FoundryVTT-Tagger...
CCalego8/25/2021

mergeObject

mergeObject is a beast of a function which lets you smash two objects together and that options argument lets you control how exactly you want to merge things. Argument 1: Source Object --> What we are merging into (this is going to be mutated by default) Argument 2: Mod Object --> What we are applying to the Source ...
EEthck8/20/2021

custom hud element

Maybe I'm missing something simple here. I'm making my own custom hud element (NOT based on a Foundry Class) and am wondering what's the easiest way to make it draggable/movable. Any suggestions? I saw the draggable class which at least changes the cursor, but no dragging can actually happen yet (assuming I need a handler somewhere but don't want to reinvent the wheel.)
DTDaniel Thorp8/17/2021

Dynamically get Object property from user input

Anyone know how I can do this? I have an Actor (myactor) and I'd like to have an input box which the user can use to refer to any of its properties, by typing in a path (i.e. @data.abilities.str.proficiency). How can I get that property within my script after they type in the box?...
DTDaniel Thorp8/12/2021

Scroll Into View troubles

Anyone know why Element.scrollIntoViewIfNeeded() is working, but Element.scrollIntoView() isn't? The IfNeeded version is apparently "Non-Standard" https://developer.mozilla.org/en-US/docs/Web/API/Element/scrollIntoViewIfNeeded Not sure what I should do here... Could someone test which works best on your Foundry instance?...
No description
EEthck8/12/2021

Overlay hiding stars

Hey y'all! I've run into a general CSS/design problem that I'm kinda stumped on solving. In the image the red circles are highlighting the star(s) in the constellation that are overlaid by my absolute positioned elements and therefore are uninteractable without stretching to some insane dimensions. Any suggestions? I've thought about maybe adding a margin to the image but that just makes the scrolling even worse :(...
No description
DTDaniel Thorp8/11/2021

Document Timestamps

Is there a way to find the timestamp of the last edit made to a Document?
MMagus8/4/2021

Temporary Documents

Is there a built-in way to create temporary entities? Like entities wich are not stored in the database, but remains in memory for .update etc