This commit is contained in:
team3
2026-09-07 07:44:09 +02:00
parent 848c8ea1aa
commit e12c2595fc
69 changed files with 7080 additions and 1165 deletions

View File

@@ -13,7 +13,8 @@ RAW = {
"role": "Caster",
"stats": {"hp": 600, "armor": 25, "magicResist": 25, "damage": 40,
"attackSpeed": 0.7, "mana": 60, "initialMana": 10},
"squareIcon": "ASSETS/x.TFT_Set17.tex",
"squareIcon": "ASSETS/x_splash_tile.TFT_Set17.tex",
"tileIcon": "ASSETS/HUD/x_Square.TFT_Set17.tex",
"ability": {
"name": "Blast",
"desc": "Deal <magicDamage>@ModifiedDamage@ (%i:scaleAP%)</magicDamage> magic damage.",
@@ -92,6 +93,23 @@ def test_resolve_spell_adaptive_and_fallback():
assert resolve_spell(utility)["spell_damage"] is None
def test_icon_url_drops_set_suffix():
"""cdragon serviert ohne Set-Suffix — mit Suffix gab es stumme 404er."""
from tft.staticdata.parse import icon_url
assert icon_url("ASSETS/Characters/TFT17_Illaoi/HUD/TFT17_Illaoi_Square.TFT_Set17.tex") == (
"https://raw.communitydragon.org/latest/game"
"/assets/characters/tft17_illaoi/hud/tft17_illaoi_square.png"
)
assert icon_url("ASSETS/UX/TraitIcons/Trait_Icon_17_Doomer.TFT_Set17.tex").endswith(
"/assets/ux/traiticons/trait_icon_17_doomer.png"
)
# Ohne Suffix bleibt der Name unverändert.
assert icon_url("ASSETS/Maps/TFT/Icons/Items/TFT_Item_BFSword.tex").endswith(
"/tft_item_bfsword.png"
)
def test_augment_tier_from_icon():
from tft.staticdata.parse import augment_tier
assert augment_tier("ASSETS/x/GodAugmentEkko_II.TFT_Set17.tex") == 2