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'.
game.actors.getName('A Character').update({
['flags']: 'A value'
})

game.actors.getName('A Character').data.flags // 'A value'

game.actors.getName('A Character').setFlag('world', 'someKey', 'some string value')

game.actors.getName('A Character').data.flags // { world: { someKey: 'some string value' }}
game.actors.getName('A Character').update({
['flags']: 'A value'
})

game.actors.getName('A Character').data.flags // 'A value'

game.actors.getName('A Character').setFlag('world', 'someKey', 'some string value')

game.actors.getName('A Character').data.flags // { world: { someKey: 'some string value' }}
C
Calegoā€¢958d ago
dnd5e for instance gets big mad when its flags disappear from an actor.
UU
Unknown Userā€¢958d ago
C
Calegoā€¢958d ago
It seems that core doesn't care
C
Calegoā€¢958d ago
No description
C
Calegoā€¢958d ago
this falls squarely under "play stupid games win stupid prizes" lol
C
Calegoā€¢958d ago
No description
C
Calegoā€¢958d ago
speaking of... I want to try this with items or like data itself, but am too scared
C
Calegoā€¢958d ago
omg lol
No description
C
Calegoā€¢958d ago
Alright well. TIL update has great power and thus comes with great responsibility.
UU
Unknown Userā€¢958d ago
C
Calegoā€¢958d ago
[removed gif] oo no that looks like it actually hurt no more of that gif thanks
C
Calegoā€¢958d ago
much better
UU
Unknown Userā€¢958d ago
C
Calegoā€¢958d ago
lol
UU
Unknown Userā€¢958d ago
DT
Daniel Thorpā€¢941d ago
Is this a "bug"?
C
Calegoā€¢941d ago
I would not categorize it as such. If I got sent a bug with this at work, my reply to it would be "... don't" and I'd WONTFIX it.
DT
Daniel Thorpā€¢941d ago
Makes sense, thanks
C
Calegoā€¢941d ago
if I couldn't get away with telling them to "just don't" I'd say something like:
The amount of complexity and performance overhead that would be introduced by adding validations to this low-level API do not outweight being able to prevent the edge case described by this issue.
šŸ˜›
UU
Unknown Userā€¢941d ago
Want results from more Discord servers?
Add your server
More Posts
raaeAfter some discussion yesterday in #active-effects , I decided to try to create a system-agnostic modevMode json changed warningI checked the module repo and I honestly can't figure out where I would plug in my code. I'd be guesS3 File Picker SettingsCan someone with an S3 configuration give me a test of the FilePicker settings api and tell me if a item preCreate@sol.folango @mrprimate (pinging you two in particular because you do import stuff involving existinItem Macro Compendium WorkflowOkay, here's a long one that's a bit of a doozy. I'm looking at setting up some sort of tooling/workItem Specific Crit DetailsOh that critical hit thing is gonna hit MRE too isn't it... hrm...1.5.x 72%@dnd5e No action required (but suggested šŸ™‚ ) The 1.5.0 milestone is ~72% complete. It has a due daV9 Tabs IssueIf you never figured this out, here's why this happened: A small change in `Tabs` during v9 causes sDeck Creation MacroI created a macro to fill out a 52-card deck, you set the ID of the deck and the base URL of the foldevmode-issues@arcanist figured out, the flex layout elements have `pointer-events: none`, so anything injected wifunction vs methodAnyone know of a good guide that explains the difference between a function and a method? I don't reActive Effect HelpAnd it should be the actual ActiveEffect document for the effect, not just the id. I don't have theTOL JEs@badgerwerks I haven't had a chance to poke around in TOB/BoL yet, but I wanted to ask how you did tCI 2 minute windowAlright, I've got a Gitlab CI pipeline I'm reasonably pleased with as a result of yesterday's effortGitLab CI PipelinesToday's project is Gitlab CI. Wow me with your pipelines if you got em.Storybook Shennanegins@wyrmisis I have a headcannon for you, one who also uses Storybook. _What if_ we could load foundryjsxDammit I want this...react librarySo far I've seen Vue 2, Vue 3, Alpine, and Svelte pulled into Foundry. No one has yet been crazy enoweb componentsA comment @n1xx1 made over in #development-basics (https://discord.com/channels/732325252788387980/7UI element JS Classeshttps://discord.com/channels/732325252788387980/734922093967310910/882979923483037696 @wyrmisis > I