CARVIEW |
Select Language
HTTP/2 200
date: Sat, 11 Oct 2025 15:05:43 GMT
content-type: text/html; charset=UTF-8
server: cloudflare
x-frame-options: DENY
x-content-type-options: nosniff
x-xss-protection: 1;mode=block
vary: accept-encoding
cf-cache-status: DYNAMIC
content-encoding: gzip
set-cookie: _csrf-frontend=596cb9454fda017471627e51c249a9b01595f535e843639b31c9024cd6e4bb58a%3A2%3A%7Bi%3A0%3Bs%3A14%3A%22_csrf-frontend%22%3Bi%3A1%3Bs%3A32%3A%22JHDAicKOdiFvcRDPFtJXl2as2Bjb1YN7%22%3B%7D; HttpOnly; Path=/
cf-ray: 98cf41dadb396cd6-BLR
Aseprite fast palette switch - Pastebin.com
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function switch_to_palette(fname)
- if fname == "" then return end
- local newPalette = Palette{ fromFile=fname }
- if not newPalette then
- print("Could not load palette")
- return
- end
- oldPalette = app.activeSprite.palettes[1]
- if #newPalette < #oldPalette then -- Never move to a smaller palette, to be safe
- newPalette:resize(#oldPalette)
- end
- app.activeSprite:setPalette(newPalette)
- end
- local dlg = Dialog("Fast Palette Swap")
- dlg
- :button{text="1",onclick=function() switch_to_palette(dlg.data.pal1) end}
- :button{text="2",onclick=function() switch_to_palette(dlg.data.pal2) end}
- :button{text="3",onclick=function() switch_to_palette(dlg.data.pal3) end}
- :button{text="4",onclick=function() switch_to_palette(dlg.data.pal4) end}
- :newrow()
- :file{ id="pal1", title="Select a file for palette 1", open=true}
- :file{ id="pal2", title="Select a file for palette 2", open=true}
- :file{ id="pal3", title="Select a file for palette 3", open=true}
- :file{ id="pal4", title="Select a file for palette 4", open=true}
- :show{wait=false}
Advertisement
Add Comment
Please, Sign In to add comment
-
⭐✅ Swapzone Glitch ✅ Working⭐⭐⭐ I
JavaScript | 3 sec ago | 0.24 KB
-
⭐ Free Crypto Method ✅ NEVER SEEN BEFORE ⭐⭐⭐
JavaScript | 5 sec ago | 0.24 KB
-
✅ Make $2500 in 20 minutes⭐⭐⭐ A
JavaScript | 14 sec ago | 0.24 KB
-
✅⭐ Make huge profits on trading ✅ NEVER SEEN...
JavaScript | 15 sec ago | 0.24 KB
-
⭐⭐Exchange Exploit⭐⭐ 5
JavaScript | 25 sec ago | 0.24 KB
-
⭐✅ Marketplace Glitch ✅ Working ✅ NEVER SEEN...
JavaScript | 26 sec ago | 0.24 KB
-
✅⭐ Make $2500 in 15 minutes ✅ NEVER SEEN BEFO...
JavaScript | 35 sec ago | 0.24 KB
-
✅⭐ Make huge profits on trading ⭐⭐ T
JavaScript | 36 sec ago | 0.24 KB
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand