how to make a Textbox stay in place on a side scroller game

Get help using Construct 2

Post » Thu May 07, 2015 3:10 pm

When my Player leaves the screen it switchs to the next screen but my Button and Text box stay on the first screen so how do I make them appear on the next screen?
B
9
S
1
Posts: 51
Reputation: 602

Post » Thu May 07, 2015 3:22 pm

What do you mean by the next screen?
I told my dentist I had trouble with my teeth and asked her to fix it without looking in my mouth..
B
54
S
16
G
8
Posts: 6,160
Reputation: 19,775

Post » Thu May 07, 2015 4:08 pm

If you are switching from one layout to another instead of "side scrolling"on the same layout and you want to have the text box appear in the same spot you can place the UI (text box layer hp all the stuff you normally want to keep) on a separate layer and make it global and just in case paralax 0,0 (in the layer settings).

Also if you have some other kind of setup you may need to just set that text box to "global" on its properties.

I find it better just to make the layer which I'll use as a UI a global to keep it tidy but to each their own. I made a very simple example of the text passing from one layout to the other. (no paralax just the text) Here it is. Just click anywhere it will switch layout and update the text. I hope it helps.
Freefall Bird
B
47
S
9
G
5
Posts: 280
Reputation: 5,796

Post » Fri May 08, 2015 7:04 am

I have a 3840 by 1280 screen divided into two 1920 by 1280 screens which will alternate by a push of a button or by walking off the edge. In hindsight it was easy, I duplicate the score number and push button on both screens and I will keep it on a separate layer to make it more organised. Thanks.
B
9
S
1
Posts: 51
Reputation: 602

Post » Fri May 08, 2015 4:25 pm

@Marc456
Ok so in that case you do not actually need to duplicate it you just need to set the layer(best to have a separate layer for your ui) paralax property to 0,0 that way you just need one field and it will keep the information(since its the same field) and follow the player around.
Freefall Bird
B
47
S
9
G
5
Posts: 280
Reputation: 5,796


Return to How do I....?

Who is online

Users browsing this forum: No registered users and 10 guests