Skip to content

Commit

Permalink
JokerDisplay compat for Power Grid
Browse files Browse the repository at this point in the history
  • Loading branch information
TehSeph committed Oct 13, 2024
1 parent 0420edd commit f2e2c75
Showing 1 changed file with 13 additions and 22 deletions.
35 changes: 13 additions & 22 deletions jokers/powergrid.lua
Original file line number Diff line number Diff line change
Expand Up @@ -47,27 +47,18 @@ SMODS.Joker {
if SMODS.Mods['JokerDisplay'] and _G['JokerDisplay'] then
local jd_def = JokerDisplay.Definitions
jd_def["j_kcva_powergrid"] = {
--[[
This PR includes tooltips for all Jokers except for Power Grid. I don't understand what that Joker does...
I assume it should be starting at "x1.0" and gaining "x0.2" for every playing card scored with +Mult, then resetting on round end.
Testing in game, however, I can't get it to increase (or decrease) from "x1.2"... It even starts the round at "x1.2"!
And even while claiming "x1.2", it doesn't seem to ever actually apply that "x0.2" mult anywhere. Played hands just skip this Joker.
I've tried +Mult, xMult, Holographic, Polychrome, Lucky, and Red Seal. Nothing changes. The code looks fine, so I don't understand.
Testing was done with:
- Balatro 1.0.1g
- Lovely 0.5.0-beta7
- Steammodded 1.0.0-1006a
- "_RELEASE_MODE = false"
I wasn't even including JokerDisplay compat in testing, just this mod and the Joker's core functionality.
*shrugs* I'm leaving it with no display for now. I don't want to add something that I cannot test for.
I assume just a simple "x_mult" border_node is all that is needed. (Can be copied directly from Handy.)
Please discuss within this PR (or Discord) and I will update it, or you may merge this and do so yourself.
~Toranaado (@TehSeph)
]] --
text = {
{ text = "Next " },
{ text = "Mult ", colour = G.C.IMPORTANT }, -- No localization for "Mult"
{ text = "Card " }, -- No localization for "Cards"
{
border_nodes = {
{ ref_table = "card.joker_display_values", ref_value = "next_xmult", retrigger_type = "exp" }
}
}
},
calc_function = function(card)
card.joker_display_values.next_xmult = "X"..(1 + card.ability.extra + ((G.GAME.current_round.kcv_mults_scored or 0) * card.ability.extra))
end
}
end

0 comments on commit f2e2c75

Please sign in to comment.