LOVE2D-trouble with cameras (follow player until end of map)

Questions about the LÖVE API, installing LÖVE and other support related questions go here.
Forum rules
Before you make a thread asking for help, read this.
Post Reply
jambox5
Prole
Posts: 1
Joined: Tue Mar 15, 2016 5:33 pm

LOVE2D-trouble with cameras (follow player until end of map)

Post by jambox5 »

Hi Love community!

First time posting, still pretty new to LUA and LOVE, but I've been working on some small projects to better expand my understanding of a lot of core concepts (both of LOVE and of game design), one thing I really don't quite get is camera motion, ie having the screen follow the player character.

In my attached project (pretty simplistic and please ignore the bad code structure) I want the screen view to follow the player, but then stop once the edge of the map lines up with the edge of visible screen. I didnt find anything that jumped out as obviously dealing with this in the wiki, so I figured I'd hope over hear and ask.

Any help would be excellent :D
Attachments
TestSpace.love
(15.09 KiB) Downloaded 109 times
Post Reply

Who is online

Users browsing this forum: Bing [Bot], Google [Bot] and 3 guests