STALKER-X (Camera library)

Showcase your libraries, tools and other projects that help your fellow love users.
User avatar
adnzzzzZ
Party member
Posts: 305
Joined: Sun Dec 26, 2010 11:04 pm
Location: Porto Alegre, Brazil

STALKER-X (Camera library)

Post by adnzzzzZ »

Hi. I've created a camera library for LÖVE. It provides basic functionalities that a camera should have and is inspired by hump.camera and FlxCamera. The goal is to provide enough functions that building something like in this video becomes as easy as possible:



STALKER-X on github
User avatar
yetneverdone
Party member
Posts: 446
Joined: Sat Sep 24, 2016 11:20 am
Contact:

Re: STALKER-X (Camera library)

Post by yetneverdone »

Awesome! Very good documentation also! With lots of features hooray! Thanks dude
User avatar
Tjakka5
Party member
Posts: 243
Joined: Thu Dec 26, 2013 12:17 pm

Re: STALKER-X (Camera library)

Post by Tjakka5 »

Absolutely fantastic! It seems to address all the issues I had with Hump Camera, while still being very easy to use.
I'll be sure to upgrade to this system once I can get around doing so.
Fuzzlix
Citizen
Posts: 60
Joined: Thu Oct 13, 2016 5:36 pm

Re: STALKER-X (Camera library)

Post by Fuzzlix »

Nice work. Thank you for sharing.

looking into it and using luacheck in ZBS i found this:

Code: Select all

function Camera:attach(x, y, w, h)
    local x, y = 0, 0
    ...
I am not shure what you wanted to do. Probably remove parameters x and y ?
User avatar
adnzzzzZ
Party member
Posts: 305
Joined: Sun Dec 26, 2010 11:04 pm
Location: Porto Alegre, Brazil

Re: STALKER-X (Camera library)

Post by adnzzzzZ »

Yea, I meant to do something else. I fixed it.
User avatar
master both
Party member
Posts: 262
Joined: Tue Nov 08, 2011 12:39 am
Location: Chile

Re: STALKER-X (Camera library)

Post by master both »

Amazing camera! I will certainly use it for future proyects. But I have a question, is there a way to make the shaking not move the camera position when it finishes, like it does in the example gif?
User avatar
adnzzzzZ
Party member
Posts: 305
Joined: Sun Dec 26, 2010 11:04 pm
Location: Porto Alegre, Brazil

Re: STALKER-X (Camera library)

Post by adnzzzzZ »

I should add an option for that. But for now you can just make the camera follow a target. If the camera is following a position then after the shake is done it will still be following that position.
User avatar
master both
Party member
Posts: 262
Joined: Tue Nov 08, 2011 12:39 am
Location: Chile

Re: STALKER-X (Camera library)

Post by master both »

adnzzzzZ wrote: Sat Nov 18, 2017 5:06 pm I should add an option for that. But for now you can just make the camera follow a target. If the camera is following a position then after the shake is done it will still be following that position.
Oh right, I'm asking for some cases like cutscenes, where the player doens't have control over the player, but I guess I can make the camera folow a target during those.
User avatar
adnzzzzZ
Party member
Posts: 305
Joined: Sun Dec 26, 2010 11:04 pm
Location: Porto Alegre, Brazil

Re: STALKER-X (Camera library)

Post by adnzzzzZ »

Just make it follow the center of the screen (in world coordinates).
User avatar
yetneverdone
Party member
Posts: 446
Joined: Sat Sep 24, 2016 11:20 am
Contact:

Re: STALKER-X (Camera library)

Post by yetneverdone »

Is there a debug mode where we can see the rectangular target as shown in the gif?
Post Reply

Who is online

Users browsing this forum: No registered users and 35 guests