postload: upscale all HD cursors
This commit is contained in:
parent
044d6a38d4
commit
74ea816f8a
@ -1,4 +1,5 @@
|
||||
-- Revert cursor frames if a mod replaced cursors.png with a SD version again
|
||||
-- Otherwise, scale down our HD cursors
|
||||
if assets.image("/cursors/cursors.png"):size()[1] == 64 then
|
||||
local path = "/cursors/opensb/revert.cursor.patch"
|
||||
assets.add(path, '{"scale":null}')
|
||||
@ -8,6 +9,14 @@ if assets.image("/cursors/cursors.png"):size()[1] == 64 then
|
||||
path = "/cursors/opensb/revert.frames.patch"
|
||||
assets.add(path, '{"frameGrid":{"size":[16,16]}}')
|
||||
assets.patch("/cursors/cursors.frames", path)
|
||||
else
|
||||
local cursors = assets.json("/cursors/cursors.frames:frameGrid.names")
|
||||
local path = "/cursors/%s.cursor.patch"
|
||||
for i = 1, #cursors do
|
||||
for j = 1, #cursors[i] do
|
||||
assets.add(string.format(path, cursors[i][j]), '{"scale":1}')
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
-- Add object patches
|
||||
|
Loading…
Reference in New Issue
Block a user