Zinnia.Unity icon indicating copy to clipboard operation
Zinnia.Unity copied to clipboard

Action Source/Target for passing actions across a bridge

Open thestonefox opened this issue 3 years ago • 0 comments

from Discord:

I think interactors having a list of ActionSources is better than an ActionSource knowing about its interactor

this actiontarget/source concept is more about

i know both these sources can control this target but only under certain circumstances
i could have only 1 source control it
both or neither
so in the use case of interactables
its grabbing
and right now we have 4 (5 with custom whatever that means) states
first touched/touched/first grabbed/grabbed
so..
* the first controller that touches me gets the action link
* any controller that touches me gets an action link
* the first controller that grabs me gets the action link
* any controller that grabs me gets an action link
so a gun would be like first grab
the primary grabbing controller is my firing controller
this actiontarget/source concept is more about

i know both these sources can control this target but only under certain circumstances
i could have only 1 source control it
both or neither
so in the use case of interactables
its grabbing
and right now we have 4 (5 with custom whatever that means) states
first touched/touched/first grabbed/grabbed
so..
* the first controller that touches me gets the action link
* any controller that touches me gets an action link
* the first controller that grabs me gets the action link
* any controller that grabs me gets an action link
so a gun would be like first grab
the primary grabbing controller is my firing controller
this actiontarget/source concept is more about

i know both these sources can control this target but only under certain circumstances
i could have only 1 source control it
both or neither
so in the use case of interactables
its grabbing
and right now we have 4 (5 with custom whatever that means) states
first touched/touched/first grabbed/grabbed
so..
* the first controller that touches me gets the action link
* any controller that touches me gets an action link
* the first controller that grabs me gets the action link
* any controller that grabs me gets an action link
so a gun would be like first grab
the primary grabbing controller is my firing controller
this actiontarget/source concept is more about

i know both these sources can control this target but only under certain circumstances
i could have only 1 source control it
both or neither
so in the use case of interactables
its grabbing
and right now we have 4 (5 with custom whatever that means) states
first touched/touched/first grabbed/grabbed
so..
* the first controller that touches me gets the action link
* any controller that touches me gets an action link
* the first controller that grabs me gets the action link
* any controller that grabs me gets an action link
so a gun would be like first grab
the primary grabbing controller is my firing controller
i think i have a way of making it totally generic and even can be part of zinnia
i need to let it swill around in my head a bit first
this way you can keep using the ActionPublisher/ActionReceiver for a super simple way

but if you want to use ActionSource and ActionTarget components separately then you can
well i dunno how easy it is it to make it part of zinnia yet....
it'll all become clearer when i start on it

thestonefox avatar May 23 '22 15:05 thestonefox