Skip to content

Commit adf9d34

Browse files
JollyBot: auto-format Lua files using Stylua
1 parent c9285ce commit adf9d34

File tree

9 files changed

+3767
-3759
lines changed

9 files changed

+3767
-3759
lines changed

Cryptid.lua

Lines changed: 312 additions & 312 deletions
Large diffs are not rendered by default.

https/thread.lua

Lines changed: 36 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -1,36 +1,36 @@
1-
require("love.system")
2-
3-
-- mac/linux support?
4-
5-
local script_path = debug.getinfo(1, "S").source:sub(2)
6-
local script_dir = script_path:match("(.*/)")
7-
8-
package.path = script_dir .. "?.lua;" .. package.path
9-
package.cpath = script_dir .. "?.so;" .. package.cpath
10-
11-
local index_os = love.system.getOS()
12-
13-
if index_os == "OS X" then
14-
loc_https = require("macos-https")
15-
elseif index_os == "Linux" then
16-
loc_https = require("linux-https")
17-
else
18-
loc_https = require("https")
19-
end
20-
21-
local last_update_time = 0
22-
local initial = true
23-
while true do
24-
if (os.time() - last_update_time >= 60) or initial then
25-
initial = nil
26-
last_update_time = os.time()
27-
local resp, txt = loc_https.request(
28-
"https://discord.com/api/v10/invites/eUf9Ur6RyB?with_counts=true" .. "&v=" .. tostring(os.time())
29-
)
30-
if resp == 200 then
31-
love.thread.getChannel("member_count"):push(txt)
32-
else
33-
love.thread.getChannel("member_error"):push("Failed to get count: " .. resp)
34-
end
35-
end
36-
end
1+
require("love.system")
2+
3+
-- mac/linux support?
4+
5+
local script_path = debug.getinfo(1, "S").source:sub(2)
6+
local script_dir = script_path:match("(.*/)")
7+
8+
package.path = script_dir .. "?.lua;" .. package.path
9+
package.cpath = script_dir .. "?.so;" .. package.cpath
10+
11+
local index_os = love.system.getOS()
12+
13+
if index_os == "OS X" then
14+
loc_https = require("macos-https")
15+
elseif index_os == "Linux" then
16+
loc_https = require("linux-https")
17+
else
18+
loc_https = require("https")
19+
end
20+
21+
local last_update_time = 0
22+
local initial = true
23+
while true do
24+
if (os.time() - last_update_time >= 60) or initial then
25+
initial = nil
26+
last_update_time = os.time()
27+
local resp, txt = loc_https.request(
28+
"https://discord.com/api/v10/invites/eUf9Ur6RyB?with_counts=true" .. "&v=" .. tostring(os.time())
29+
)
30+
if resp == 200 then
31+
love.thread.getChannel("member_count"):push(txt)
32+
else
33+
love.thread.getChannel("member_error"):push("Failed to get count: " .. resp)
34+
end
35+
end
36+
end

items/code.lua

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4553,9 +4553,13 @@ local cut = {
45534553
end
45544554
if context.joker_main and (to_big(card.ability.extra.Xmult) > to_big(1)) then
45554555
return {
4556-
message = localize({ type = "variable", key = "a_xmult", vars = {
4557-
number_format(card.ability.extra.Xmult),
4558-
} }),
4556+
message = localize({
4557+
type = "variable",
4558+
key = "a_xmult",
4559+
vars = {
4560+
number_format(card.ability.extra.Xmult),
4561+
},
4562+
}),
45594563
Xmult_mod = card.ability.extra.Xmult,
45604564
colour = G.C.MULT,
45614565
}

items/exotic.lua

Lines changed: 42 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -279,9 +279,13 @@ local exponentia = {
279279
calculate = function(self, card, context)
280280
if context.joker_main and (to_big(card.ability.extra.Emult) > to_big(1)) then
281281
return {
282-
message = localize({ type = "variable", key = "a_powmult", vars = {
283-
number_format(card.ability.extra.Emult),
284-
} }),
282+
message = localize({
283+
type = "variable",
284+
key = "a_powmult",
285+
vars = {
286+
number_format(card.ability.extra.Emult),
287+
},
288+
}),
285289
Emult_mod = card.ability.extra.Emult,
286290
colour = G.C.DARK_EDITION,
287291
}
@@ -304,20 +308,13 @@ local exponentia = {
304308
for _, v in pairs(find_joker("cry-Exponentia")) do
305309
local old = v.ability.extra.Emult
306310
v.ability.extra.Emult = v.ability.extra.Emult + v.ability.extra.Emult_mod
307-
card_eval_status_text(
308-
v,
309-
"extra",
310-
nil,
311-
nil,
312-
nil,
313-
{
314-
message = localize({
315-
type = "variable",
316-
key = "a_powmult",
317-
vars = { number_format(to_big(v.ability.extra.Emult)) },
318-
}),
319-
}
320-
)
311+
card_eval_status_text(v, "extra", nil, nil, nil, {
312+
message = localize({
313+
type = "variable",
314+
key = "a_powmult",
315+
vars = { number_format(to_big(v.ability.extra.Emult)) },
316+
}),
317+
})
321318
exponentia_scale_mod(v, v.ability.extra.Emult_mod, old, v.ability.extra.Emult)
322319
end
323320
end
@@ -622,9 +619,13 @@ local primus = {
622619
end
623620
if context.joker_main and (to_big(card.ability.extra.Emult) > to_big(1)) then
624621
return {
625-
message = localize({ type = "variable", key = "a_powmult", vars = {
626-
number_format(card.ability.extra.Emult),
627-
} }),
622+
message = localize({
623+
type = "variable",
624+
key = "a_powmult",
625+
vars = {
626+
number_format(card.ability.extra.Emult),
627+
},
628+
}),
628629
Emult_mod = card.ability.extra.Emult,
629630
colour = G.C.DARK_EDITION,
630631
}
@@ -776,9 +777,13 @@ local stella_mortis = {
776777
end
777778
if context.joker_main and (to_big(card.ability.extra.Emult) > to_big(1)) then
778779
return {
779-
message = localize({ type = "variable", key = "a_powmult", vars = {
780-
number_format(card.ability.extra.Emult),
781-
} }),
780+
message = localize({
781+
type = "variable",
782+
key = "a_powmult",
783+
vars = {
784+
number_format(card.ability.extra.Emult),
785+
},
786+
}),
782787
Emult_mod = card.ability.extra.Emult,
783788
colour = G.C.DARK_EDITION,
784789
}
@@ -1305,9 +1310,13 @@ local duplicare = {
13051310
end
13061311
if context.joker_main and (to_big(card.ability.extra.Xmult) > to_big(1)) then
13071312
return {
1308-
message = localize({ type = "variable", key = "a_xmult", vars = {
1309-
number_format(card.ability.extra.Xmult),
1310-
} }),
1313+
message = localize({
1314+
type = "variable",
1315+
key = "a_xmult",
1316+
vars = {
1317+
number_format(card.ability.extra.Xmult),
1318+
},
1319+
}),
13111320
Xmult_mod = card.ability.extra.Xmult,
13121321
colour = G.C.MULT,
13131322
}
@@ -1444,9 +1453,13 @@ local formidiulosus = {
14441453
and not context.after
14451454
then
14461455
return {
1447-
message = localize({ type = "variable", key = "a_powmult", vars = {
1448-
number_format(card.ability.extra.Emult),
1449-
} }),
1456+
message = localize({
1457+
type = "variable",
1458+
key = "a_powmult",
1459+
vars = {
1460+
number_format(card.ability.extra.Emult),
1461+
},
1462+
}),
14501463
Emult_mod = card.ability.extra.Emult,
14511464
colour = G.C.DARK_EDITION,
14521465
}

items/misc.lua

Lines changed: 12 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -179,8 +179,7 @@ local mosaic = {
179179
context.edition -- for when on jonklers
180180
and context.cardarea == G.jokers -- checks if should trigger
181181
and card.config.trigger -- fixes double trigger
182-
)
183-
or (
182+
) or (
184183
context.main_scoring -- for when on playing cards
185184
and context.cardarea == G.play
186185
)
@@ -463,13 +462,10 @@ local glitched = {
463462
return true
464463
end,
465464
}))
466-
update_hand_text(
467-
{ delay = 0 },
468-
{
469-
chips = (to_big(amount) > to_big(0) and "+" or "-") .. number_format(math.abs(modc)),
470-
StatusText = true,
471-
}
472-
)
465+
update_hand_text({ delay = 0 }, {
466+
chips = (to_big(amount) > to_big(0) and "+" or "-") .. number_format(math.abs(modc)),
467+
StatusText = true,
468+
})
473469
update_hand_text({ delay = 1.3 }, { chips = G.GAME.hands[hand].chips })
474470
for i = 1, math.random(2, 4) do
475471
update_hand_text(
@@ -486,13 +482,10 @@ local glitched = {
486482
return true
487483
end,
488484
}))
489-
update_hand_text(
490-
{ delay = 0 },
491-
{
492-
mult = (to_big(amount) > to_big(0) and "+" or "-") .. number_format(math.abs(modm)),
493-
StatusText = true,
494-
}
495-
)
485+
update_hand_text({ delay = 0 }, {
486+
mult = (to_big(amount) > to_big(0) and "+" or "-") .. number_format(math.abs(modm)),
487+
StatusText = true,
488+
})
496489
update_hand_text({ delay = 1.3 }, { mult = G.GAME.hands[hand].mult })
497490
elseif hand == G.handlist[#G.handlist] then
498491
G.E_MANAGER:add_event(Event({
@@ -562,8 +555,7 @@ local astral = {
562555
context.edition -- for when on jonklers
563556
and context.cardarea == G.jokers -- checks if should trigger
564557
and card.config.trigger -- fixes double trigger
565-
)
566-
or (
558+
) or (
567559
context.main_scoring -- for when on playing cards
568560
and context.cardarea == G.play
569561
)
@@ -679,8 +671,7 @@ local noisy = {
679671
context.edition -- for when on jonklers
680672
and context.cardarea == G.jokers -- checks if should trigger
681673
and card.config.trigger -- fixes double trigger
682-
)
683-
or (
674+
) or (
684675
context.main_scoring -- for when on playing cards
685676
and context.cardarea == G.play
686677
)
@@ -944,8 +935,7 @@ local jollyedition = {
944935
context.edition -- for when on jonklers
945936
and context.cardarea == G.jokers -- checks if should trigger
946937
and card.config.trigger -- fixes double trigger
947-
)
948-
or (
938+
) or (
949939
context.main_scoring -- for when on playing cards
950940
and context.cardarea == G.play
951941
)

items/spooky.lua

Lines changed: 15 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -772,20 +772,17 @@ local flickering = {
772772
if context.post_trigger and context.other_joker == card then
773773
card.ability.flick_tally = card.ability.flick_tally - 1
774774
if card.ability.flick_tally > 0 then
775-
card_eval_status_text(
776-
card,
777-
"extra",
778-
nil,
779-
nil,
780-
nil,
781-
{
782-
message = localize({ type = "variable", key = "a_remaining", vars = {
775+
card_eval_status_text(card, "extra", nil, nil, nil, {
776+
message = localize({
777+
type = "variable",
778+
key = "a_remaining",
779+
vars = {
783780
card.ability.flick_tally,
784-
} }),
785-
colour = G.C.FILTER,
786-
delay = 0.45,
787-
}
788-
)
781+
},
782+
}),
783+
colour = G.C.FILTER,
784+
delay = 0.45,
785+
})
789786
else
790787
card.will_shatter = true
791788
G.E_MANAGER:add_event(Event({
@@ -802,7 +799,11 @@ local flickering = {
802799
card.ability.flick_tally = card.ability.flick_tally - 1
803800
if card.ability.flick_tally > 0 then
804801
card_eval_status_text(card, "extra", nil, nil, nil, {
805-
message = localize({ type = "variable", key = "a_remaining", vars = { card.ability.flick_tally } }),
802+
message = localize({
803+
type = "variable",
804+
key = "a_remaining",
805+
vars = { card.ability.flick_tally },
806+
}),
806807
colour = G.C.FILTER,
807808
delay = 0.45,
808809
})

lib/content.lua

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -315,11 +315,11 @@ SMODS.ObjectType({
315315
self:inject_card(G.P_CENTERS.j_space)
316316
end,
317317
})
318-
SMODS.ObjectType ( {
319-
object_type = "ObjectType",
320-
key = "Tier3",
321-
default = "v_blank",
322-
cards = {},
318+
SMODS.ObjectType({
319+
object_type = "ObjectType",
320+
key = "Tier3",
321+
default = "v_blank",
322+
cards = {},
323323
})
324324
SMODS.ObjectType({
325325
object_type = "ObjectType",

localization/en-us.lua

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2160,7 +2160,7 @@ return {
21602160
text = {
21612161
"After scoring {C:attention}#2#{} {C:inactive}[#1#]{} Enhanced",
21622162
"cards, sell this card to",
2163-
"create a(n) {V:1}#3#{} {C:attention}Joker{}",
2163+
"create a(n) {V:1}#3#{} {C:attention}Joker{}",
21642164
},
21652165
},
21662166
j_cry_savvy = {

0 commit comments

Comments
 (0)