Infinite, Smooth Wrapped Scrolling Issue

Discussion and feedback on Construct 2

Post » Sun Mar 03, 2013 1:05 pm

Infinite, Smooth Wrapped Scrolling Issue
First I should say I am new to C2 and this maybe solve of have a simple solution. But I can not find.

I have the same frustration and a number of other posts nave the same requests. I think maybe it can't be done easily. As no simple posted an answer. But there are a few work arounds posted.

Please can some one post a reply to the threads at as can not for some reason un authorised.

Maybe I have missed something as it should be included in any game engine as a basic feature..

However looking at this link http://www.scirra.com/forum/scroll-repeat_topic45428.html
B
4
Posts: 7
Reputation: 689

Post » Sun Mar 03, 2013 1:09 pm

Opps I am a noob it cut of my post half way. Here the rest.. lol

However looking at this link http://www.scirra.com/forum/scroll-repeat_topic45428.html
B
4
Posts: 7
Reputation: 689

Post » Sun Mar 03, 2013 1:16 pm

Try again it not me it does not like my links :(

Infinite, Smooth Wrapped Scrolling Issue
First I should say I am new to C2 and this maybe solve of have a simple solution. But I can not find.

I have the same frustration and a number of other posts nave the same requests. I think maybe it can't be done easily. As no simple posted an answer. But there are a few work arounds posted.

Please can some one post a reply to the threads at as can not for some reason un authorised.

Maybe I have missed something as it should be included in any game engine as a basic feature..

However looking at this link

http://www.scirra.com/forum/scroll-repeat_topic45428.html

jhonM said he solved it as jhonM said he solved it. But there is not explanation. Maybe I have missed something being new and still working through the manual.

Here is I believe the same issue and a solution of that from my programming background and but lack of Contract 2 knowledge sounds do able.

Method 1

http://www.scirra.com/forum/continuous-scrolling-background-from-parts_topic48041.html

Method 2

Ths for RTS But should be applicable to the problems[URL=http://www.scirra.com/forum/theory-virtually-unlimited-game-area_topic38715.html

Got Luck

Jackson

Links to the same issue threads

http://www.scirra.com/forum/keep-an-object-centered-and-looping-layout_topic62150.html
Keep an object centered and looping layout?

http://www.scirra.com/forum/scroll-repeat_topic45428.html
scroll repeat

http://www.scirra.com/forum/layout-like-a-globe_topic62271.html
Layout like a globe

http://www.scirra.com/forum/drawing-to-a-minimap-clearing-offscreen-objects_topic57881.html
Drawing to a minimap + clearing offscreen objects

http://www.scirra.com/forum/the-evergrowing-tile-editor_topic59032_page2.html
The Ever-Growing Tile Editor

http://www.scirra.com/forum/continuous-scrolling-background-from-parts_topic48041.html
Continuous scrolling background from parts?

http://www.scirra.com/forum/theory-virtually-unlimited-game-area_topic38715.html
Theory: (Virtually) Unlimited Game Area
B
4
Posts: 7
Reputation: 689

Post » Sun Mar 03, 2013 11:39 pm

yeah..been lookin fer the same thing..i searched "defender scrolling with the same kind of results...would love a tutorial.

:)
B
10
S
2
G
1
Posts: 38
Reputation: 1,721

Post » Mon Mar 04, 2013 9:04 pm

Is this what you're looking for?

http://www.scirra.com/forum/set-image-offset_topic54382.html
B
106
S
35
G
37
Posts: 798
Reputation: 25,215

Post » Thu Apr 11, 2013 5:09 pm

No Sorry. Maybe I will Try and Explain again
As example
The screen window in the browser is 800 by 600. The lay out is 3200 by 2400. This mean the lay out is 4 times longer and taller than the screen.

So to sole this the back ground scroll left and right and up down depending on the direction the character moves in.

The plkayer remains in the screen which means in effect the camera is attached to the player.

As the player moves close any edge of the layout the back ground continues to scroll. Instead of screen showing the edge of the layout or have the charge move from the center of the screen. The screen shows the right opposite side of the layout.

This is a feature in many retro style games. Defender (Arcade), Lunar JetMan (Spectrum) are examples of the horizontal scrolling wrap. There are 4 directional scrollong wrap.

As an example of the character move to a corner of the layout and was moving diagonally off the corner. At the point where the center of the center of the player was at the edge of the very layout.

The player would still appear in the center of the screen and all for corners of the layout would appear in the center of the screen taking up a quarter of the screen each one in the on the screen each.

If the back ground and object were on the lay out were placed correctly it would appear as if there was not edge and the layout was infinite in all for directions.

Please can some one help as this should be elementary feature.

Thank you.
B
4
Posts: 7
Reputation: 689

Post » Thu Apr 11, 2013 5:22 pm

Just a thought

on EveryTick
Player.x < 0
-Player.x = Layoutwidth - 1

Player.x > Layoutwidth
-player.x = 1

repeat for Y


Also set Layout property Unbound scrolling to yes
layout your background images outside of the layout so that they render(ok I have never technically done this)


Player Sprite
give behaviour ScrollTo . that way the game always keeps the player centered.

based on what I read. I thin this is what your looking for.jayderyu2013-04-11 17:22:50
B
87
S
18
G
9
Posts: 2,455
Reputation: 14,834

Post » Thu Apr 11, 2013 6:07 pm

Here is the official response emailed to me:

Sent: Friday, 12 April 2013 2:57 AM

Construct 2 doesn't support this in a built-in way, but you might be able to "fake" it.

Best regards,

Ashley Gullen
Scirra.com


B
4
Posts: 7
Reputation: 689

Post » Thu Apr 11, 2013 6:10 pm

I have been able to fake it by manually controlling every object every tick. But Construct grinds to a hult due to all the code in the high level contract programming system.

Maybe I can make it faster as I improve my coding skill. But it a massive amount of code.

B
4
Posts: 7
Reputation: 689


Return to Construct 2 General

Who is online

Users browsing this forum: Lordshiva1948, MonDieu and 16 guests