#Accessing an IEnableableComponent's state and data during a Job

1 messages · Page 1 of 1 (latest)

vague grove
#

Hello again! Thank you all for your help so far. I've got another difficulty I've run into.

Right now, I've got an IEnableableComponent that's got some data inside of it. I've got a job that would like to both read the state of the component (enabled or disabled) and also read-write the data inside the struct. However, I'm not sure how to do that.

If I pass it as an EnableableRefRO (or RW), I can see the overall status (enabled or disabled), but I can't access the data stored inside. Conversely, if I pass it as a ref, I can see and work with the data inside but I don't seem to be able to access the overall enabled/disabled state (unless there is syntax for doing so that I am unaware of). Finally, if I try to pass it as both, I get an error saying that I'm trying to pass two of the same thing.

I've seen some an forum threads online on this and they've discussed various workarounds but also talked about potential support for this functionality being included in updated versions, and I was wondering if there's any commonly-accepted best practice for doing this or other direct functionality that those forum posters may not have been aware of, especially since I'm not sure what would be best for accomplishing my goal.

Thank you all once more for your help. You've helped me get unstuck when I'm feeling stumped even after quite a bit of time poring over forum threads and documentation.

calm vale
#

Either both RO or both RW