Can't get input in collection proxy

I have loaded a collection proxy but I receive no input on the scripts inside the proxy even if I have input focus on the loader object. I also receive no input on the loader object.

This is the script that loads the proxy:

function init(self)
    msg.post(".", "acquire_input_focus")
    msg.post("/game#level1", "load")
end

function on_message(self, message_id, message, sender)
    if message_id == hash("proxy_loaded") then
    	msg.post(sender, "enable")
    end
end

And this is a script on an object in the proxy:

function init(self)
    msg.post(".", "acquire_input_focus")
end
1 Like

Input is routed through the proxy so the game object that holds the proxy component need to acquire input focus for it to work.

3 Likes

Found the issue, I activated input on a gameobject that did not have the proxy component.

1 Like

Cool. That’s a very common thing to miss. I’m adding an entry about this to the FAQ.

1 Like