how to handle items and effects?

I've been working on a system for a game that needs a concept that seems like it might be a good fit for active effects. Though i'm not sure if effects are the right way to go. Some of these effects can temporarily raise or lower a stat, seems like a fit for effects. While some of these effects may deal damage, give your current attack an AoE, or grant you an ability to use this turn. Some of these things i'm not sure do fit into effects. Some of these effects may target the player, and others may target the player's target. The last thing that I'm struggling with is how to model these things. I don't want to have to create an active effect on every item that has one, as they are sometimes reused across several items. I was planning on using Items so I could have a sheet to manage them and pre-built effects ready to go in the compendium. Then I can easily drag on drop the effects onto the items/actor they should belong to. Though I got stuck trying to apply my new effect (item) to a a weapon (item), due to default drag and drop behaviour not existing for item->item. My questions are if these things sound like a good fit for active effects? Should I try and model effects as items to be able to reuse them easily? How do I handle drag and drop to add an item to an item?
F
Farling170d ago
I don't think an item can have another item as a child. For just dragging effects between items, you could look at my "cypher system active effects" module which adds drag and drop. Although I actually got the drag and drop from another game system.
E
Eclipxs170d ago
I'll check it out, thanks. How do you handle effects that need to make an actual change to an actor? for example, my Bleed effect should cause them to take damage at the start of a round. From what I understand, effects only make temporary changes, usually to buff or debuff a stat temporarily.
Would it be a similar thing to transferring an effect to your target? Add a chat message when the effect should cause damage and have the player apply the damage to the actor?
F
Farling170d ago
Effects normally do a single change to an Actor. I've never looked into how to do periodic damage in FOUndry.
E
Eclipxs168d ago
since I want to be able to create items out of these things to manage them easier, and not all of them may be good fits for effects. I created a drag drop handler for items->items that will copy some data over. (the id of the item and its name and description) that way I can display info about it in the owning item, and look up the original item if I need to create something from it later on. Thanks for getting me started with the drag and drop @Farling
A
aaron101d ago
You can use Hooks.on("updateWorldTime", ... to loop thru all the actors with your damaging effect, applying damage as appropraite. You can also use Combat::nextTurn, looking for your damaging effect. You can add a duration to the effect to implement a Bleed for X seconds/rounds.
Want results from more Discord servers?
Add your server
More Posts
Advice on the general programming model a system should followI'm brand new to foundry dev and I want to make sure I am gaining the correct understanding of the eAdvice for compendium data in a custom systemHello, i'm new here! I was wondering if I could get a little direction for storing data about my gaDialog Box Auto-Closing Upon Opening 2nd TimeI've been appending custom functionality to the simple worldbuilding system. At this time, I'm tryinActor collisionImplementing the homebrew knockback feature. It's almost working but how do I test if two actor tokeActor attributes update on player's sideI can't fathom how to make changes to actor attributes on player's side. According to documentation Sort itemsHello, I am searching for where is stored the data about "items" order, as I would like to order thNewby accepting advice on the Foundry API and Module DevelopmentHeya,im very new to Module development for foundry and im suuuuper rusty in the codding department bHow do I create/modify embedded document types?Let's say I want Items to also have Items embeddedHow do I specify an Array in my template.json?I want schema checking for elements inside of an undefined-length array in my template.json, how do Is is possible to create/change Foundry's document types?For instance, removing "Actor" and "Item" and adding new ones.ERROR: actors is not a valid embedded Document within the Token DocumentHi guys! New here, just purchased the software. Could we get any help on this elusive error? It's wHow to trigger "hotbarDrop" with element that are not "Item" ?Hello, I would like to know if it is possible to trigger "hotbarDrop" with element that are not "ItIs there a starter system based on the v10 DataModel?I'm creating a new system (sci-fi with a cyberpunk theme, battles in space, land vehicles, and closeNewb looking for advice on creating Compendium via codeI am new to Foundry and trying to figure out if it will be a good fit for my game. I have a fair amo