looking for love launcher

General discussion about LÖVE, Lua, game development, puns, and unicorns.
Post Reply
Muris
Party member
Posts: 131
Joined: Fri May 23, 2014 9:18 am

looking for love launcher

Post by Muris »

Hello!

I remember seeing someone posting a project about something that launches other love files with some kind of user interface back in couple of months ago, but I cannot seem to find it at all or maybe I just remember wrong.

I figured it could be really nice tool for android testing, since I have to constantly keep replacing the lovegame/ -folder, but instead it would be awesome if i could just make subprojects and use the launcher to launch any of the projects I have.

Thank you in advance!
User avatar
SpotlightKid
Prole
Posts: 6
Joined: Mon Nov 10, 2014 7:57 am
Location: Cologne, Germany

Re: looking for love launcher

Post by SpotlightKid »

Do you mean the examples collection on the wiki?

http://www.love2d.org/wiki/examples.love

The main.lua kinda does what you're describing.

I adapted the examples for LÖVE 0.9.1 and cleaned up the code quite a bit. Here's my repository::

http://trac.chrisarndt.de/code/browser/ ... 1-examples

Check it out with:

Code: Select all

svn co svn://svn.chrisarndt.de/projects/love2d/love-0.9.1-examples
Muris
Party member
Posts: 131
Joined: Fri May 23, 2014 9:18 am

Re: looking for love launcher

Post by Muris »

hey thanks, this is something that I was looking for, but sadly I was not able to get it work with with sub-projects.

I managed to change the file-finder by just checking if fn/main.lua exists, then add that from the file-finder, but the problem comes when executing the main.lua from subfolder. Since I am using require("img/something.jpg") or whatever require for lua-files, it uses the parent directory from the apploader. Now since the program for example is located at "test/main.lua", it doesn't do the search from "test"-folder.

So now the solutions that I can come up with is, a) somehow change parent directory, im not sure how to do this or b) set a global variable and insert that variable into every single lua-file require / loading image / loading sounds, which is not bad, since I don't have that many files, but still a bit of a nuisance.

PS: A minor thing, not so much of a real problem but the menu doesn't really scale well on nexus 5, android device, since it uses 1920 x 1080 resolution, but that is something ill have to fix by myself. Also I have to give thanks to people who did the porting to android, everything I've tried has worked with 0 changes to lua code compared to running on pc.

Edit: Actually I got the require working by adding "folder/?.lua;" into package.path, but sadly this still gives problems with loading audio and images. I guess I should just start using asset managers to get past this problem, or maybe there is a way to set parent directroy to audio and image-folders.
User avatar
micha
Inner party member
Posts: 1083
Joined: Wed Sep 26, 2012 5:13 pm

Re: looking for love launcher

Post by micha »

I think you are looking for Vapor.
User avatar
Positive07
Party member
Posts: 1014
Joined: Sun Aug 12, 2012 4:34 pm
Location: Argentina

Re: looking for love launcher

Post by Positive07 »

I think he referes to my project, Cube. It's still in development, but it will soon come. Live development is a good use, I didnt think about it haha thanks! There is a github for it but I havent posted the most important part of the code, I'll go back to it and update it soon
for i, person in ipairs(everybody) do
[tab]if not person.obey then person:setObey(true) end
end
love.system.openURL(github.com/pablomayobre)
Post Reply

Who is online

Users browsing this forum: Ahrefs [Bot] and 3 guests