Distributing your games (making a .love file)
Forum rules
Before you make a thread asking for help, read this.
Before you make a thread asking for help, read this.
- Positive07
- Party member
- Posts: 1014
- Joined: Sun Aug 12, 2012 4:34 pm
- Location: Argentina
Re: Distributing your games (making a .love file)
Yeah, it may... but indie has that kind of community... I mean indie games are less likely to be cracked and redistributed than AAA games. Indie games are usually copied (not cracked) during developing time if the idea is good enough and has traction.
for i, person in ipairs(everybody) do
[tab]if not person.obey then person:setObey(true) end
end
love.system.openURL(github.com/pablomayobre)
[tab]if not person.obey then person:setObey(true) end
end
love.system.openURL(github.com/pablomayobre)
Re: Distributing your games (making a .love file)
Thanks for the answers, I just wanted to make sure this was the case and I wasn't missing a step while building the final exe
Currently working on Breaking Fast, a competitive 2D "mario kart alike" racing game! Already passed steam greenlight, hopefully soon to be released!
-
- Prole
- Posts: 12
- Joined: Fri Nov 03, 2017 5:19 pm
- Location: Pacific Northwest
- Contact:
Re: Distributing your games (making a .love file)
For those who want an easy command-line way of creating a zip archive on Windows without requiring any external tools, I find it easy enough to create a simple PowerShell script and embed it inside a batch file.
There's an example of what I mean here: https://github.com/jonthysell/RetroLove ... /build.cmd
There's an example of what I mean here: https://github.com/jonthysell/RetroLove ... /build.cmd
Re: Distributing your games (making a .love file)
Or if you have 7-zip you can use the command-line 7z.exe in a batch file. I use this method to create .love archives.
I can even provide my own name for the Archiver. Simply make a .bat in your working directory and then run it.
I can even provide my own name for the Archiver. Simply make a .bat in your working directory and then run it.
Code: Select all
@ECHO OFF
title LOVE 7z Archiver
CLS
ECHO Name the Archive!
SET /p name=:
ECHO Archiving Directory...
CALL %Program Files%\7-zip\7z.exe a %name%.love .\* -xr!*.bat -xr!*.love -xr!*.cmd
ECHO Archive Complete!
PAUSE
EXIT
- zorg
- Party member
- Posts: 3468
- Joined: Thu Dec 13, 2012 2:55 pm
- Location: Absurdistan, Hungary
- Contact:
Re: Distributing your games (making a .love file)
Unless one of those switches ensures that a plain zip archive is created, not all OS-es will be able to handle the unarchiving by default.Karasuro wrote: ↑Mon Dec 25, 2017 3:07 am Or if you have 7-zip you can use the command-line 7z.exe in a batch file. I use this method to create .love archives.
I can even provide my own name for the Archiver. Simply make a .bat in your working directory and then run it.
Code: Select all
@ECHO OFF title LOVE 7z Archiver CLS ECHO Name the Archive! SET /p name=: ECHO Archiving Directory... CALL %Program Files%\7-zip\7z.exe a %name%.love .\* -xr!*.bat -xr!*.love -xr!*.cmd ECHO Archive Complete! PAUSE EXIT
Me and my stuff True Neutral Aspirant. Why, yes, i do indeed enjoy sarcastically correcting others when they make the most blatant of spelling mistakes. No bullying or trolling the innocent tho.
Re: Distributing your games (making a .love file)
7z.exe uses a -t switch to specify what type of archive you want. Example.. -tzip is a standard .zip archive. -ttar for .tar, -tiso for a .iso archive, etc.
so in my code you could change the CALL to:
Code: Select all
...
CALL %Program Files%\7-zip\7z.exe a -tzip %name%.love .\* -xr!*.bat -xr!*.love -xr!*.cmd
...
- zorg
- Party member
- Posts: 3468
- Joined: Thu Dec 13, 2012 2:55 pm
- Location: Absurdistan, Hungary
- Contact:
Re: Distributing your games (making a .love file)
Exactly what i mean, 7zip doesn't come standard on some systems, just saying; but if you always create a zip-compatible archive, then yes, löve.exe can handle it.
Me and my stuff True Neutral Aspirant. Why, yes, i do indeed enjoy sarcastically correcting others when they make the most blatant of spelling mistakes. No bullying or trolling the innocent tho.
Re: Distributing your games (making a .love file)
What's that? Is it possible to run a .love file that is in 7z-format providing that 7z is installed? Or is it really zip only? (some posts confuse me a bit in that direction).
I personally only use zip though, although 7z takes pride to be able to create "pure zip files" that are smaller than with the original zip. Never tried that though.
And what I saw about "ripping" stuff, and "hacking/cracking" games. Well with LÖVE games it's of course (since they are just .zip files) a lot easier to do, but since I have lived in the old days where DOS and AMIGA were the big systems I know how AAA devs were trying one thing after another keeping crackers at bay. Nothing worked. I even remember a friend of mine saying one of the games (he obtained illegally ONE DAY after its official release) with a cracker scroll saying: "Stupid devs. Did you really think spending 1 million bucks would keep me away from removing your copy-protection. Next time, use something better (but it won't help you)." If you have at least set out the license well you have some ways to get rippers sued, but that also reminds me of the Dutch proverb "Dweilen met de kraan open" (lit. Mobbing while the tap's open).
When it comes to that batch file above. I am a Mac user and thus I have to do it with Unix variants, so lemme translate that batch file into a shell script:
Now I've my own ways to build love files, but this is the simplistic one using 7z (providing you installed it). I didn't try this is Linux, but I can't think of a reason why this wouldn't work in Linux (aside from not having 7z installed that is).
I personally only use zip though, although 7z takes pride to be able to create "pure zip files" that are smaller than with the original zip. Never tried that though.
And what I saw about "ripping" stuff, and "hacking/cracking" games. Well with LÖVE games it's of course (since they are just .zip files) a lot easier to do, but since I have lived in the old days where DOS and AMIGA were the big systems I know how AAA devs were trying one thing after another keeping crackers at bay. Nothing worked. I even remember a friend of mine saying one of the games (he obtained illegally ONE DAY after its official release) with a cracker scroll saying: "Stupid devs. Did you really think spending 1 million bucks would keep me away from removing your copy-protection. Next time, use something better (but it won't help you)." If you have at least set out the license well you have some ways to get rippers sued, but that also reminds me of the Dutch proverb "Dweilen met de kraan open" (lit. Mobbing while the tap's open).
When it comes to that batch file above. I am a Mac user and thus I have to do it with Unix variants, so lemme translate that batch file into a shell script:
Code: Select all
#!/bin/sh
# title LOVE 7z Archiver
clear
read -r -p 'Name the Archive: ' NAME
echo Archiving Directory...
7z a $NAME.love -tzip ./* -xr!*.bat -xr!*.love -xr!*.cmd
echo Archive Complete!
-
- Prole
- Posts: 6
- Joined: Fri Jan 05, 2018 10:56 pm
Re: Distributing your games (making a .love file)
Show-and-tell time for zip scripts?
I'm just coming back into development after stopping when I started university. As a result I just use a lazy batch script I wrote back in school, which is probably the most useful piece of code I've written:
See the problem? Back in the days all of my art came in the form of circles and lines.
I'm just coming back into development after stopping when I started university. As a result I just use a lazy batch script I wrote back in school, which is probably the most useful piece of code I've written:
Code: Select all
if exist game.love rename game.love game.zip
7z a -tzip game.zip *.lua -x!*.zip
ren game.zip game.love
start game.love
-
- Citizen
- Posts: 86
- Joined: Mon Jul 17, 2017 2:07 pm
Re: Distributing your games (making a .love file)
here's my masterpiece for mac OSX, worked on Mavericks, works on High Sirrera (mac users are cool obviously)
the clever bit is them weird quotes, because macs, being superior an all don't run their bloody equivalent of the .bat file from the same folder, they run it from your home directory... unless you use that weird unknown hack i can't remember where i found it from
so i double click the file it dumps to the desktop, i save all my little functions as .command files so they're not tied to like any knowledge or editor etc
edit: oh sorry i think i just accidentally raised the dead lol, my bad
edit2: notice whether it's shell or batch files, it always comes down to something that makes less sense than regex but "just works"
Code: Select all
# builds the entire current folder into a love file
# designed to be double clicked from mac OSX finder
# should be saved as a .command file with "sudo chmod +x" applied to it (allows it to execute)
# filename=EntityEngine_0_2_0_Alpha.love # would dump the file to the current directory
filename=~/Desktop/EntityEngine_0_2_0_Alpha.love # dump the file on the desktop
cd "`dirname "$0"`" # OSX hack that means the double clicked command file runs in the directory it is in
zip -9 -r $filename .
read # OSX hack allows waiting for a key press before command box is closed
so i double click the file it dumps to the desktop, i save all my little functions as .command files so they're not tied to like any knowledge or editor etc
edit: oh sorry i think i just accidentally raised the dead lol, my bad
edit2: notice whether it's shell or batch files, it always comes down to something that makes less sense than regex but "just works"
Who is online
Users browsing this forum: Bing [Bot], Google [Bot] and 5 guests