2D Toolkit Forum

2D Toolkit => Support => Topic started by: kenglou.lee on August 05, 2013, 11:20:02 am

Title: Possible to have 2 Ui camera attached to UI Manager?
Post by: kenglou.lee on August 05, 2013, 11:20:02 am
Hi,

Is there any solution for me to implement 2 UI Camera On the screen and both are attached to UI Manager?

Currently I am thinking to do a level map that has some UI Button on the screen(UI Camera) and Level Button inside the map(Map Camera). I want to zoom and move on the Map and click on the Level Button meanwhile the UI Button UI Camera will stay its own size. But UIManager only can set 1 Camera for receiving input. Any Suggestion?

Thanks .
Title: Re: Possible to have 2 Ui camera attached to UI Manager?
Post by: unikronsoftware on August 05, 2013, 12:28:28 pm
No, you can only have one UI camera right now. The reason is to avoid keeping a multiple references to objects, but there could be potential solutions to this in a later version.
Title: Re: Possible to have 2 Ui camera attached to UI Manager?
Post by: kenglou.lee on August 06, 2013, 12:23:06 am
that means if I want to do things like what i said in post 1 is certainly impossible?
Title: Re: Possible to have 2 Ui camera attached to UI Manager?
Post by: unikronsoftware on August 06, 2013, 10:06:00 am
No its not impossible, it means you'll have to write some code to do it. If you make it so you can have multiple UIManagers (disable the code that stops you from doing so), you can fairly easily make them work with multiple cameras & layers.