36 lines
1.9 KiB
Python
36 lines
1.9 KiB
Python
|
|
# -*- coding: utf-8 -*-
|
||
|
|
# 2026-10-02 PD 지시(자율 반복) — 같은 길잡이의 "지금 색 조합(밝은 금 + 적/청)"과 "어두운 색 조합(a22)"을 나란히 놓은 비교 시트(PD 방향 결정용).
|
||
|
|
# python icon_compare_sheet.py
|
||
|
|
# 열: 지금(앞 회차의 같은 행 #0) | 어두운 조합 ANFG 0.7 #0 · #1 | ANFG 0.8 #0 · #1
|
||
|
|
import os
|
||
|
|
from PIL import Image, ImageDraw
|
||
|
|
|
||
|
|
ROOT = os.path.join(os.path.dirname(os.path.abspath(__file__)), "moba_anfg")
|
||
|
|
ROWS = [("armor-fr1267", "a17"), ("boots-fr1379", "a17"), ("gloves-fr1183", "a17"), ("necklace-fr1099", "a17"), ("belt-fr1351", "a17"),
|
||
|
|
("helmet-genmoba0", "a17"), ("blunt-fr1057", "a17"), ("shield-genxl1", "a19"), ("sword-genxl1", "a19"), ("staff-genxlb0", "a20")]
|
||
|
|
HEAD = ["now (bright)", "dark 0.7 #0", "dark 0.7 #1", "dark 0.8 #0", "dark 0.8 #1"]
|
||
|
|
|
||
|
|
|
||
|
|
def main():
|
||
|
|
cell, pad, top = 200, 4, 18
|
||
|
|
sheet = Image.new("RGB", (len(HEAD) * (cell + pad) + pad, top + len(ROWS) * (cell + pad) + pad), (24, 24, 28))
|
||
|
|
d = ImageDraw.Draw(sheet)
|
||
|
|
for c, h in enumerate(HEAD):
|
||
|
|
d.text((pad + c * (cell + pad) + 4, 3), h, fill=(240, 220, 160))
|
||
|
|
for r, (row, old) in enumerate(ROWS):
|
||
|
|
files = ["%s_%s_s07_0.png" % (old, row), "a22_%s_s07_0.png" % row, "a22_%s_s07_1.png" % row, "a22_%s_s08_0.png" % row, "a22_%s_s08_1.png" % row]
|
||
|
|
for c, fn in enumerate(files):
|
||
|
|
path = os.path.join(ROOT, fn)
|
||
|
|
if not os.path.exists(path):
|
||
|
|
continue
|
||
|
|
im = Image.open(path).convert("RGBA")
|
||
|
|
# 게임 칸과 비슷한 어두운 바탕
|
||
|
|
bg = Image.new("RGB", (cell, cell), (40, 40, 46)); small = im.resize((cell, cell), Image.LANCZOS); bg.paste(small, (0, 0), small)
|
||
|
|
sheet.paste(bg, (pad + c * (cell + pad), top + r * (cell + pad)))
|
||
|
|
out = os.path.join(ROOT, "a22_compare.png")
|
||
|
|
sheet.save(out); print(out)
|
||
|
|
|
||
|
|
|
||
|
|
if __name__ == "__main__":
|
||
|
|
main()
|