Skip to content
Snippets Groups Projects
Commit d2bd328a authored by dg's avatar dg
Browse files

New "video" option in the boot menu: Censor boot; (on by default), when...

New "video" option in the boot menu: Censor boot; (on by default), when disabled it allows to select between all boot images


git-svn-id: http://svn.net-core.org/repos/t-engine4@6180 51575b47-30f0-44d4-a5cc-537603b46e54
parent 6f6f02a6
No related branches found
No related tags found
No related merge requests found
game/engines/default/data/gfx/background/tome.png

1.08 MiB | W: | H:

game/engines/default/data/gfx/background/tome.png

980 KiB | W: | H:

game/engines/default/data/gfx/background/tome.png
game/engines/default/data/gfx/background/tome.png
game/engines/default/data/gfx/background/tome.png
game/engines/default/data/gfx/background/tome.png
  • 2-up
  • Swipe
  • Onion skin
......@@ -106,7 +106,7 @@ function _M:loadDefinition(dir, team, incompatible)
-- print("Loading module definition from", team and (dir.."/mod/init.lua") or (dir.."/init.lua"))
if mod_def then
-- Call the file body inside its own private environment
local mod = {rng=rng}
local mod = {rng=rng, config=config}
setfenv(mod_def, mod)
mod_def()
mod.rng = nil
......
......@@ -145,5 +145,14 @@ function _M:generateList()
end), 50)
end,}
local zone = Textzone.new{width=self.c_desc.w, height=self.c_desc.h, text=string.toTString"Disallow boot images that could be fuond 'offensive'.#WHITE#"}
list[#list+1] = { zone=zone, name=string.toTString"#GOLD##{bold}#Censor boot#WHITE##{normal}#", status=function(item)
return tostring(config.settings.censor_boot and "enabled" or "disabled")
end, fct=function(item)
config.settings.censor_boot = not config.settings.censor_boot
game:saveSettings("censor_boot", ("censor_boot = %s\n"):format(tostring(config.settings.censor_boot)))
self.c_list:drawItem(item)
end,}
self.list = list
end
......@@ -59,6 +59,7 @@ mouse_cursor = true
display_fps = 30
gamma_correction = 120
mouse_move = true
censor_boot = true
chat.filter = {}
addons = {}
]]
......
......@@ -51,7 +51,13 @@ function _M:init()
engine.interface.GameSound.init(self)
engine.GameEnergyBased.init(self, engine.KeyBind.new(), 100, 100)
self.profile_font = core.display.newFont("/data/font/DroidSerif-Italic.ttf", 14)
self.background = core.display.loadImage("/data/gfx/background/tome3.png")
local background_name
if not config.settings.censor_boot then background_name = {"tome","tome2","tome3"}
else background_name = {"tome3"}
end
self.background = core.display.loadImage("/data/gfx/background/"..util.getval(background_name)..".png")
if self.background then
self.background_w, self.background_h = self.background:getSize()
self.background, self.background_tw, self.background_th = self.background:glTexture()
......
......@@ -30,5 +30,6 @@ Bootmenu!
]]
starter = "mod.load"
loading_wait_ticks = 1600
--background_name = {"tome","tome2","tome3"}
background_name = {"tome3"}
if not config.settings.censor_boot then background_name = {"tome","tome2","tome3"}
else background_name = {"tome3"}
end
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment