end_of_eden/assets/scripts/cards/shield_bash.lua
Daniel Schmidt b2fdbee545 Lua format.
2023-05-16 10:45:31 +02:00

22 lines
754 B
Lua

register_card("SHIELD_BASH", {
name = "Shield Bash",
description = "Deal 4 (+2 for each upgrade) damage to the enemy and gain " .. highlight("block") ..
" status effect equal to the damage dealt.",
state = function(ctx)
return "Deal " .. highlight(4 + ctx.level * 2) .. " damage to the enemy and gain " .. highlight("block") ..
" status effect equal to the damage dealt."
end,
max_level = 1,
color = "#ff5722",
need_target = true,
point_cost = 1,
price = 40,
callbacks = {
on_cast = function(ctx)
local damage = deal_damage(ctx.caster, 4 + ctx.level * 2)
give_status_effect("BLOCK", ctx.caster, damage)
return nil
end
}
})