Don't Starve Together

Don't Starve Together

Ei tarpeeksi arvosteluja
Static Wallpaper
   
Palkinto
Lisää suosikkeihin
Lisätty suosikkeihin
Poista suosikeista
Tiedostokoko
Julkaistu
Päivitetty
87.754 KB
18.4.2022 klo 7.49
24.10.2023 klo 0.54
13 muutosilmoitusta ( näytä )

Tilaa ladataksesi
Static Wallpaper

1 kokoelmassa, tekijä RICK
2023可用客户端mod推荐Usable Client Mods Recommendation
128 luomusta
Kuvaus
Let's celebrate for this wonderful mod, WallPaper Engine in DST!
https://steamcommunity.com/sharedfiles/filedetails/?id=2795671031
So I made my own version, using static images only.

For modders:
Global Variable WallPaper = {
images = {},
anims = {},
loadings={},
add = function(id)
table.insert(Assets, Asset("ATLAS", "images/" .. id .. ".xml"))
table.insert(Assets, Asset("IMAGE", "images/" .. id .. ".tex"))
table.insert(WallPaper.images, {"images/" .. id .. ".xml", id .. ".tex"})
end,
addloading=function(id)end,
create = function(type)
local selected = WallPaper.choose(type)
return selected and Image(selected[1], selected[2]) or nil
end,
choose = function(type)
end,
position = function(element)
end,
maininit = function(self)
end,
multiinit = function(self)
end,
modinit = function()
-- load assets
if not IsServer() and not IsClient() then
modimport("loadassets.lua")
end
end,
serverinit=function(self)
end
}
To avoid conflict between your mod and this API, I introduced a function table called WallPaperCall:
modinit = function()
-- load assets
modimport("loadassets.lua")
if rawget(GLOBAL,"WallPaperCall") then
for i,v in ipairs(WallPaperCall) do
v()
end
end
end
You need to check whether WallPaper already exists, if false, then insert your init function into WallPaperCall(try to check if it exists!), thus the API will call these functions when it loads.

You can just insert anything into this table, or rewrite any of these functions.
To create your own wallpapers, you need to install Don't Starve Mod Tools, and know how to convert images to atlas.
To batch load assets, run generate.py in the mod folder. You can see the result in loadassets.lua
To batch crop assets and load, run convert.py, granted that you've installed Python and OpenCV library.
The images are best shaped 1280x720, 1920x1080, etc, according to the size of your screen. It is advised that downsize large files will lower memory usage. convert.py tries to resize images to 1.7777777:1 and within 1820x1024 for optimization(guaranteed to be within 2048x1024 range). But you can freely adjust the params.

All the sample images are collected from the internet. Do inform me of any possible copyright issues.
Datasets are removed from this mod. If you want wallpapers built by me, use this mod:
https://steamcommunity.com/sharedfiles/filedetails/?id=2796620934
https://steamcommunity.com/sharedfiles/filedetails/?id=2796652971
https://steamcommunity.com/sharedfiles/filedetails/?id=2796662041

How to simply create some wallpapers:
1. Download the dataset(the first one for example), find where folder "2796620934" is, cut and paste the folder to "Don't Starve Together/mods/"
2. delete everything in "images/"
3. put your images in "images/"
(3.5 If your images differ drastically, or have width:height ratio away from 1.77:1, or the file names contain special characters, it is wise to run convert.py first. Apparently you must install python and OpenCV.)
4. Download Don't Starve Mod Tools in Steam
5. run "autocompiler.exe"
6. run generate.py, You have to install Python beforehand.
7. check whether loadassets.lua has something in it.
8. delete your images as they are no longer needed.
9. open the game to see if wallpapers are loaded.

20220430 edit:
What, wait, you see WX-78's leg? I'm not going to fix that lol.

20230911 edit:
Add loading screen.

Search Tags:
Remove mainscreen motd news overlay

DS version:
https://steamcommunity.com/sharedfiles/filedetails/?id=2948484096
14 kommenttia
lakhnish_monster 24.10.2023 klo 11.17 
Thank you!
RICK  [tekijä] 24.10.2023 klo 0.43 
OK, that's server slot screen. You can view it by pressing backspace key. Its name will show on the top.
lakhnish_monster 23.10.2023 klo 12.46 
When you first launch the game from steam, then hit the "Host Game" button, which is button underneath Browse Games. Here's an Imgur link: https://imgur.com/8rqyGkp
RICK  [tekijä] 22.10.2023 klo 23.34 
@flaperon you are not supposed to edit them. They are calculated by the converters.
@lakhnish_monster what is a host game menu? The server creation screen?
lakhnish_monster 12.10.2023 klo 18.27 
Is it possible to add a mod config for the host game menu?
flaperon 6.10.2023 klo 13.01 
how to configure u1,u2,v1,v2 correctly?
RICK  [tekijä] 29.4.2023 klo 16.37 
OK, I'll update.
lakhnish_monster 29.4.2023 klo 11.15 
Hello,

Is it possible to get a mod config option so that the changed menu doesn't show up for the login screen or the browse games screen? I would greatly appreciate it.:SaffronHappy:
lakhnish_monster 28.4.2023 klo 16.15 
Awesome, thanks!
RICK  [tekijä] 28.4.2023 klo 16.07 
There are many wallpaper mods in the workshop, so do whatever you want. You can even publish a standalone mod.