Limit how far "down" the camera can go?

Get help using Construct 2

Post » Tue Jan 03, 2012 6:02 pm

So what I need is for the ScrollTo plugin to act the same, but I want the camera to only go down so far. Let me explain.
Example (How it should be)


(How it ends up with the System's Scrolling feature)


I want the it to still scroll and follow the player, including when he jumps, or even if he was to fall down below to a lower platform. I just want the camera to be limited to how much "freespace" is shown below the player. Can this be done?DoubleElite2012-01-05 04:49:36
B
16
S
3
G
5
Posts: 43
Reputation: 3,875

Post » Tue Jan 03, 2012 7:55 pm

Get rid of the ScrollTo plugin, it's a shortcut for the system 'scroll to object' action. Just use that instead, e.g. if object Y < 1000 then scroll to the object. Then it will never scroll below 1000 pixels.
Scirra Founder
B
357
S
214
G
72
Posts: 22,946
Reputation: 178,228

Post » Tue Jan 03, 2012 8:26 pm

Ok, so I set it up like this;

System | Player.Y < 200 ----- ScrollTo Player

The problem is that now the system wont scroll when he moves. I'm trying to replicate a 'camera' from this http://www.scirra.com/forum/imfuckincold-wip_topic47701.html
B
16
S
3
G
5
Posts: 43
Reputation: 3,875

Post » Tue Jan 03, 2012 8:45 pm

Did you add the condition to a System Every Tick condition? It works for me like that, i.e.

System Every Tick        System Scroll To Player
Player.X <1000zenox982012-01-03 20:46:21
If your vision so exceeds your ability, then look to something closer.
Moderator
B
120
S
28
G
68
Posts: 4,839
Reputation: 48,279

Post » Tue Jan 03, 2012 11:56 pm

I did as you said, but when he get's near the side, the camera jumps down.
http://dl.dropbox.com/u/8177003/CameraMove.capx Here's a quick setup of my example. Any ideas?DoubleElite2012-01-04 00:51:59
B
16
S
3
G
5
Posts: 43
Reputation: 3,875

Post » Wed Jan 04, 2012 12:20 am

put the file on the public folder and right click on it "dropbox > copy public link"
B
60
S
22
G
14
Posts: 1,479
Reputation: 16,346

Post » Wed Jan 04, 2012 12:52 am

Thanks Yann, updated my post with the new link.
B
16
S
3
G
5
Posts: 43
Reputation: 3,875

Post » Thu Jan 05, 2012 4:47 am

Bump. Update my post with example images, and more info.
B
16
S
3
G
5
Posts: 43
Reputation: 3,875

Post » Thu Jan 05, 2012 5:39 am

New to Construct ? Where to start

Image Image
Image Image

Please attach a capx to any help request or bug report !
Moderator
B
247
S
85
G
40
Posts: 6,998
Reputation: 57,786

Post » Thu Jan 05, 2012 5:12 pm

Thank you very much Kyatric! This is exactly what I needed, works great!
B
16
S
3
G
5
Posts: 43
Reputation: 3,875

Next

Return to How do I....?

Who is online

Users browsing this forum: Governador, tarek2, Thelegendvinny and 23 guests