Hello everyone!
I'm not sure if it is possible, but I can't figure out how to do something like this.
I have a cooking system in my game and I want to give the party a state based on the meal they cook.
I only want to give the state for a set amount of game time.
Sounds simple enough, If anyone has any ideas that could help I'd be greatful.
I am using alot of visustella plugins too. So if there's anything in there that can do this too.
only need plugin to make the state 'ignore recover all removal' and possibly 'ignore death removal'
pretty sure that was visu's skill and state core plugin for that.
the rest would just be a parallel common event time system.
wait 60 frames
control variable -1
if variable = 0 remove state from all party members.
and item common event for the food.
add state all party members
set variable X
X would be the duration in real life minutes * 60
ie: 60sec * 20min = variable 1200
edit: actually probably dont even the plugin if death is supposed to remove food buff and the only time you use 'recover all' event command is for sleeping which would remove the buff also.
the event is only playing once from using the item forcing it to run while the trigger condition is never met because you forgot to turn on the bread switch.
guessing the timer switch is causing another common event to trigger?
in my head i was building this as just a 24/7 common evented time system that is a separate from the item use common event, turn on the 'time passes' switch right at the start of the game.
(only turn it off if want to freeze time for a cutscene or something and turn it on again right after)
just add to the time event whenever you need to more time based checks, like adding 1 more 'remove state' line for each different food buff (exactly where you have the remove bread buff, not a sperate condition for each buff) instead of having a whole other CE for each buff.
and the item would have the add state as part of the item effects (as well as remove all other food buffs so cant stack food effects).
the item CE i was picturing was only set variable for X minutes (i wasnt picturing a visible timer outside of seeing the state icon)
(if wanted food to be stackable you would need a separate variable for each buff and a separate condition on the time CE.)
dont know where the notetag set variable is from but if that part works then wouldnt even need the item to have a CE at all for how i was picturing it, just the time system event.
but would probably still need the item common event for your visible timer. unless you can notetag turning on the timer switch too.
edit: theres youtube videos for building full (second/minute/hour/day of the week) common event time systems instead on only a X seconds tracker. (the basis for having it as a 24/7 common event)
the "in my head" system described here can very easily be added into the 'seconds' part of a full time system event since its just "seconds remaining variable -1, if variable 0 remove buff states"
but building a full time system event would be going overboard if only plan to track X seconds condition checks.