How can I reference a component of a spawned game object (i.e., a dynamically created game object instance)? This doesn’t work, since “message.other_id” is a hash and not a string…
msg.post(message.other_id .. "#collisionobject", "disable")
Bryan
How can I reference a component of a spawned game object (i.e., a dynamically created game object instance)? This doesn’t work, since “message.other_id” is a hash and not a string…
msg.post(message.other_id .. "#collisionobject", "disable")
Bryan
message.other_id
is a hash, not a string, so ..
won’t work on it. Instead, you can use it to construct a URL to a component like so:
msg.post(msg.url(nil, messsage.other_id, "collisionobject"), "disable")
Thanks, this is perfect!
Sounds like I need to continue poring through the documentation.
Thanks again,
Bryan
This is mentioned in the manual on factory components:
But we should probably also add this to the message passing manual.