Skip to content

Commit

Permalink
Added Dungeon Defenders example.
Browse files Browse the repository at this point in the history
  • Loading branch information
icculus committed Mar 5, 2013
1 parent 54f8f73 commit 7ac0e00
Show file tree
Hide file tree
Showing 4 changed files with 99 additions and 0 deletions.
3 changes: 3 additions & 0 deletions examples/dungeondefenders/details.txt
@@ -0,0 +1,3 @@
APPTITLE="Dungeon Defenders Installer"
DATAFILE="data/UDKGame/Config/DefaultDunDef.ini"

Binary file added examples/dungeondefenders/meta/splash.bmp
Binary file not shown.
15 changes: 15 additions & 0 deletions examples/dungeondefenders/scripts/app_localization.lua
@@ -0,0 +1,15 @@
-- Lines starting with "--" are comments in this file.
-- You should add your installer's strings here, instead of localization.lua,
-- but localization.lua has instructions on how this file is formatted.

MojoSetup.applocalization = {
["Dungeon Defenders README"] = {
de = "Dungeon Defenders-README",
es = "LEEME",
pl = "Dungeon Defenders README",
it = "Informazioni su Dungeon Defenders",
};
};

-- end of app_localization.lua ...

81 changes: 81 additions & 0 deletions examples/dungeondefenders/scripts/config.lua
@@ -0,0 +1,81 @@
local TOTAL_INSTALL_SIZE = 6027721827;

local _ = MojoSetup.translate

Setup.Package
{
vendor = "trendyent.com",
id = "dungeondefenders",
description = "Dungeon Defenders",
version = "7.48",
splash = "splash.bmp",
superuser = false,
write_manifest = true,
support_uninstall = true,
recommended_destinations =
{
MojoSetup.info.homedir,
"/opt/games",
"/usr/local/games"
},

Setup.Readme
{
description = _("Dungeon Defenders README"),
source = _("README-linux.txt")
},

Setup.Option
{
-- !!! FIXME: All this filter nonsense is because
-- !!! FIXME: source = "base:///some_dir_in_basepath/"
-- !!! FIXME: doesn't work, since it wants a file when drilling
-- !!! FIXME: for the final archive, not a directory. Fixing this
-- !!! FIXME: properly is a little awkward, though.

value = true,
required = true,
disabled = false,
bytes = TOTAL_INSTALL_SIZE,
description = "Dungeon Defenders",

Setup.File
{
wildcards = "*";
filter = function(dest)
if dest == "DungeonDefenders" then
return dest, "0755" -- make sure it's executable.
end
if dest == "UDKGame/Binaries/DungeonDefenders-x86" then
return dest, "0755" -- make sure it's executable.
end
if dest == "UDKGame/Binaries/libSDL2-2.0.so.0" then
return dest, "0755" -- make sure it's executable.
end
if dest == "UDKGame/Binaries/libopenal.so.1" then
return dest, "0755" -- make sure it's executable.
end
if dest == "UDKGame/Binaries/xdg-open" then
return dest, "0755" -- make sure it's executable.
end
return dest -- everything else just goes through as-is.
end
},

Setup.DesktopMenuItem
{
disabled = false,
name = "Dungeon Defenders",
genericname = "Dungeon Defenders",
tooltip = _("Dungeon Defenders"),
builtin_icon = false,
icon = "DunDefIcon.png",
commandline = "%0/DungeonDefenders",
workingdir = "%0",
category = "Game"
}
}
}

-- end of config.lua ...

0 comments on commit 7ac0e00

Please sign in to comment.