Page 15 of 28

Re: Distributing your games (making a .love file)

Posted: Wed Feb 02, 2011 9:25 am
by BlackBulletIV
For a Linux and Mac friendly version, here's a Ruby script.
Make sure you're in the project directory when executing, and that you provide a filename for the .love file (with or without the extension).

Code: Select all

#!/usr/bin/env ruby

if ARGV.length == 0
    print "Usage: ./make_love_file.rb love_file_location\n"
    print "Make sure you are in the project folder when using this command..\n"
    exit 0
end

unless File.exists? 'main.lua'
    print "Directory does not contain a main.lua file.\n"
    exit 1
end

if ARGV[0]
    file = ARGV[0]
    file += '.love' unless file.end_with? '.love'
    
    `zip -r #{file} *`
    
    if $?.exitstatus == 0
        print "#{ARGV[0]}.love created successfully.\n"
    else
        print "An error occurred file creating the file.\n"
    end
else
    print "Please give a name for the .love file.\n"
    exit 1
end
EDIT: On Mac OSX, a cool thing to do is add this to your ~/.bash_profile file:

Code: Select all

alias lovemake="path/to/where/you/placed/script.rb"
Then you can execute like this from anywhere:

Code: Select all

lovemake LoveFileName

Re: Distributing your games (making a .love file)

Posted: Wed Feb 02, 2011 11:00 pm
by BlackBulletIV
I've expanded the script above into "Love Builder". Here's the topic: http://love2d.org/forums/viewtopic.php?f=5&t=2436

Re: Distributing your games (making a .love file)

Posted: Tue Feb 15, 2011 2:44 am
by Victor Bjelkholm
How can this be stickied when the video in the first post doesn't work?

Re: Distributing your games (making a .love file)

Posted: Tue Feb 15, 2011 3:43 am
by BlackBulletIV
Spreken ze web page? :P

EDIT: Oh so there was a video here earlier...

Re: Distributing your games (making a .love file)

Posted: Tue Feb 15, 2011 10:42 am
by Robin
Victor Bjelkholm wrote:How can this be stickied when the video in the first post doesn't work?
Check the date.

Mike has removed the videos since.

Re: Distributing your games (making a .love file)

Posted: Tue Feb 15, 2011 11:18 am
by Victor Bjelkholm
Robin wrote:
Victor Bjelkholm wrote:How can this be stickied when the video in the first post doesn't work?
Check the date.

Mike has removed the videos since.
I understand that he removed the video... But I can't understand why this is still a sticky.

Re: Distributing your games (making a .love file)

Posted: Sun Feb 20, 2011 2:34 pm
by obur
hey, i'm sorry to waste your time and blablabla, but i have a problem in making my .love file to .exe in win (of course).
when i navigate to my folder that my game.love exists in dos, then when i write "copy /b love.exe+game.love game.exe" it says it's ok, everything done and stuff, but when i open the newly created game.exe, i just see love.exe's turning worms. that's all. no game, nothing else.
i can see my work clearly when i drag&drop my game to love.exe, but i just couldn't do this exe thing.
please help me.
thanks in advance.
(if i act bad, i mean rude, sorry about that. my hands are shaking because of anger..)

Re: Distributing your games (making a .love file)

Posted: Sun Feb 20, 2011 5:17 pm
by bartbes
I ehm.. probably broke it.

Re: Distributing your games (making a .love file)

Posted: Sun Feb 20, 2011 5:21 pm
by obur
so, what must i do now? :)

Re: Distributing your games (making a .love file)

Posted: Sun Feb 20, 2011 5:29 pm
by bartbes
You could try the 0.7.0 binary, but yeah...