BurningTimesAi/공유/기획/FirstRising/맵/tools/patch_look2.py

40 lines
4.1 KiB
Python

# -*- coding: utf-8 -*-
# 화면 확인(2026-09-28 BT36) 뒤 손보기 2: 사막 소품 색 · 사막 맵 정의(분위기 · 바위)
import io
def patch(path, pairs):
s = io.open(path, encoding="utf-8").read()
for a, b in pairs:
assert s.count(a) == 1, (path, a[:70], s.count(a))
s = s.replace(a, b)
io.open(path, "w", encoding="utf-8", newline="\n").write(s)
print("ok", path)
patch("blender_props/theme_desert.py", [
("make_stone('sandstone', (0.60, 0.44, 0.28),", "make_stone('sandstone', (0.43, 0.31, 0.20),"),
("make_stone('sandstone_block', (0.58, 0.43, 0.27),", "make_stone('sandstone_block', (0.41, 0.30, 0.19),"),
("make_stone('sandstone_dark', (0.40, 0.29, 0.19),", "make_stone('sandstone_dark', (0.28, 0.20, 0.13),"),
("make_cloth('cloth_red', (0.36, 0.11, 0.08), stripe=(0.52, 0.41, 0.24))", "make_cloth('cloth_red', (0.28, 0.075, 0.055), stripe=(0.42, 0.31, 0.14), stripe_n=0.7, stripe_w=0.10, stripe_mix=0.6)"),
("make_cloth('cloth_tan', (0.52, 0.42, 0.28), stripe=(0.30, 0.16, 0.10))", "make_cloth('cloth_tan', (0.40, 0.32, 0.21), stripe=(0.24, 0.10, 0.07), stripe_n=0.9, stripe_w=0.12, stripe_mix=0.6)"),
])
patch("maps_def_desert.py", [
# 바위는 밑이 뾰족해 얕게 묻으면 떠 보인다 → 깊이 묻는다
("'h', 1.0, 1.9, 0.9, 2, False, 'c', sink=0.1) for n in ('01', '01_a'", "'h', 1.0, 1.9, 0.9, 2, False, 'c', sink=0.24) for n in ('01', '01_a'"),
("'h', 2.2, 3.6, 1.8, 1, True, 'c', sink=0.12) for n in ('03', '03_a'", "'h', 2.2, 3.6, 1.8, 1, True, 'c', sink=0.22) for n in ('03', '03_a'"),
# 절벽은 크게 만든 메시라 3~8 m 로 줄이면 면이 넓적한 쐐기로 보인다 → 1열은 더 크게 · 더 멀리, 작은 절벽 자리는 큰 바위로
("'l', 5.0, 8.0, 3.2, 1, True, 'c', sink=0.12) for i in (1, 2, 3,", "'l', 7.5, 10.5, 3.4, 1, True, 'c', sink=0.12) for i in (1, 2, 3,"),
("pool('under', *[item(pf(DR, 'MEP_Rock_' + n), 'h', 0.9, 1.5, 0.8, 2, False, 'c', sink=0.1) for n in ('01_a', '01_c', '02_a', '02_b')], *cliff_small[:4],",
"pool('under', *[item(pf(DR, 'MEP_Rock_' + n), 'h', 0.9, 1.5, 0.8, 2, False, 'c', sink=0.24) for n in ('01_a', '01_c', '02_a', '02_b')],"),
("band('길가 돌 · 선인장', 2.4, 5.0, 1.5, 0.46, 'under', 'pebble',", "band('길가 돌 · 선인장', 2.4, 5.0, 1.5, 0.30, 'under', 'pebble',"),
("band('절벽 1열', 5.0, 13.0, 2.6, 0.55, 'cliff', 'rock', seen=4.0), band('절벽 2열', 13.0, 30.0, 3.6, 0.32, 'cliff', 'cliff', seen=6.0),",
"band('절벽 1열', 7.0, 14.0, 3.2, 0.55, 'cliff', 'rock', seen=4.0), band('절벽 2열', 14.0, 30.0, 4.2, 0.34, 'cliff', 'cliff', seen=6.0),"),
("band('작은 절벽', 3.5, 9.0, 3.0, 0.22, 'cliff_small', 'rock', seen=3.0),", "band('큰 바위', 3.5, 8.0, 3.0, 0.26, 'rock_big', 'rock', seen=3.0),"),
# 분위기: 화면 전체가 갈색 한 가지로 보였다 → 달빛 · 하늘빛을 차갑게 돌려 모래색과 불빛이 갈리게(키아트: 청록 밤 + 따뜻한 불빛)
(" a = atmo(moon=(1.0, 0.84, 0.62), moon_i=2.0, moon_euler=(46, 300, 0), fog=(0.24, 0.17, 0.11), fog0=11, fog1=64, sky=(0.44, 0.38, 0.34), eq=(0.32, 0.25, 0.19), gnd=(0.17, 0.12, 0.08),\n"
" exposure=1.25, saturation=-8, split_sh=(0.24, 0.34, 0.42), split_hi=(0.95, 0.80, 0.56), bloom_t=0.85, bloom_i=1.05, mist=(0.92, 0.76, 0.54), mist_a=0.11, mote_a=(1.0, 0.85, 0.55), mote_b=(1.0, 0.95, 0.8),\n"
" note='황토빛 모래바람 + 호박빛 화로 + 오아시스의 푸른 빛(그늘은 청록으로)')",
" a = atmo(moon=(0.74, 0.84, 1.0), moon_i=2.0, moon_euler=(46, 300, 0), fog=(0.13, 0.16, 0.22), fog0=11, fog1=64, sky=(0.30, 0.38, 0.50), eq=(0.24, 0.24, 0.26), gnd=(0.15, 0.11, 0.08),\n"
" exposure=1.15, saturation=-2, split_sh=(0.20, 0.34, 0.46), split_hi=(0.92, 0.80, 0.62), bloom_t=0.85, bloom_i=1.05, mist=(0.74, 0.72, 0.66), mist_a=0.10, mote_a=(1.0, 0.85, 0.55), mote_b=(0.85, 0.92, 1.0),\n"
" note='푸른 달밤의 사막 + 호박빛 화로 + 오아시스의 푸른 빛 — 달빛은 차갑게, 불빛은 따뜻하게 갈라 모래색이 살아나게')"),
])