Skip to content

Commit

Permalink
formatting and moving files
Browse files Browse the repository at this point in the history
  • Loading branch information
sbordeyne committed May 22, 2024
1 parent 66aea5e commit a93a7ad
Show file tree
Hide file tree
Showing 8 changed files with 189 additions and 42 deletions.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
93 changes: 93 additions & 0 deletions extension-src/Palettes/UI.gpl
Original file line number Diff line number Diff line change
@@ -0,0 +1,93 @@
GIMP Palette
Channels: RGBA
#
254 95 85 255 MULT
0 157 255 255 CHIPS
243 185 88 255 MONEY
254 95 85 255 XMULT
255 154 0 255 FILTER
0 157 255 255 BLUE
254 95 85 255 RED
75 194 146 255 GREEN
86 168 135 255 PALE_GREEN
253 162 0 255 ORANGE
255 154 0 255 IMPORTANT
234 192 88 255 GOLD
255 255 0 255 YELLOW
0 0 0 0 CLEAR
255 255 255 255 WHITE
136 103 165 255 PURPLE
55 66 68 255 BLACK
79 99 103 255 L_BLACK
95 115 119 255 GREY
75 194 146 255 CHANCE
191 199 213 255 JOKER_GREY
203 114 76 255 VOUCHER
100 110 183 255 BOOSTER
255 255 255 255 EDITION
0 0 0 255 DARK_EDITION
199 89 133 255 ETERNAL
55 66 68 255 DYN_UI.MAIN
55 66 68 255 DYN_UI.DARK
55 66 68 255 DYN_UI.BOSS_MAIN
55 66 68 255 DYN_UI.BOSS_DARK
55 66 68 255 DYN_UI.BOSS_PALE
240 52 100 255 SO_1.HEARTS
240 107 63 255 SO_1.DIAMONDS
64 57 149 255 SO_1.SPADES
35 89 85 255 SO_1.CLUBS
248 59 47 255 SO_2.HEARTS
226 144 0 255 SO_2.DIAMONDS
79 49 185 255 SO_2.SPADES
0 142 230 255 SO_2.CLUBS
254 95 85 255 SUITS.HEARTS
254 95 85 255 SUITS.DIAMONDS
55 70 73 255 SUITS.SPADES
66 78 84 255 SUITS.CLUBS
255 255 255 255 UI.TEXT_LIGHT
79 99 103 255 UI.TEXT_DARK
136 136 136 153 UI.TEXT_INACTIVE
184 216 216 255 UI.BACKGROUND_LIGHT
255 255 255 255 UI.BACKGROUND_WHITE
122 158 159 255 UI.BACKGROUND_DARK
102 102 102 255 UI.BACKGROUND_INACTIVE
216 216 216 255 UI.OUTLINE_LIGHT
238 238 238 34 UI.TRANSPARENT_LIGHT
34 34 34 34 UI.TRANSPARENT_DARK
0 0 0 85 UI.HOVER
205 217 220 255 SET.DEFAULT
205 217 220 255 SET.ENHANCED
66 78 84 255 SET.JOKER
66 78 84 255 SET.TAROT
66 78 84 255 SET.PLANET
66 78 84 255 SET.SPECTRAL
66 78 84 255 SET.VOUCHER
155 182 189 255 SECONDARY_SET.DEFAULT
131 137 221 255 SECONDARY_SET.ENHANCED
112 139 145 255 SECONDARY_SET.JOKER
167 130 209 255 SECONDARY_SET.TAROT
19 175 206 255 SECONDARY_SET.PLANET
69 132 250 255 SECONDARY_SET.SPECTRAL
253 104 43 255 SECONDARY_SET.VOUCHER
76 168 147 255 SECONDARY_SET.EDITION
0 157 255 255 RARITY.1
75 194 146 255 RARITY.2
254 95 85 255 RARITY.3
178 108 187 255 RARITY.4
80 132 110 255 BLIND.SMALL
80 132 110 255 BLIND.BIG
180 68 48 255 BLIND.BOSS
79 99 103 255 BLIND.WON
254 95 85 255 HAND_LEVELS.0
239 239 239 255 HAND_LEVELS.1
149 172 255 255 HAND_LEVELS.2
101 239 175 255 HAND_LEVELS.3
250 227 126 255 HAND_LEVELS.4
255 192 82 255 HAND_LEVELS.5
248 125 117 255 HAND_LEVELS.6
202 160 239 255 HAND_LEVELS.7
255 255 0 255 BACKGROUND.L
0 255 255 255 BACKGROUND.D
55 66 68 255 BACKGROUND.C
0 157 255 255 UI_CHIPS
254 95 85 255 UI_MULT
76 changes: 52 additions & 24 deletions extension-src/package.json
Original file line number Diff line number Diff line change
@@ -1,25 +1,53 @@
{
"name": "Balamod_Extension_Tools",
"displayName": "Balamod Extension Tools",
"description": "A pack of utilities and scripts for quickly creating Balatro assets.",
"version": "1.0",
"author": { "name": "jacobr1227", "url": "https://github.com/balamod/aseprite-balamod-extension"},
"contributors": [ ],
"publisher": "jacobr1227",
"license": "MIT",
"categories": [ "Scripts", "Keys", "Palettes" ],
"contributes": {
"scripts": [
{ "path": "./plugin.lua" }
],
"keys": [
{ "id": "template-key", "path": "./template-key.aseprite-keys" }
],
"palettes": [
{ "id": "Balatro_Tarot", "path": "./Tarot.gpl"},
{ "id": "Balatro_Planet", "path": "./Planet.gpl" },
{ "id": "Balatro_Seal", "path": "./Seal.gpl"},
{ "id": "Balatro_Spectral", "path": "./Spectral.gpl"}
]
}
}
"name": "Balamod_Extension_Tools",
"displayName": "Balamod Extension Tools",
"description": "A pack of utilities and scripts for quickly creating Balatro assets.",
"version": "1.0",
"author": {
"name": "jacobr1227",
"url": "https://github.com/balamod/aseprite-balamod-extension"
},
"contributors": [],
"publisher": "jacobr1227",
"license": "MIT",
"categories": [
"Scripts",
"Keys",
"Palettes"
],
"contributes": {
"scripts": [
{
"path": "./plugin.lua"
}
],
"keys": [
{
"id": "template-key",
"path": "./template-key.aseprite-keys"
}
],
"palettes": [
{
"id": "Balatro_Tarot",
"path": "./Palettes/Tarot.gpl"
},
{
"id": "Balatro_Planet",
"path": "./Palettes/Planet.gpl"
},
{
"id": "Balatro_Seal",
"path": "./Palettes/Seal.gpl"
},
{
"id": "Balatro_Spectral",
"path": "./Palettes/Spectral.gpl"
},
{
"id": "Balatro_UI",
"path": "./Palettes/UI.gpl"
}
]
}
}
58 changes: 41 additions & 17 deletions extension-src/plugin.lua
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
-- MIT License

-- Copyright (c) 2021 David Fletcher
-- Copyright (c) 2024 Balamod

-- Permission is hereby granted, free of charge, to any person obtaining a copy
-- of this software and associated documentation files (the "Software"), to deal
Expand All @@ -20,6 +20,11 @@
-- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
-- SOFTWARE.

function loadFile(data, ...)
local path = app.fs.joinPath(app.fs.userConfigPath, "extensions", "Balamod_Extension_Tools", ...)
return loadfile(path)(data)
end

function init(plugin)
print("Aseprite is initializing Balamod Extension Tools")

Expand All @@ -39,22 +44,41 @@ function init(plugin)
},
utils = dofile(app.fs.joinPath(app.fs.userConfigPath, "extensions", "Balamod_Extension_Tools", "helpers.lua")),
};

local function AddCommand(id, title, group, file, loc)
plugin:newCommand {
id=id,
title=title,
group=group,
onclick=function()
loadfile(app.fs.joinPath(app.fs.userConfigPath, "extensions", "Balamod_Extension_Tools", loc, file))(data);
end
}
end

AddCommand("Balamod_Extension_Templates","Templates","file_new","TemplateWindow.lua", "Dialogs");
AddCommand("Balamod_Extension_Tools_Blindify", "Blindify", "file_new", "Blindify.lua", "")
AddCommand("Balamod_Extension_Tools_Scaler", "1X to 2X scaler", "file_new", "1Xto2X.lua", "")

print("Registering Balamod Extension Tools menu group")
plugin:newMenuGroup{
id="balamod_extension_tools",
title="Balamod",
group="main_menu"
}
print("Registering Balamod Extension Tools commands")
print("Registering Balamod Extension Tools Templates command")
plugin:newCommand {
id="balamod_extension_tools_templates",
title="Templates",
group="balamod_extension_tools",
onclick=function()
loadFile(data, "Dialogs", "Templates.lua")
end
}
print("Registering Balamod Extension Tools Blindify command")
plugin:newCommand {
id="balamod_extension_tools_blindify",
title="Blindify",
group="balamod_extension_tools",
onclick=function()
loadFile(data, "Blindify.lua")
end
}
print("Registering Balamod Extension Tools 1X to 2X scaler command")
plugin:newCommand {
id="balamod_extension_tools_scaler",
title="1X to 2X scaler",
group="balamod_extension_tools",
onclick=function()
loadFile(data, "1Xto2X.lua")
end
}
print("Balamod extension tools installed.")
end

function exit(plugin)
Expand Down
4 changes: 3 additions & 1 deletion extension-src/template-key.aseprite-keys
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
<?xml version="1.0" encoding="utf-8" ?>
<keyboard version="1">
<commands>
<key command="Balamod_Extension_Templates" shortcut="Ctrl+Alt+T" />
<key command="balamod_extension_tools_templates" shortcut="Ctrl+Alt+T" />
<key command="balamod_extension_tools_blindify" shortcut="Ctrl+Alt+B" />
<key command="balamod_extension_tools_scaler" shortcut="Ctrl+Alt+S" />
</commands>
</keyboard>

0 comments on commit a93a7ad

Please sign in to comment.