Page 2 of 3

Re: LOVE 0.5 Mac with working .love access

Posted: Mon Jan 05, 2009 2:07 pm
by smrx
Hm...even when i save it as .lua from the beginning, it doesn't work.

But - then i get no error when starting the new .love Archive, instead the Script itself doesn't even start, i just see in the Dock that Love is running...

Re: LOVE 0.5 Mac with working .love access

Posted: Wed Jan 07, 2009 3:41 am
by iLove
smrx: (and anybody else wanting to know) to be able to use Mac OS X's TextEdit to write code or script (of any kind), it needs to be in Plain Text mode. To switch modes you go to the Format menu and select "Make Plain Text" or "Make Rich Text". (The menu option changes depending on which of the two modes of operation you're currently in.)

Re: LOVE 0.5 Mac with working .love access

Posted: Tue Jan 27, 2009 8:07 pm
by codonnell
I love Löve on OS X. There are a couple of idiosyncrasies, but I'd be happy to help in whatever capacity I can. So far I'm just tickled. For those other OS X users out there. To launch your project, I'm using the terminal this way:

Code: Select all

$ open -a love ~/Proj/Löve/MyTest/
To create a .love file do this:

Code: Select all

$ ditto -c -k -X MyTest MyTest.love
I'm looking into what it takes to create a stand-alone binary distribution, but that is lower on my list of things to do that... playing with Löve! Super work!

Oh, and I recommend TextWrangler or TextMate for editing your files. Both are full of awesomeness.

Re: LOVE 0.5 Mac with working .love access

Posted: Fri Jan 30, 2009 10:06 am
by interlol
codonnell wrote:To create a .love file do this:

Code: Select all

$ ditto -c -k -X MyTest MyTest.love
I had a problem launching my applications and found a "problem" with the way ZIP files were created on the Mac, I hope this quick explanation can be useful:

I just discovered Löve today (from Reddit) and you have to tweak the ZIP file with Löve 0.5 if you want the .love file to work.
For example, if I decompress a file and recompress it (with a right-click on the folder), it will be broken because the structure inside the ZIP file will have changed. If you want the .love file to work, I discovered that the main.lua file must not be inside a subdirectory (which is sadly the default behaviour if you right-click on the folder and ask to "Compress the folder.")

Here is an example, before (it's working :) ):

Code: Select all

$ unzip -l myhamsterball.love 
Archive:  myhamsterball.love
  Length     Date   Time    Name
 --------    ----   ----    ----
    10854  01-24-08 03:09   hamster.png
      648  03-23-08 18:34   main.lua
       92  03-23-08 18:34   game.conf
 --------                   -------
    11594                   3 files
And after clicking "Compress folder" (it's not working anymore :( ):

Code: Select all

$ unzip -l myhamsterball.love 
Archive:  myhamsterball.love
  Length     Date   Time    Name
 --------    ----   ----    ----
        0  01-30-09 10:40   myhamsterball/
       92  03-23-08 18:34   myhamsterball/game.conf
    10854  01-24-08 03:09   myhamsterball/hamster.png
      648  03-23-08 18:34   myhamsterball/main.lua
 --------                   -------
    11594                   4 files
You see that the files are inside a subdirectory in the ZIP file, which seems to be ignored by Löve for the moment.
You must either use loveMaker (I haven't tried it yet but it's mentioned in the forum) or use the appropriate command in the Terminal, something like:

Code: Select all

cd myhamsterball/
zip ../myhamsterball.love *
or

Code: Select all

cd myhamsterball/
zip -r ../myhamsterball.love *
if you have data directories to add to the archive.

I hope it's clearer now for those who use a Mac...

Re: LOVE 0.5 Mac with working .love access

Posted: Fri Jan 30, 2009 1:17 pm
by klopfer
I note that the original post indicates that this doesn't work well with Tiger (10.4). I can confirm that-- seems to be a problem with physfs referencing some symbol in a 10.4 library.

Has anyone worked around or solved this?

Re: LOVE 0.5 Mac with working .love access

Posted: Fri Jan 30, 2009 8:36 pm
by tmm1
http://love2d.org/docs/GameDistribution.html should be updated with instructions for OSX:
cp -R /Applications/love.app mygame.app; cat file.love >> mygame.app/Contents/MacOS/love

Re: LOVE 0.5 Mac with working .love access

Posted: Fri Jan 30, 2009 10:02 pm
by rude
@ tmm1: does that actually work? Will the embedded game run?

Re: LOVE 0.5 Mac with working .love access

Posted: Sun Feb 01, 2009 8:21 pm
by xhx
klopfer wrote:I note that the original post indicates that this doesn't work well with Tiger (10.4). I can confirm that-- seems to be a problem with physfs referencing some symbol in a 10.4 library.

Has anyone worked around or solved this?
I rebuilt physfs from sources, and now games run on my 10.4

Re: LOVE 0.5 Mac with working .love access

Posted: Sun Feb 01, 2009 9:08 pm
by klopfer
Could you perhaps post or send a link to the physfs library for 10.4?

Re: LOVE 0.5 Mac with working .love access

Posted: Sun Feb 01, 2009 10:21 pm
by appleide
I wonder if it works by just selecting the X items thats supposed to be in the ZIP and right click "compress X items". It shouldn't have a subdirectory that way, theoretically speaking.