Sorry guys, on a bit of a fast track to learn OStageC!
I have an XY pad.
I want to have a button that will store the current value of it (the XY pad).
And then another button that can later (even an hour later) restore the pad to that stored value.
Is something like that possible?
(i already know about set(“knob_id”, 1), so i guess “get” works the same way, but then how later send that value out again?)
it seems that you can store in the local of your browser https://openstagecontrol.ammd.net/docs/widgets/scripting/#storage
hope it helps
storage as @zoltan pointed out would look like this:
// save in slot "knob_val"
// load from slot "knob_val"
Brilliant, J-E & Zoltan, that works perfect!
This is very cool!
Question tho - I tried this while session was running on laptop and iPad, pressed “store” button on iPad and I could recall the stored value from laptop. But after restarting laptop, I could restore value from laptop, but not from iPad anymore.
Any thoughts why that might be a case?
@Dazzer in example bellow is another way how to store values, only problem is that they get reset when session is closed. Might come in handy anyways.
store_values.json (13.4 KB)
I think the issue here is that the tap buttons are sync’ed across the different clients when the session is loaded and it triggers the script. That’s a behavior I’ll need to rationalize somehow… meanwhile I think the best course of action is to set bypass to true on these button to avoid sync.
Note that in any case, the variables saved in storage are not shared between clients, it may have seemed that way but was only a side effect of widget sync.
But is there a way how to save those values on server itself? So I can recall them from any client?