From d73c606e469c2ef310c27e62815ed7ba1928b117 Mon Sep 17 00:00:00 2001 From: swrring Date: Fri, 6 Nov 2026 23:20:57 +0900 Subject: [PATCH] =?UTF-8?q?UI=20=EB=A6=AC=EB=89=B4=EC=96=BC=20A-2~A-4=20?= =?UTF-8?q?=ED=99=94=EB=A9=B4=20=EC=A0=81=EC=9A=A9(PD=20#1100)=20=E2=80=94?= =?UTF-8?q?=20=ED=8C=A9=20=EB=B6=80=ED=92=88=20+=20UI=20=ED=85=8C=EB=A7=88?= =?UTF-8?q?(id=20=EC=B9=98=ED=99=98)=20=C2=B7=20=ED=99=94=EB=A9=B4=2010?= =?UTF-8?q?=EC=A2=85=20=C2=B7=20=EC=9D=B8=EB=B0=95=EC=8A=A4=20ui=20kind?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - 테마: SOT Assets/Data/UI/ui_theme.csv(색 57 · 스킨 32 · 아이콘 63 · 제목 폰트) → 메뉴 TKS/Import UI Theme → Resources/UI/UITheme.asset (Runtime/UI/UITheme · UISkin · Editor/UIThemeImporter · ProjectSetup 에서도 임포트) · 화면 코드는 id 로만 묻는다(스프라이트 경로 0) - 신규 제작(B) 치환: Assets/UI/Samguk/**/.png → 임포트 시 같은 id 스킨·아이콘 자동 치환(팩 보존 · 새 id = 아이콘 추가) · Tools/apply_delivery.py ui kind(md5 → Samguk/ · gim_* → Resources/Gimmicks/Art · ui_delivered.csv) - 공통: UiKit(카드 = BorderFrame_Round20 틴트 · 버튼 = Button01_s + 광택 · 원 · 진행 바 = Slider_Basic01 · 초상 틀 · 등급 칸 ItemFrame02 · 별 줄 · 병종 배지) · 재화 바(ResourceBar + cur_* 아이콘) · 하단 탭(선택 판 + PictoIcon) · 제목 띠 · 팝업(Popup Topber + 닫기 X) · 토스트 - 화면: 로비(키아트 04 배경 위쪽 ×1.22 · 출정·편성·연무장 아이콘) · 영웅(등급 칸 + 장비 아이콘 · 체크/알림 점 · 별 아이콘) · 편성 · 거래(배너 · 상자 아이콘) · 보물(상자 아이콘 · 포인트 배지) · 내정(보상 줄 · 도면·골드 아이콘) · 연무장 · 결과(리본 · 별) · 월드맵 스테이지 팝업만 팩(거점 kit 유지) - 전투: HUD 칩 · 턴 띠 · 원형 스킬 버튼 + 쿨 라디얼 · 유닛 체력 바 · 기믹 내구 핍 = 팩 슬라이더(월드 9-slice 사본 · 가운데 2 px) · 조준선 색 유지 - 3:4(1536×2048): 본문 비율 축소(UiFitHeight · 1080×1920 = 그대로) - 검증: 플레이모드 116/116(기존 115 + UIThemeTests 1) · 컴파일 0 · error 0 · 캡처 = DataImporter.CaptureUI(UICaptureDriver · 15장) Co-Authored-By: Claude Opus 5.5 --- Assets/Data/UI.meta | 8 + Assets/Data/UI/ui_theme.csv | 154 +++++ Assets/Data/UI/ui_theme.csv.meta | 7 + Assets/Resources/UI.meta | 8 + Assets/Resources/UI/UITheme.asset | 608 ++++++++++++++++++ Assets/Resources/UI/UITheme.asset.meta | 8 + Assets/Scripts/Editor/DataImporter.cs | 18 + Assets/Scripts/Editor/ProjectSetup.cs | 2 + Assets/Scripts/Editor/UIThemeImporter.cs | 234 +++++++ Assets/Scripts/Editor/UIThemeImporter.cs.meta | 2 + .../OutGame/Domestic/DomesticScreen.cs | 10 +- .../OutGame/Treasure/TreasureScreen.cs | 11 +- .../Scripts/OutGame/UI/BattleResultPanel.cs | 47 +- Assets/Scripts/OutGame/UI/HeroScreens.cs | 70 +- Assets/Scripts/OutGame/UI/LobbyScreen.cs | 46 +- Assets/Scripts/OutGame/UI/OutGameRoot.cs | 125 +++- Assets/Scripts/OutGame/UI/TradeScreen.cs | 9 +- Assets/Scripts/OutGame/UI/UiFitHeight.cs | 45 ++ Assets/Scripts/OutGame/UI/UiFitHeight.cs.meta | 2 + Assets/Scripts/OutGame/UI/UiKit.cs | 229 +++++-- Assets/Scripts/OutGame/UICaptureDriver.cs | 169 +++++ .../Scripts/OutGame/UICaptureDriver.cs.meta | 2 + Assets/Scripts/Runtime/BattleHUD.cs | 87 ++- .../Scripts/Runtime/Gimmicks/GimmickView.cs | 10 +- Assets/Scripts/Runtime/UI.meta | 8 + Assets/Scripts/Runtime/UI/UISkin.cs | 148 +++++ Assets/Scripts/Runtime/UI/UISkin.cs.meta | 2 + Assets/Scripts/Runtime/UI/UITheme.cs | 154 +++++ Assets/Scripts/Runtime/UI/UITheme.cs.meta | 2 + Assets/Scripts/Runtime/UnitView.cs | 37 +- Assets/Scripts/Runtime/WorldMapScreen.cs | 46 +- Assets/Tests/PlayMode/UIThemeTests.cs | 48 ++ Assets/Tests/PlayMode/UIThemeTests.cs.meta | 2 + Assets/UI/Lobby.meta | 8 + Assets/UI/Lobby/keyart_04.png | Bin 0 -> 1154719 bytes Assets/UI/Lobby/keyart_04.png.meta | 168 +++++ Assets/UI/Samguk.meta | 8 + Assets/UI/Samguk/README.md | 5 + Assets/UI/Samguk/README.md.meta | 7 + Tools/apply_delivery.py | 71 +- 40 files changed, 2489 insertions(+), 136 deletions(-) create mode 100644 Assets/Data/UI.meta create mode 100644 Assets/Data/UI/ui_theme.csv create mode 100644 Assets/Data/UI/ui_theme.csv.meta create mode 100644 Assets/Resources/UI.meta create mode 100644 Assets/Resources/UI/UITheme.asset create mode 100644 Assets/Resources/UI/UITheme.asset.meta create mode 100644 Assets/Scripts/Editor/UIThemeImporter.cs create mode 100644 Assets/Scripts/Editor/UIThemeImporter.cs.meta create mode 100644 Assets/Scripts/OutGame/UI/UiFitHeight.cs create mode 100644 Assets/Scripts/OutGame/UI/UiFitHeight.cs.meta create mode 100644 Assets/Scripts/OutGame/UICaptureDriver.cs create mode 100644 Assets/Scripts/OutGame/UICaptureDriver.cs.meta create mode 100644 Assets/Scripts/Runtime/UI.meta create mode 100644 Assets/Scripts/Runtime/UI/UISkin.cs create mode 100644 Assets/Scripts/Runtime/UI/UISkin.cs.meta create mode 100644 Assets/Scripts/Runtime/UI/UITheme.cs create mode 100644 Assets/Scripts/Runtime/UI/UITheme.cs.meta create mode 100644 Assets/Tests/PlayMode/UIThemeTests.cs create mode 100644 Assets/Tests/PlayMode/UIThemeTests.cs.meta create mode 100644 Assets/UI/Lobby.meta create mode 100644 Assets/UI/Lobby/keyart_04.png create mode 100644 Assets/UI/Lobby/keyart_04.png.meta create mode 100644 Assets/UI/Samguk.meta create mode 100644 Assets/UI/Samguk/README.md create mode 100644 Assets/UI/Samguk/README.md.meta diff --git a/Assets/Data/UI.meta b/Assets/Data/UI.meta new file mode 100644 index 00000000..27e10cc0 --- /dev/null +++ b/Assets/Data/UI.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: bf00b201586bf2a48beb4f0b0ffe0d9c +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Data/UI/ui_theme.csv b/Assets/Data/UI/ui_theme.csv new file mode 100644 index 00000000..033b58be --- /dev/null +++ b/Assets/Data/UI/ui_theme.csv @@ -0,0 +1,154 @@ +kind,id,path,overlay,ppu,inset,alpha,color,note +color,bg,,,,,,#EFE5CF,화면 바탕(양피지) +color,paper,,,,,,#FFF9EC,패널·카드 바탕 +color,header,,,,,,#2E3349,제목 띠(팩 진남) +color,header_text,,,,,,#FFFFFF,제목 띠 글자 +color,header_sub,,,,,,#C9C3D6,제목 띠 보조 글자 +color,ink,,,,,,#2A2230,글자(먹) +color,ink_soft,,,,,,#6F6470,보조 글자 +color,dark,,,,,,#3A4060,어두운 버튼(팩 진남) +color,red,,,,,,#D8412F,붉은 옻칠(주 버튼·강조) +color,line,,,,,,#1E2535,외곽선 +color,slot,,,,,,#DCD0B9,빈 칸 +color,coin,,,,,,#F3B72E,금 +color,jade,,,,,,#23B394,보옥(옥) +color,grain,,,,,,#D9963F,군량 +color,ok,,,,,,#47B53F,완료 +color,star,,,,,,#FFC21A,별 +color,disabled,,,,,,#9E98A3,비활성 +color,purple,,,,,,#9A57D8,보라 +color,white,,,,,,#FFFFFF,흰색 +color,bar,,,,,,#1E2535,상단 재화 바·하단 탭 바 +color,pill,,,,,,#353B57,상단 재화 칩 바탕(흰 칩 틴트) +color,bar_text,,,,,,#FFFFFF,바 글자 +color,bar_text_off,,,,,,#8D93A8,바 글자(비활성) +color,tab_off,,,,,,#3A4060,하단 탭 아이콘 바탕(꺼짐) +color,stroke,,,,,,#1E2535,흰 글자 외곽선 +color,dim,,,,,,#000000A0,팝업 뒤 어둡게 +color,lobby_tint,,,,,,#9C95A8,로비 배경 어둡게(곱) +color,bar_track,,,,,,#FFFFFF,진행 바 바탕(스킨 원색 · 곱) +color,grade_white,,,,,,#D9D6CF,등급 흰 +color,grade_green,,,,,,#47B53F,등급 녹 +color,grade_blue,,,,,,#3C7BE0,등급 청 +color,grade_purple,,,,,,#9A57D8,등급 자 +color,grade_orange,,,,,,#F08A24,등급 주 +color,grade_gold,,,,,,#F3C12E,등급 금 +color,type_infantry,,,,,,#C8553A,병종 보병 +color,type_spear,,,,,,#3E9A4A,병종 창병 +color,type_cavalry,,,,,,#3C67C8,병종 기병 +color,type_archer,,,,,,#D99A2B,병종 궁병 +color,type_strategist,,,,,,#9A57D8,병종 책사 +color,faction_shu,,,,,,#D8412F,세력 촉(적) +color,faction_wei,,,,,,#3C7BE0,세력 위(청) +color,faction_wu,,,,,,#2FA84F,세력 오(녹) +color,faction_other,,,,,,#8C8C96,세력 군웅(회) +color,hp_bg,,,,,,#FFFFFF,유닛 체력 바 바탕(스킨 원색) +color,hp_hi,,,,,,#52D148,체력 50 % 초과 +color,hp_mid,,,,,,#FFC52B,체력 25~50 % +color,hp_low,,,,,,#F2453A,체력 25 % 이하 +color,pip_on,,,,,,#FFC21A,기믹 내구 핍(남음) +color,pip_off,,,,,,#2B2F40CC,기믹 내구 핍(깎임) +color,hud_panel,,,,,,#1E2535D9,전투 HUD 판 +color,hud_turn_player,,,,,,#3C7BE0,턴 띠(아군) +color,hud_turn_enemy,,,,,,#D8412F,턴 띠(적군) +color,skill_ready,,,,,,#D8412F,스킬 사용 가능 +color,skill_reserved,,,,,,#F3B72E,스킬 예약 +color,skill_off,,,,,,#5A5E70,스킬 불가 +color,skill_passive,,,,,,#3A4060,패시브만 +color,skill_cool,,,,,,#000000A8,스킬 쿨 라디얼 덮개 +skin,card,Frame/BorderFrame_Round20_White_Bg.png,,1,,,,패널·카드(흰 바탕 + 굵은 외곽선 · 호출 색 틴트) +skin,soft,Frame/BasicFrame_Round20.png,,1,,,,외곽선 없는 둥근 칸(반투명 판) +skin,button,Button/Button01_s_White_Bg.png,Button/Button01_s_White_Light1.png,1,5;5;5;18,0.35,,버튼(흰 바탕 틴트 + 윗면 광택) +skin,dot,Frame/BorderFrame_Circle60.png,,1,,,,원(외곽선) +skin,bar_bg,Slider/Slider_Basic01_Bg_Single.png,,1,,,,진행 바 바탕 +skin,bar_fill,Slider/Slider_Basic01_FillMask.png,,1,,,,진행 바 채움(틴트) +skin,pill,UI_Etc/ResourceBar_Single_Bg.png,,1,,,,상단 재화 칩 +skin,plus,UI_Etc/ResourceBar_Single_Btn_Yellow1.png,UI_Etc/ResourceBar_Single_Btn_Yellow2.png,1,14;14;14;16,1,,재화 + 버튼 +skin,tabbar,Button/Menu_BottomBtn_Bg.png,,1,,,,하단 탭 바 +skin,tab_focus,Frame/BorderFrame_Round20_White_Bg.png,Frame/BorderFrame_Round20_White_Light.png,1,6;4;6;30,0.45,,하단 탭 선택(틴트) +skin,popup,Popup/Popup02~09_Topber_White_Bg.png,,1,,,,팝업 틀 +skin,popup_head,Popup/Popup02~09_Topber_White_BgTop.png,Popup/Popup02~09_Topber_White_BgTopLight.png,1,0;0;0;60,0.25,,팝업 제목 띠(틴트) +skin,close,Button/Button_Round06_Red.png,IconMisc/Icon_Close01.png,1,22;22;22;26,1,,팝업 닫기 X +skin,ribbon,Label/Title_Ribbon01_Red.png,,1,,,,결과 제목 리본 +skin,ribbon_gray,Label/Title_Ribbon01_Gray.png,,1,,,,결과 제목 리본(패배) +skin,toast,Frame/BorderFrame_Round20_White_Bg.png,,1,,,,알림(틴트) +skin,portrait_mask,Frame/BasicFrame_Round20.png,,1,,,,초상 마스크 +skin,circle_frame,Frame/BorderFrame_Circle78.png,,1,,,,원형 자리(편성) +skin,skill_btn,Button/Button_Circle122.png,,1,,,,전투 스킬 버튼(원형) +skin,skill_cool,Frame/BasicFrame_Circle160.png,,1,,,,스킬 쿨 라디얼 +skin,hp_bg,Slider/Slider_Basic02_Bg.png,,1,,,,유닛 체력 바 바탕(월드) +skin,hp_fill,Slider/Slider_Basic01_FillMask.png,,1,,,,유닛 체력 바 채움(월드) +skin,pip,Frame/BorderFrame_Round20_White_Bg.png,,1,,,,기믹 내구 핍(월드) +skin,hud_pill,UI_Etc/ResourceBar_Single_Bg.png,,1,,,,전투 HUD 칩 +skin,banner,Frame/BannerFrame04_Single.png,,1,,,,뽑기 배너 틀 +skin,flag,Frame/BorderFrame_Flag_White_Bg.png,,1,,,,세력 깃발(틴트) +skin,frame_white,Frame/ItemFrame02_Single_OffWhite.png,,1,,,,등급 칸 흰(B frame_* 오면 치환) +skin,frame_green,Frame/ItemFrame02_Single_Green.png,,1,,,,등급 칸 녹 +skin,frame_blue,Frame/ItemFrame02_Single_Blue.png,,1,,,,등급 칸 청 +skin,frame_purple,Frame/ItemFrame02_Single_Purple.png,,1,,,,등급 칸 자 +skin,frame_orange,Frame/ItemFrame02_Single_Red.png,,1,,,,등급 칸 주(팩에 주황 없음 → 적색) +skin,frame_gold,Frame/ItemFrame02_Single_Yellow.png,,1,,,,등급 칸 금 +icon,cur_gold,Icon_ItemIcons/128/ItemIcon_Money_Coin.Png,,,,,,골드(임시 · B cur_gold) +icon,cur_gem,Icon_ItemIcons/128/ItemIcon_Gem_Circle.Png,,,,,,보옥(임시) +icon,cur_stamina,Icon_ItemIcons/128/ItemIcon_Bag_Brown.Png,,,,,,군량(임시) +icon,cur_shard,Icon_ItemIcons/128/ItemIcon_Star_Purple.Png,,,,,,영웅 조각(임시) +icon,cur_iron,Icon_ItemIcons/128/ItemIcon_Gear.Png,,,,,,운철(임시) +icon,cur_blueprint,Icon_ItemIcons/128/ItemIcon_MemoPad.Png,,,,,,도면(임시) +icon,cur_ticket,Icon_ItemIcons/128/ItemIcon_Ticket_Gold.Png,,,,,,입장권(임시) +icon,cur_skillbook,Icon_ItemIcons/128/ItemIcon_Book_1_Wine.Png,,,,,,스킬서(임시) +icon,cur_exp,Icon_ItemIcons/128/ItemIcon_Star_Blue.Png,,,,,,경험(임시) +icon,cur_gear,Icon_ItemIcons/128/ItemIcon_Gear_Sword.Png,,,,,,장비(임시) +icon,tab_hero,Icon_PictoIcons/128/PictoIcon_Helmet_1.Png,,,,,,하단 탭 영웅(임시) +icon,tab_treasure,Icon_PictoIcons/128/PictoIcon_Chest.Png,,,,,,하단 탭 보물(임시) +icon,tab_domestic,Icon_PictoIcons/128/PictoIcon_Castle.Png,,,,,,하단 탭 내정(임시) +icon,tab_alliance,Icon_PictoIcons/128/PictoIcon_Lock_1.Png,,,,,,하단 탭 동맹(잠금 · 임시) +icon,tab_trade,Icon_PictoIcons/128/PictoIcon_Scale.Png,,,,,,하단 탭 거래(임시) +icon,btn_sortie,Icon_PictoIcons/128/PictoIcon_Battle.Png,,,,,,로비 출정(임시) +icon,btn_formation,Icon_PictoIcons/128/PictoIcon_Flag.Png,,,,,,로비 편성(임시) +icon,btn_arena,Icon_PictoIcons/128/PictoIcon_Target.Png,,,,,,로비 연무장(임시) +icon,cls_infantry,Icon_PictoIcons/128/PictoIcon_Sword_1.Png,,,,,,병종 보병(임시) +icon,cls_spear,Icon_PictoIcons/128/PictoIcon_Pick.Png,,,,,,병종 창병(임시) +icon,cls_cavalry,Icon_PictoIcons/128/PictoIcon_Paw.Png,,,,,,병종 기병(임시) +icon,cls_archer,Icon_PictoIcons/128/PictoIcon_Bow.Png,,,,,,병종 궁병(임시) +icon,cls_strategist,Icon_PictoIcons/128/PictoIcon_Pen_Feather.Png,,,,,,병종 책사(임시) +icon,chest_bronze,Icon_ItemIcons/128/ItemIcon_Chest_Wood.Png,,,,,,청동 상자(임시) +icon,chest_silver,Icon_ItemIcons/128/ItemIcon_Chest_Skull.png,,,,,,은 상자(임시) +icon,chest_gold,Icon_ItemIcons/128/ItemIcon_Chest_Gold.Png,,,,,,금 상자(임시) +icon,chest_general,Icon_ItemIcons/128/ItemIcon_Chest_Premium.Png,,,,,,명장 상자(임시) +icon,chest_gem,Icon_ItemIcons/128/ItemIcon_Chest_Gem.Png,,,,,,보옥 상자(임시) +icon,chest_point,Icon_ItemIcons/128/ItemIcon_Badge_Gold.png,,,,,,상자 포인트(임시) +icon,gear_sword,Icon_ItemIcons/128/ItemIcon_Gear_Sword.Png,,,,,,청동 검(임시) +icon,gear_spear,Icon_ItemIcons/128/ItemIcon_Battle.Png,,,,,,철 창(임시) +icon,gear_bow,Icon_PictoIcons/128/PictoIcon_Bow.Png,,,,,#8A5A2B,각궁(임시 · 실루엣 틴트) +icon,gear_armor,Icon_ItemIcons/128/ItemIcon_Gear_Armor_Top.Png,,,,,,가죽 갑주(임시) +icon,gear_helmet,IconMisc/Icon_Helmet.png,,,,,,철 투구(임시) +icon,gear_horse,Icon_ItemIcons/128/ItemIcon_Gear_Boots.Png,,,,,,마구(임시) +icon,gear_banner,Icon_PictoIcons/128/PictoIcon_Flag.Png,,,,,#D8412F,군령기(임시 · 실루엣 틴트) +icon,gear_book,Icon_ItemIcons/128/ItemIcon_Book_1_Purple.Png,,,,,,병서(임시) +icon,gear_potion,Icon_ItemIcons/128/ItemIcon_Pot.Png,,,,,,약낭(임시) +icon,gear_shield,IconMisc/Icon_Shield.png,,,,,,방패(임시) +icon,gear_charm,Icon_ItemIcons/128/ItemIcon_Clover_Gold.Png,,,,,,부적(임시) +icon,gear_flag,Icon_ItemIcons/128/ItemIcon_Medal_Gold_1.png,,,,,,전고(임시) +icon,flag_shu,Frame/BorderFrame_Flag_Red.png,,,,,,세력 촉(임시) +icon,flag_wei,Frame/BorderFrame_Flag_Blue.png,,,,,,세력 위(임시) +icon,flag_wu,Frame/BorderFrame_Flag_Green.png,,,,,,세력 오(임시) +icon,flag_other,Frame/BorderFrame_Flag_White_Bg.png,,,,,#8C8C96,세력 군웅(임시) +icon,rank_1,Icon_GradeBadge/128/Icon_GradeBadge_Beginner.Png,,,,,,훈련 랭크 1(임시) +icon,rank_2,Icon_GradeBadge/128/Icon_GradeBadge_Iron.Png,,,,,,훈련 랭크 2(임시) +icon,rank_3,Icon_GradeBadge/128/Icon_GradeBadge_Bronze.Png,,,,,,훈련 랭크 3(임시) +icon,rank_4,Icon_GradeBadge/128/Icon_GradeBadge_Silver.Png,,,,,,훈련 랭크 4(임시) +icon,rank_5,Icon_GradeBadge/128/Icon_GradeBadge_Gold.Png,,,,,,훈련 랭크 5(임시) +icon,rank_6,Icon_GradeBadge/128/Icon_GradeBadge_Platinum.Png,,,,,,훈련 랭크 6(임시) +icon,rank_7,Icon_GradeBadge/128/Icon_GradeBadge_Diamond.Png,,,,,,훈련 랭크 7(임시) +icon,star_on,IconMisc/GradeIcon_Star_s_Yellow.png,,,,,,별(켜짐) +icon,star_off,IconMisc/Icon_Star_Off.png,,,,,,별(꺼짐) +icon,lock,IconMisc/Icon_Lock03.png,,,,,,잠금 +icon,check,IconMisc/Icon_Check03_s.png,,,,,,체크 +icon,arrow_prev,IconMisc/Icon_Arrow_Prev1.png,,,,,,이전 +icon,arrow_next,IconMisc/Icon_Arrow_Next1.png,,,,,,다음 +icon,arrow_back,IconMisc/Icon_Arrow_Back.png,,,,,,뒤로 +icon,new_dot,UI_Etc/Alert_Dot_Bg.png,,,,,#F2453A,새 알림 점 +icon,tut_hand,Icon_TutorialHand/128/tutorial_hand_1.png,,,,,,튜토리얼 손가락 +icon,shop_pack,Icon_ShopItem/ShopItem_l_GemPack_3.png,,,,,,상점 패키지(준비 중 칸) +icon,bg_lobby,Assets/UI/Lobby/keyart_04.png,,,,,,로비 배경(키아트 04 · B bg_lobby 오면 치환) +font,title,Assets/UI/GUIPro/ResourcesData/Fonts/Sen-ExtraBold.ttf,,,,,,제목·숫자(라틴 Sen · 한글 = 폴백 Malgun Gothic · PD 결정 전) diff --git a/Assets/Data/UI/ui_theme.csv.meta b/Assets/Data/UI/ui_theme.csv.meta new file mode 100644 index 00000000..28919c01 --- /dev/null +++ b/Assets/Data/UI/ui_theme.csv.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: b79aa3573c2bd824eb781e9385791aad +TextScriptImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Resources/UI.meta b/Assets/Resources/UI.meta new file mode 100644 index 00000000..3c14c99e --- /dev/null +++ b/Assets/Resources/UI.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: b327fe546ab27674db7aebf2c7c51f6c +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Resources/UI/UITheme.asset b/Assets/Resources/UI/UITheme.asset new file mode 100644 index 00000000..598a2583 --- /dev/null +++ b/Assets/Resources/UI/UITheme.asset @@ -0,0 +1,608 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!114 &11400000 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 0} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 63b0a8e358e193740883a84a0bfe1325, type: 3} + m_Name: + m_EditorClassIdentifier: TKS.Runtime::TKS.UITheme + colors: + - id: bg + color: {r: 0.9372549, g: 0.8980392, b: 0.8117647, a: 1} + - id: paper + color: {r: 1, g: 0.9764706, b: 0.9254902, a: 1} + - id: header + color: {r: 0.18039216, g: 0.2, b: 0.28627452, a: 1} + - id: header_text + color: {r: 1, g: 1, b: 1, a: 1} + - id: header_sub + color: {r: 0.7882353, g: 0.7647059, b: 0.8392157, a: 1} + - id: ink + color: {r: 0.16470589, g: 0.13333334, b: 0.1882353, a: 1} + - id: ink_soft + color: {r: 0.43529412, g: 0.39215687, b: 0.4392157, a: 1} + - id: dark + color: {r: 0.22745098, g: 0.2509804, b: 0.3764706, a: 1} + - id: red + color: {r: 0.84705883, g: 0.25490198, b: 0.18431373, a: 1} + - id: line + color: {r: 0.11764706, g: 0.14509805, b: 0.20784314, a: 1} + - id: slot + color: {r: 0.8627451, g: 0.8156863, b: 0.7254902, a: 1} + - id: coin + color: {r: 0.9529412, g: 0.7176471, b: 0.18039216, a: 1} + - id: jade + color: {r: 0.13725491, g: 0.7019608, b: 0.5803922, a: 1} + - id: grain + color: {r: 0.8509804, g: 0.5882353, b: 0.24705882, a: 1} + - id: ok + color: {r: 0.2784314, g: 0.70980394, b: 0.24705882, a: 1} + - id: star + color: {r: 1, g: 0.7607843, b: 0.101960786, a: 1} + - id: disabled + color: {r: 0.61960787, g: 0.59607846, b: 0.6392157, a: 1} + - id: purple + color: {r: 0.6039216, g: 0.34117648, b: 0.84705883, a: 1} + - id: white + color: {r: 1, g: 1, b: 1, a: 1} + - id: bar + color: {r: 0.11764706, g: 0.14509805, b: 0.20784314, a: 1} + - id: pill + color: {r: 0.20784314, g: 0.23137255, b: 0.34117648, a: 1} + - id: bar_text + color: {r: 1, g: 1, b: 1, a: 1} + - id: bar_text_off + color: {r: 0.5529412, g: 0.5764706, b: 0.65882355, a: 1} + - id: tab_off + color: {r: 0.22745098, g: 0.2509804, b: 0.3764706, a: 1} + - id: stroke + color: {r: 0.11764706, g: 0.14509805, b: 0.20784314, a: 1} + - id: dim + color: {r: 0, g: 0, b: 0, a: 0.627451} + - id: lobby_tint + color: {r: 0.6117647, g: 0.58431375, b: 0.65882355, a: 1} + - id: bar_track + color: {r: 1, g: 1, b: 1, a: 1} + - id: grade_white + color: {r: 0.8509804, g: 0.8392157, b: 0.8117647, a: 1} + - id: grade_green + color: {r: 0.2784314, g: 0.70980394, b: 0.24705882, a: 1} + - id: grade_blue + color: {r: 0.23529412, g: 0.48235294, b: 0.8784314, a: 1} + - id: grade_purple + color: {r: 0.6039216, g: 0.34117648, b: 0.84705883, a: 1} + - id: grade_orange + color: {r: 0.9411765, g: 0.5411765, b: 0.14117648, a: 1} + - id: grade_gold + color: {r: 0.9529412, g: 0.75686276, b: 0.18039216, a: 1} + - id: type_infantry + color: {r: 0.78431374, g: 0.33333334, b: 0.22745098, a: 1} + - id: type_spear + color: {r: 0.24313726, g: 0.6039216, b: 0.2901961, a: 1} + - id: type_cavalry + color: {r: 0.23529412, g: 0.40392157, b: 0.78431374, a: 1} + - id: type_archer + color: {r: 0.8509804, g: 0.6039216, b: 0.16862746, a: 1} + - id: type_strategist + color: {r: 0.6039216, g: 0.34117648, b: 0.84705883, a: 1} + - id: faction_shu + color: {r: 0.84705883, g: 0.25490198, b: 0.18431373, a: 1} + - id: faction_wei + color: {r: 0.23529412, g: 0.48235294, b: 0.8784314, a: 1} + - id: faction_wu + color: {r: 0.18431373, g: 0.65882355, b: 0.30980393, a: 1} + - id: faction_other + color: {r: 0.54901963, g: 0.54901963, b: 0.5882353, a: 1} + - id: hp_bg + color: {r: 1, g: 1, b: 1, a: 1} + - id: hp_hi + color: {r: 0.32156864, g: 0.81960785, b: 0.28235295, a: 1} + - id: hp_mid + color: {r: 1, g: 0.77254903, b: 0.16862746, a: 1} + - id: hp_low + color: {r: 0.9490196, g: 0.27058825, b: 0.22745098, a: 1} + - id: pip_on + color: {r: 1, g: 0.7607843, b: 0.101960786, a: 1} + - id: pip_off + color: {r: 0.16862746, g: 0.18431373, b: 0.2509804, a: 0.8} + - id: hud_panel + color: {r: 0.11764706, g: 0.14509805, b: 0.20784314, a: 0.8509804} + - id: hud_turn_player + color: {r: 0.23529412, g: 0.48235294, b: 0.8784314, a: 1} + - id: hud_turn_enemy + color: {r: 0.84705883, g: 0.25490198, b: 0.18431373, a: 1} + - id: skill_ready + color: {r: 0.84705883, g: 0.25490198, b: 0.18431373, a: 1} + - id: skill_reserved + color: {r: 0.9529412, g: 0.7176471, b: 0.18039216, a: 1} + - id: skill_off + color: {r: 0.3529412, g: 0.36862746, b: 0.4392157, a: 1} + - id: skill_passive + color: {r: 0.22745098, g: 0.2509804, b: 0.3764706, a: 1} + - id: skill_cool + color: {r: 0, g: 0, b: 0, a: 0.65882355} + skins: + - id: card + pack: {fileID: 21300000, guid: 3070a6f23e6ca4273897acf1b7e8c5ce, type: 3} + samguk: {fileID: 0} + overlay: {fileID: 0} + ppu: 1 + inset: {x: 0, y: 0, z: 0, w: 0} + overlayAlpha: 1 + - id: soft + pack: {fileID: 21300000, guid: 6c9211bc1d90b4e35a3a080121e93d05, type: 3} + samguk: {fileID: 0} + overlay: {fileID: 0} + ppu: 1 + inset: {x: 0, y: 0, z: 0, w: 0} + overlayAlpha: 1 + - id: button + pack: {fileID: 21300000, guid: 615459ca724384003a91b93533033ab1, type: 3} + samguk: {fileID: 0} + overlay: {fileID: 21300000, guid: 1047c0bcbda25440faf8332b872b3529, type: 3} + ppu: 1 + inset: {x: 5, y: 5, z: 5, w: 18} + overlayAlpha: 0.35 + - id: dot + pack: {fileID: 21300000, guid: b31cc26b044a54db88302afadc39ed11, type: 3} + samguk: {fileID: 0} + overlay: {fileID: 0} + ppu: 1 + inset: {x: 0, y: 0, z: 0, w: 0} + overlayAlpha: 1 + - id: bar_bg + pack: {fileID: 21300000, guid: 6332433fb34294d58bfc835736ee8ac3, type: 3} + samguk: {fileID: 0} + overlay: {fileID: 0} + ppu: 1 + inset: {x: 0, y: 0, z: 0, w: 0} + overlayAlpha: 1 + - id: bar_fill + pack: {fileID: 21300000, guid: 3fceb536486e040c99fac1bb7f353cf6, type: 3} + samguk: {fileID: 0} + overlay: {fileID: 0} + ppu: 1 + inset: {x: 0, y: 0, z: 0, w: 0} + overlayAlpha: 1 + - id: pill + pack: {fileID: 21300000, guid: 83aedc4dd182a4b859ab60b44189cda6, type: 3} + samguk: {fileID: 0} + overlay: {fileID: 0} + ppu: 1 + inset: {x: 0, y: 0, z: 0, w: 0} + overlayAlpha: 1 + - id: plus + pack: {fileID: 21300000, guid: 77db17572c3694c38812470f80f4009b, type: 3} + samguk: {fileID: 0} + overlay: {fileID: 21300000, guid: a707b1e1252f042c58519d2882ee2651, type: 3} + ppu: 1 + inset: {x: 14, y: 14, z: 14, w: 16} + overlayAlpha: 1 + - id: tabbar + pack: {fileID: 21300000, guid: 03cc62a06f5fc44639b0a7ec241ee65f, type: 3} + samguk: {fileID: 0} + overlay: {fileID: 0} + ppu: 1 + inset: {x: 0, y: 0, z: 0, w: 0} + overlayAlpha: 1 + - id: tab_focus + pack: {fileID: 21300000, guid: 3070a6f23e6ca4273897acf1b7e8c5ce, type: 3} + samguk: {fileID: 0} + overlay: {fileID: 21300000, guid: d332162b7f97a44c8968e3570e42e325, type: 3} + ppu: 1 + inset: {x: 6, y: 4, z: 6, w: 30} + overlayAlpha: 0.45 + - id: popup + pack: {fileID: 21300000, guid: 2bd06dd44f28c41ebac87b908313e284, type: 3} + samguk: {fileID: 0} + overlay: {fileID: 0} + ppu: 1 + inset: {x: 0, y: 0, z: 0, w: 0} + overlayAlpha: 1 + - id: popup_head + pack: {fileID: 21300000, guid: 620879c9ab62c447b82f0c54e1e88fee, type: 3} + samguk: {fileID: 0} + overlay: {fileID: 21300000, guid: ab01a2531c35a4aafb31413b44dd1bcb, type: 3} + ppu: 1 + inset: {x: 0, y: 0, z: 0, w: 60} + overlayAlpha: 0.25 + - id: close + pack: {fileID: 21300000, guid: ac729c6a63c5c46578bef27ddfc3c0fe, type: 3} + samguk: {fileID: 0} + overlay: {fileID: 21300000, guid: c7c98a2b50d944d2d933ad3c1f60ad39, type: 3} + ppu: 1 + inset: {x: 22, y: 22, z: 22, w: 26} + overlayAlpha: 1 + - id: ribbon + pack: {fileID: 21300000, guid: 2495840c8944f4f05b1d8aa2a409ad7c, type: 3} + samguk: {fileID: 0} + overlay: {fileID: 0} + ppu: 1 + inset: {x: 0, y: 0, z: 0, w: 0} + overlayAlpha: 1 + - id: ribbon_gray + pack: {fileID: 21300000, guid: 46d72fa068f1c473cacf5009c97a9b9c, type: 3} + samguk: {fileID: 0} + overlay: {fileID: 0} + ppu: 1 + inset: {x: 0, y: 0, z: 0, w: 0} + overlayAlpha: 1 + - id: toast + pack: {fileID: 21300000, guid: 3070a6f23e6ca4273897acf1b7e8c5ce, type: 3} + samguk: {fileID: 0} + overlay: {fileID: 0} + ppu: 1 + inset: {x: 0, y: 0, z: 0, w: 0} + overlayAlpha: 1 + - id: portrait_mask + pack: {fileID: 21300000, guid: 6c9211bc1d90b4e35a3a080121e93d05, type: 3} + samguk: {fileID: 0} + overlay: {fileID: 0} + ppu: 1 + inset: {x: 0, y: 0, z: 0, w: 0} + overlayAlpha: 1 + - id: circle_frame + pack: {fileID: 21300000, guid: 555b142732e774962897f672b89e14a9, type: 3} + samguk: {fileID: 0} + overlay: {fileID: 0} + ppu: 1 + inset: {x: 0, y: 0, z: 0, w: 0} + overlayAlpha: 1 + - id: skill_btn + pack: {fileID: 21300000, guid: c8638447d0c4a40fd9a7e32c25783d96, type: 3} + samguk: {fileID: 0} + overlay: {fileID: 0} + ppu: 1 + inset: {x: 0, y: 0, z: 0, w: 0} + overlayAlpha: 1 + - id: skill_cool + pack: {fileID: 21300000, guid: d8a3e7288e03247ec8f56796382ec1a1, type: 3} + samguk: {fileID: 0} + overlay: {fileID: 0} + ppu: 1 + inset: {x: 0, y: 0, z: 0, w: 0} + overlayAlpha: 1 + - id: hp_bg + pack: {fileID: 21300000, guid: 1dfa4588cbf5d4c8eb9ecaf11c55c88b, type: 3} + samguk: {fileID: 0} + overlay: {fileID: 0} + ppu: 1 + inset: {x: 0, y: 0, z: 0, w: 0} + overlayAlpha: 1 + - id: hp_fill + pack: {fileID: 21300000, guid: 3fceb536486e040c99fac1bb7f353cf6, type: 3} + samguk: {fileID: 0} + overlay: {fileID: 0} + ppu: 1 + inset: {x: 0, y: 0, z: 0, w: 0} + overlayAlpha: 1 + - id: pip + pack: {fileID: 21300000, guid: 3070a6f23e6ca4273897acf1b7e8c5ce, type: 3} + samguk: {fileID: 0} + overlay: {fileID: 0} + ppu: 1 + inset: {x: 0, y: 0, z: 0, w: 0} + overlayAlpha: 1 + - id: hud_pill + pack: {fileID: 21300000, guid: 83aedc4dd182a4b859ab60b44189cda6, type: 3} + samguk: {fileID: 0} + overlay: {fileID: 0} + ppu: 1 + inset: {x: 0, y: 0, z: 0, w: 0} + overlayAlpha: 1 + - id: banner + pack: {fileID: 21300000, guid: 0386c61d06bee46feb8e6bca9882cb40, type: 3} + samguk: {fileID: 0} + overlay: {fileID: 0} + ppu: 1 + inset: {x: 0, y: 0, z: 0, w: 0} + overlayAlpha: 1 + - id: flag + pack: {fileID: 21300000, guid: 6f23dee49868b4ee4bb927e2eebe0f5a, type: 3} + samguk: {fileID: 0} + overlay: {fileID: 0} + ppu: 1 + inset: {x: 0, y: 0, z: 0, w: 0} + overlayAlpha: 1 + - id: frame_white + pack: {fileID: 21300000, guid: f0bdcf4700e3143dd941fff695e8c391, type: 3} + samguk: {fileID: 0} + overlay: {fileID: 0} + ppu: 1 + inset: {x: 0, y: 0, z: 0, w: 0} + overlayAlpha: 1 + - id: frame_green + pack: {fileID: 21300000, guid: 9f5976efc00a04bbf9d3a01ac0219c63, type: 3} + samguk: {fileID: 0} + overlay: {fileID: 0} + ppu: 1 + inset: {x: 0, y: 0, z: 0, w: 0} + overlayAlpha: 1 + - id: frame_blue + pack: {fileID: 21300000, guid: 63128e5af0cdc46bfbd4a90aac012629, type: 3} + samguk: {fileID: 0} + overlay: {fileID: 0} + ppu: 1 + inset: {x: 0, y: 0, z: 0, w: 0} + overlayAlpha: 1 + - id: frame_purple + pack: {fileID: 21300000, guid: 7878a4afed4e6465c9785efcd828aaec, type: 3} + samguk: {fileID: 0} + overlay: {fileID: 0} + ppu: 1 + inset: {x: 0, y: 0, z: 0, w: 0} + overlayAlpha: 1 + - id: frame_orange + pack: {fileID: 21300000, guid: e628dc11848744b1c8b2cf768e50aaeb, type: 3} + samguk: {fileID: 0} + overlay: {fileID: 0} + ppu: 1 + inset: {x: 0, y: 0, z: 0, w: 0} + overlayAlpha: 1 + - id: frame_gold + pack: {fileID: 21300000, guid: bf3e36f58b7084484bf9b2cf2fb6f142, type: 3} + samguk: {fileID: 0} + overlay: {fileID: 0} + ppu: 1 + inset: {x: 0, y: 0, z: 0, w: 0} + overlayAlpha: 1 + icons: + - id: cur_gold + pack: {fileID: 21300000, guid: 6d5687fb0dd3a428d9cd26a6f36c6d78, type: 3} + samguk: {fileID: 0} + tint: {r: 1, g: 1, b: 1, a: 1} + - id: cur_gem + pack: {fileID: 21300000, guid: 42854c0d5a9654da395ed40f0e7443ed, type: 3} + samguk: {fileID: 0} + tint: {r: 1, g: 1, b: 1, a: 1} + - id: cur_stamina + pack: {fileID: 21300000, guid: a6832029756c14e05a79241b3ab8bfd5, type: 3} + samguk: {fileID: 0} + tint: {r: 1, g: 1, b: 1, a: 1} + - id: cur_shard + pack: {fileID: 21300000, guid: a480ffcca13b444cc828ffb178e72a88, type: 3} + samguk: {fileID: 0} + tint: {r: 1, g: 1, b: 1, a: 1} + - id: cur_iron + pack: {fileID: 21300000, guid: d3aad013ac9a74286a3cf57df76f510f, type: 3} + samguk: {fileID: 0} + tint: {r: 1, g: 1, b: 1, a: 1} + - id: cur_blueprint + pack: {fileID: 21300000, guid: 3cadefdd2c8ef4523bd35390bab0359e, type: 3} + samguk: {fileID: 0} + tint: {r: 1, g: 1, b: 1, a: 1} + - id: cur_ticket + pack: {fileID: 21300000, guid: 1ca4b50341717411f9ad901950edfc2b, type: 3} + samguk: {fileID: 0} + tint: {r: 1, g: 1, b: 1, a: 1} + - id: cur_skillbook + pack: {fileID: 21300000, guid: c16591869b2474a649dac6761e3e4b7e, type: 3} + samguk: {fileID: 0} + tint: {r: 1, g: 1, b: 1, a: 1} + - id: cur_exp + pack: {fileID: 21300000, guid: 99225861569984f349a535e76bfe9902, type: 3} + samguk: {fileID: 0} + tint: {r: 1, g: 1, b: 1, a: 1} + - id: cur_gear + pack: {fileID: 21300000, guid: 41bc376691e7a4aef8398c3f84ee249f, type: 3} + samguk: {fileID: 0} + tint: {r: 1, g: 1, b: 1, a: 1} + - id: tab_hero + pack: {fileID: 21300000, guid: 6fcf7bcb2b29e4b589e82ab74f31c79e, type: 3} + samguk: {fileID: 0} + tint: {r: 1, g: 1, b: 1, a: 1} + - id: tab_treasure + pack: {fileID: 21300000, guid: 3654b5c84fc0440f786a4918b576d3bb, type: 3} + samguk: {fileID: 0} + tint: {r: 1, g: 1, b: 1, a: 1} + - id: tab_domestic + pack: {fileID: 21300000, guid: ad90f1e81df3442d3b8fc40036d24cd3, type: 3} + samguk: {fileID: 0} + tint: {r: 1, g: 1, b: 1, a: 1} + - id: tab_alliance + pack: {fileID: 21300000, guid: 1eb0217bf1f784956bbb96cf1663c557, type: 3} + samguk: {fileID: 0} + tint: {r: 1, g: 1, b: 1, a: 1} + - id: tab_trade + pack: {fileID: 21300000, guid: 6add04477e44d48508df9a7dabad0134, type: 3} + samguk: {fileID: 0} + tint: {r: 1, g: 1, b: 1, a: 1} + - id: btn_sortie + pack: {fileID: 21300000, guid: 7f272d61d71ea41479651113f8ec2456, type: 3} + samguk: {fileID: 0} + tint: {r: 1, g: 1, b: 1, a: 1} + - id: btn_formation + pack: {fileID: 21300000, guid: 816d14bb0d767435585a0bb55886aaef, type: 3} + samguk: {fileID: 0} + tint: {r: 1, g: 1, b: 1, a: 1} + - id: btn_arena + pack: {fileID: 21300000, guid: d3112ce909bbc4504bdadf79eb35726d, type: 3} + samguk: {fileID: 0} + tint: {r: 1, g: 1, b: 1, a: 1} + - id: cls_infantry + pack: {fileID: 21300000, guid: 3d059bda0f1cb4181a080c8258995348, type: 3} + samguk: {fileID: 0} + tint: {r: 1, g: 1, b: 1, a: 1} + - id: cls_spear + pack: {fileID: 21300000, guid: 16edef63d3f7646d9bcf5f86b0e476ec, type: 3} + samguk: {fileID: 0} + tint: {r: 1, g: 1, b: 1, a: 1} + - id: cls_cavalry + pack: {fileID: 21300000, guid: 6200d1a117bb34c21ae7b0265c0027c3, type: 3} + samguk: {fileID: 0} + tint: {r: 1, g: 1, b: 1, a: 1} + - id: cls_archer + pack: {fileID: 21300000, guid: 21efa6791000e47f2b2b3d493c5d34f0, type: 3} + samguk: {fileID: 0} + tint: {r: 1, g: 1, b: 1, a: 1} + - id: cls_strategist + pack: {fileID: 21300000, guid: 244985ea9313545a38c1aec6679972a9, type: 3} + samguk: {fileID: 0} + tint: {r: 1, g: 1, b: 1, a: 1} + - id: chest_bronze + pack: {fileID: 21300000, guid: fd7a2020060844292b286576606000ab, type: 3} + samguk: {fileID: 0} + tint: {r: 1, g: 1, b: 1, a: 1} + - id: chest_silver + pack: {fileID: 21300000, guid: 52bd6c820cae24fbbbb577594c4cb085, type: 3} + samguk: {fileID: 0} + tint: {r: 1, g: 1, b: 1, a: 1} + - id: chest_gold + pack: {fileID: 21300000, guid: 145874fd002594d928ac4f1cc9046b3d, type: 3} + samguk: {fileID: 0} + tint: {r: 1, g: 1, b: 1, a: 1} + - id: chest_general + pack: {fileID: 21300000, guid: 9de9bb779c7694b08bf5aabc148b1dd3, type: 3} + samguk: {fileID: 0} + tint: {r: 1, g: 1, b: 1, a: 1} + - id: chest_gem + pack: {fileID: 21300000, guid: 05b4c15e805fa4156812361f1797f526, type: 3} + samguk: {fileID: 0} + tint: {r: 1, g: 1, b: 1, a: 1} + - id: chest_point + pack: {fileID: 21300000, guid: b23fb0df2c4474124bcec7b152ff27d9, type: 3} + samguk: {fileID: 0} + tint: {r: 1, g: 1, b: 1, a: 1} + - id: gear_sword + pack: {fileID: 21300000, guid: 41bc376691e7a4aef8398c3f84ee249f, type: 3} + samguk: {fileID: 0} + tint: {r: 1, g: 1, b: 1, a: 1} + - id: gear_spear + pack: {fileID: 21300000, guid: d031f4b21493c4841914d4257119a4e3, type: 3} + samguk: {fileID: 0} + tint: {r: 1, g: 1, b: 1, a: 1} + - id: gear_bow + pack: {fileID: 21300000, guid: 21efa6791000e47f2b2b3d493c5d34f0, type: 3} + samguk: {fileID: 0} + tint: {r: 0.5411765, g: 0.3529412, b: 0.16862746, a: 1} + - id: gear_armor + pack: {fileID: 21300000, guid: 3a3a5d970e2d94998818421e4e0e384b, type: 3} + samguk: {fileID: 0} + tint: {r: 1, g: 1, b: 1, a: 1} + - id: gear_helmet + pack: {fileID: 21300000, guid: a52e1372e66954bcf8dfac5f52044251, type: 3} + samguk: {fileID: 0} + tint: {r: 1, g: 1, b: 1, a: 1} + - id: gear_horse + pack: {fileID: 21300000, guid: e07c16cced13542f59c7400aff52d8a7, type: 3} + samguk: {fileID: 0} + tint: {r: 1, g: 1, b: 1, a: 1} + - id: gear_banner + pack: {fileID: 21300000, guid: 816d14bb0d767435585a0bb55886aaef, type: 3} + samguk: {fileID: 0} + tint: {r: 0.84705883, g: 0.25490198, b: 0.18431373, a: 1} + - id: gear_book + pack: {fileID: 21300000, guid: 4ea16497cec35499e8fcb6e48452aa29, type: 3} + samguk: {fileID: 0} + tint: {r: 1, g: 1, b: 1, a: 1} + - id: gear_potion + pack: {fileID: 21300000, guid: 67f5e0fdd0f6b4952a22b99269db6096, type: 3} + samguk: {fileID: 0} + tint: {r: 1, g: 1, b: 1, a: 1} + - id: gear_shield + pack: {fileID: 21300000, guid: 09135c198f8744fcd89493b169d11bd8, type: 3} + samguk: {fileID: 0} + tint: {r: 1, g: 1, b: 1, a: 1} + - id: gear_charm + pack: {fileID: 21300000, guid: 5d49c0aac30764cde93957570569f245, type: 3} + samguk: {fileID: 0} + tint: {r: 1, g: 1, b: 1, a: 1} + - id: gear_flag + pack: {fileID: 21300000, guid: 36c378f3ccf8c40fe8c6a3ae69624bae, type: 3} + samguk: {fileID: 0} + tint: {r: 1, g: 1, b: 1, a: 1} + - id: flag_shu + pack: {fileID: 21300000, guid: 0f8c944da644b42e09c7342aa5735ff9, type: 3} + samguk: {fileID: 0} + tint: {r: 1, g: 1, b: 1, a: 1} + - id: flag_wei + pack: {fileID: 21300000, guid: ca6ab62179a66442588aacd94b454ffe, type: 3} + samguk: {fileID: 0} + tint: {r: 1, g: 1, b: 1, a: 1} + - id: flag_wu + pack: {fileID: 21300000, guid: b625cd3838cc0477ca073199439588b5, type: 3} + samguk: {fileID: 0} + tint: {r: 1, g: 1, b: 1, a: 1} + - id: flag_other + pack: {fileID: 21300000, guid: 6f23dee49868b4ee4bb927e2eebe0f5a, type: 3} + samguk: {fileID: 0} + tint: {r: 0.54901963, g: 0.54901963, b: 0.5882353, a: 1} + - id: rank_1 + pack: {fileID: 21300000, guid: 8ae43bb338f6c4486b21b6220a1cac9d, type: 3} + samguk: {fileID: 0} + tint: {r: 1, g: 1, b: 1, a: 1} + - id: rank_2 + pack: {fileID: 21300000, guid: cbe57c0243cf5440e9934cffa4681019, type: 3} + samguk: {fileID: 0} + tint: {r: 1, g: 1, b: 1, a: 1} + - id: rank_3 + pack: {fileID: 21300000, guid: 4b3a9b4d9f2ed4a92996c71af3ba0c42, type: 3} + samguk: {fileID: 0} + tint: {r: 1, g: 1, b: 1, a: 1} + - id: rank_4 + pack: {fileID: 21300000, guid: 0e3e88c80644941acab7b5bfc3d02d78, type: 3} + samguk: {fileID: 0} + tint: {r: 1, g: 1, b: 1, a: 1} + - id: rank_5 + pack: {fileID: 21300000, guid: 7f4622e1fadad4b7680182e7309efca3, type: 3} + samguk: {fileID: 0} + tint: {r: 1, g: 1, b: 1, a: 1} + - id: rank_6 + pack: {fileID: 21300000, guid: 1054306ffb8884ea8a2e142d780c85cb, type: 3} + samguk: {fileID: 0} + tint: {r: 1, g: 1, b: 1, a: 1} + - id: rank_7 + pack: {fileID: 21300000, guid: 65172c8f38641400dbb8dea2f06a5fcd, type: 3} + samguk: {fileID: 0} + tint: {r: 1, g: 1, b: 1, a: 1} + - id: star_on + pack: {fileID: 21300000, guid: 39afaf3c0b490422ea5f07aac1dcfbe1, type: 3} + samguk: {fileID: 0} + tint: {r: 1, g: 1, b: 1, a: 1} + - id: star_off + pack: {fileID: 21300000, guid: d228604ab6373411fac2dbf1e0e215d1, type: 3} + samguk: {fileID: 0} + tint: {r: 1, g: 1, b: 1, a: 1} + - id: lock + pack: {fileID: 21300000, guid: 899da40fa9ae1462c8e7e40a89da5ca1, type: 3} + samguk: {fileID: 0} + tint: {r: 1, g: 1, b: 1, a: 1} + - id: check + pack: {fileID: 21300000, guid: 598c081bd6eaf40bfba9db8c9e2862a9, type: 3} + samguk: {fileID: 0} + tint: {r: 1, g: 1, b: 1, a: 1} + - id: arrow_prev + pack: {fileID: 21300000, guid: a9d09d9a3d0d442079a130341db6be90, type: 3} + samguk: {fileID: 0} + tint: {r: 1, g: 1, b: 1, a: 1} + - id: arrow_next + pack: {fileID: 21300000, guid: 84c3adc90c0da4f009a1cfa76fa9363c, type: 3} + samguk: {fileID: 0} + tint: {r: 1, g: 1, b: 1, a: 1} + - id: arrow_back + pack: {fileID: 21300000, guid: 26459d86a13194dc1ab0997e73d7c594, type: 3} + samguk: {fileID: 0} + tint: {r: 1, g: 1, b: 1, a: 1} + - id: new_dot + pack: {fileID: 21300000, guid: 9209a152c6b45453e9b98b6a1f1f2084, type: 3} + samguk: {fileID: 0} + tint: {r: 0.9490196, g: 0.27058825, b: 0.22745098, a: 1} + - id: tut_hand + pack: {fileID: 21300000, guid: acfcced52c2a44ec78ff53f2b51971b2, type: 3} + samguk: {fileID: 0} + tint: {r: 1, g: 1, b: 1, a: 1} + - id: shop_pack + pack: {fileID: 21300000, guid: 33f163c49b488460ea0182825ae1600e, type: 3} + samguk: {fileID: 0} + tint: {r: 1, g: 1, b: 1, a: 1} + - id: bg_lobby + pack: {fileID: 21300000, guid: 604887b577dfd2e4aacb8cf8509a5878, type: 3} + samguk: {fileID: 0} + tint: {r: 1, g: 1, b: 1, a: 1} + titleFont: {fileID: 12800000, guid: c8e065a266a274eeebccb4ae0f64b3d9, type: 3} diff --git a/Assets/Resources/UI/UITheme.asset.meta b/Assets/Resources/UI/UITheme.asset.meta new file mode 100644 index 00000000..1865a7a5 --- /dev/null +++ b/Assets/Resources/UI/UITheme.asset.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 0944e51b3c366294b95f0b4b93cfe4c5 +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 11400000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Scripts/Editor/DataImporter.cs b/Assets/Scripts/Editor/DataImporter.cs index d36df94d..6790e675 100644 --- a/Assets/Scripts/Editor/DataImporter.cs +++ b/Assets/Scripts/Editor/DataImporter.cs @@ -121,6 +121,24 @@ namespace TKS.EditorTools EditorApplication.EnterPlaymode(); } + /// + /// UI 리뉴얼 검증 캡처(GUI 에디터 · 사본 프로젝트 권장 · 세이브 = 메모리 전용 · PD #1100): + /// Unity.exe -projectPath <copy> -executeMethod TKS.EditorTools.DataImporter.CaptureUI -uiDir <dir> + /// 화면 10종 + 팝업(1080×1920) + 1536×2048 2장 PNG + log · 끝나면 스스로 종료. + /// + public static void CaptureUI() + { + string dir = GetArg("-uiDir"); + if (string.IsNullOrEmpty(dir)) dir = Path.Combine(Directory.GetCurrentDirectory(), "Logs", "ui_capture"); + ImportAll(); + UIThemeImporter.Import(); + EditorSceneManager.OpenScene(ProjectSetup.ScenePath, OpenSceneMode.Single); + SessionState.SetBool(SaveStore.MemoryFlagKey, true); + SessionState.SetString(UICaptureDriver.DirKey, dir); + Debug.Log("[TKS] UI 캡처 시작 → " + dir); + EditorApplication.EnterPlaymode(); + } + static string GetArg(string name) { var args = System.Environment.GetCommandLineArgs(); diff --git a/Assets/Scripts/Editor/ProjectSetup.cs b/Assets/Scripts/Editor/ProjectSetup.cs index b91a47c4..316e3594 100644 --- a/Assets/Scripts/Editor/ProjectSetup.cs +++ b/Assets/Scripts/Editor/ProjectSetup.cs @@ -21,6 +21,7 @@ namespace TKS.EditorTools BuildScene(cfg); ApplySettings(); UnitArtImporter.ReimportAll(); + UIThemeImporter.Import(); AssetDatabase.SaveAssets(); AssetDatabase.Refresh(); Debug.Log("[TKS] Setup 완료 · " + ConfigPath + " · " + ScenePath); @@ -41,6 +42,7 @@ namespace TKS.EditorTools BuildScene(cfg); ApplySettings(); UnitArtImporter.ReimportAll(); + UIThemeImporter.Import(); AssetDatabase.SaveAssets(); AssetDatabase.Refresh(); Debug.Log("[TKS] BuildFresh 완료 · 기본값 재시드 · " + ScenePath); diff --git a/Assets/Scripts/Editor/UIThemeImporter.cs b/Assets/Scripts/Editor/UIThemeImporter.cs new file mode 100644 index 00000000..406520b6 --- /dev/null +++ b/Assets/Scripts/Editor/UIThemeImporter.cs @@ -0,0 +1,234 @@ +using System.Collections.Generic; +using System.IO; +using System.Text; +using UnityEditor; +using UnityEngine; + +namespace TKS.EditorTools +{ + /// + /// UI 테마 임포트(PD #1100) — Assets/Data/UI/ui_theme.csv(SOT) → Assets/Resources/UI/UITheme.asset. + /// 경로 = 팩 Components 기준 상대 경로(Assets/ 로 시작하면 그대로) · 오류가 있으면 자산을 바꾸지 않는다. + /// 신규 제작 납품(Assets/UI/Samguk/**/<id>.png)은 같은 id 의 스킨·아이콘을 치환하고 표에 없는 id 는 아이콘으로 추가한다(코드 변경 없이 교체). + /// + public static class UIThemeImporter + { + public const string CsvPath = "Assets/Data/UI/ui_theme.csv"; + public const string AssetPath = "Assets/Resources/UI/UITheme.asset"; + public const string PackRoot = "Assets/UI/GUIPro/ResourcesData/Sprites/Components/"; + public const string SamgukRoot = "Assets/UI/Samguk"; + + [MenuItem("TKS/Import UI Theme (UI 테마 임포트)")] + public static void Menu() + { + Import(); + } + + public static bool Import() + { + var errors = new List(); + var theme = ScriptableObject.CreateInstance(); + if (!File.Exists(CsvPath)) + { + Debug.LogError("[TKS] UI 테마 표 없음: " + CsvPath); + return false; + } + var lines = File.ReadAllText(CsvPath, Encoding.UTF8).TrimStart('').Replace("\r", "").Split('\n'); + for (int n = 1; n < lines.Length; n++) + { + var line = lines[n]; + if (string.IsNullOrWhiteSpace(line)) continue; + var f = line.Split(','); + if (f.Length < 8) + { + errors.Add((n + 1) + "행: 열 부족"); + continue; + } + string kind = f[0].Trim(), id = f[1].Trim(), path = f[2].Trim(), overlay = f[3].Trim(), color = f[7].Trim(); + switch (kind) + { + case "color": + { + Color c; + if (!ColorUtility.TryParseHtmlString(color, out c)) errors.Add((n + 1) + "행 " + id + ": 색 형식 " + color); + else theme.colors.Add(new UITheme.ColorEntry { id = id, color = c }); + break; + } + case "skin": + { + var s = new UITheme.SkinEntry { id = id, pack = LoadSprite(path, n, errors) }; + if (overlay.Length > 0) s.overlay = LoadSprite(overlay, n, errors); + s.ppu = ParseF(f[4], 1f); + s.inset = ParseInset(f[5]); + s.overlayAlpha = ParseF(f[6], 1f); + theme.skins.Add(s); + break; + } + case "icon": + { + var e = new UITheme.IconEntry { id = id, pack = LoadSprite(path, n, errors) }; + Color c; + if (color.Length > 0 && ColorUtility.TryParseHtmlString(color, out c)) e.tint = c; + theme.icons.Add(e); + break; + } + case "font": + if (id == "title") + { + theme.titleFont = AssetDatabase.LoadAssetAtPath(path); + if (theme.titleFont == null) errors.Add((n + 1) + "행: 폰트 없음 " + path); + } + break; + default: + errors.Add((n + 1) + "행: 알 수 없는 kind " + kind); + break; + } + } + if (errors.Count > 0) + { + foreach (var e in errors) Debug.LogError("[TKS] UI 테마 표 오류 · " + e); + Debug.LogError("[TKS] UI 테마 임포트 중단(오류 " + errors.Count + ") · 자산 변경 없음"); + Object.DestroyImmediate(theme); + return false; + } + + // 신규 제작 치환(파일 이름 = id) + var samguk = SamgukSprites(); + int replaced = 0, added = 0; + var used = new HashSet(); + foreach (var s in theme.skins) + { + Sprite sp; + if (samguk.TryGetValue(s.id, out sp)) + { + s.samguk = sp; + used.Add(s.id); + replaced++; + } + } + foreach (var e in theme.icons) + { + Sprite sp; + if (samguk.TryGetValue(e.id, out sp)) + { + e.samguk = sp; + used.Add(e.id); + replaced++; + } + } + foreach (var kv in samguk) + { + if (used.Contains(kv.Key)) continue; + theme.icons.Add(new UITheme.IconEntry { id = kv.Key, samguk = kv.Value }); + added++; + } + + if (!AssetDatabase.IsValidFolder("Assets/Resources")) AssetDatabase.CreateFolder("Assets", "Resources"); + if (!AssetDatabase.IsValidFolder("Assets/Resources/UI")) AssetDatabase.CreateFolder("Assets/Resources", "UI"); + var asset = AssetDatabase.LoadAssetAtPath(AssetPath); + if (asset == null) + { + AssetDatabase.CreateAsset(theme, AssetPath); + asset = theme; + } + else + { + EditorUtility.CopySerialized(theme, asset); + Object.DestroyImmediate(theme); + } + asset.Rebuild(); + EditorUtility.SetDirty(asset); + AssetDatabase.SaveAssets(); + UITheme.Use(asset); + Debug.Log("[TKS] UI 테마 임포트 · 색 " + asset.colors.Count + " · 스킨 " + asset.skins.Count + " · 아이콘 " + asset.icons.Count + + " · 신규 제작 치환 " + replaced + " · 추가 " + added + " → " + AssetPath); + return true; + } + + /// Assets/UI/Samguk/**/<id>.png → 스프라이트(같은 id 가 둘이면 경로 순 마지막). + public static Dictionary SamgukSprites() + { + var map = new Dictionary(); + if (!AssetDatabase.IsValidFolder(SamgukRoot)) return map; + var guids = AssetDatabase.FindAssets("t:Sprite", new[] { SamgukRoot }); + var paths = new List(); + foreach (var g in guids) paths.Add(AssetDatabase.GUIDToAssetPath(g)); + paths.Sort(System.StringComparer.Ordinal); + foreach (var p in paths) + { + var sp = AssetDatabase.LoadAssetAtPath(p); + if (sp != null) map[Path.GetFileNameWithoutExtension(p)] = sp; + } + return map; + } + + static Sprite LoadSprite(string path, int n, List errors) + { + if (string.IsNullOrEmpty(path)) + { + errors.Add((n + 1) + "행: 경로 없음"); + return null; + } + string full = path.StartsWith("Assets/") ? path : PackRoot + path; + var sp = AssetDatabase.LoadAssetAtPath(full); + if (sp == null) errors.Add((n + 1) + "행: 스프라이트 없음 " + full); + return sp; + } + + static float ParseF(string s, float def) + { + float v; + return float.TryParse(s.Trim(), System.Globalization.NumberStyles.Float, System.Globalization.CultureInfo.InvariantCulture, out v) ? v : def; + } + + static Vector4 ParseInset(string s) + { + s = s.Trim(); + if (s.Length == 0) return Vector4.zero; + var p = s.Split(';'); + if (p.Length == 1) + { + float v = ParseF(p[0], 0f); + return new Vector4(v, v, v, v); + } + return new Vector4(ParseF(p[0], 0f), p.Length > 1 ? ParseF(p[1], 0f) : 0f, p.Length > 2 ? ParseF(p[2], 0f) : 0f, p.Length > 3 ? ParseF(p[3], 0f) : 0f); + } + } + + /// 신규 제작 UI(Assets/UI/Samguk) · 로비 배경(Assets/UI/Lobby) 임포트 설정 = Sprite(2D) · 납품 파일이 들어오면 테마 치환 테이블 자동 갱신. + public class UIThemeAssetPostprocessor : AssetPostprocessor + { + static bool pending; + + static bool Ours(string path) + { + return path.StartsWith(UIThemeImporter.SamgukRoot + "/") || path.StartsWith("Assets/UI/Lobby/"); + } + + void OnPreprocessTexture() + { + if (!Ours(assetPath)) return; + var ti = (TextureImporter)assetImporter; + ti.textureType = TextureImporterType.Sprite; + ti.spriteImportMode = SpriteImportMode.Single; + ti.alphaIsTransparency = true; + ti.mipmapEnabled = false; + ti.spritePixelsPerUnit = 100f; + ti.maxTextureSize = assetPath.StartsWith("Assets/UI/Lobby/") ? 2048 : 1024; + } + + static void OnPostprocessAllAssets(string[] imported, string[] deleted, string[] moved, string[] movedFrom) + { + bool hit = false; + foreach (var p in imported) hit |= p.StartsWith(UIThemeImporter.SamgukRoot + "/") && p.EndsWith(".png"); + foreach (var p in deleted) hit |= p.StartsWith(UIThemeImporter.SamgukRoot + "/") && p.EndsWith(".png"); + if (!hit || pending) return; + pending = true; + EditorApplication.delayCall += () => + { + pending = false; + UIThemeImporter.Import(); + }; + } + } +} diff --git a/Assets/Scripts/Editor/UIThemeImporter.cs.meta b/Assets/Scripts/Editor/UIThemeImporter.cs.meta new file mode 100644 index 00000000..2450981c --- /dev/null +++ b/Assets/Scripts/Editor/UIThemeImporter.cs.meta @@ -0,0 +1,2 @@ +fileFormatVersion: 2 +guid: 30f8ad8437cad284d831742184f31c39 \ No newline at end of file diff --git a/Assets/Scripts/OutGame/Domestic/DomesticScreen.cs b/Assets/Scripts/OutGame/Domestic/DomesticScreen.cs index 500c9ddc..9b118129 100644 --- a/Assets/Scripts/OutGame/Domestic/DomesticScreen.cs +++ b/Assets/Scripts/OutGame/Domestic/DomesticScreen.cs @@ -225,10 +225,12 @@ namespace TKS.OutGame PatrolRules.ChestPerHour(db, d).ToString("0.##") + " / 시간", }; Color[] rc = { UiKit.Coin, new Color(0.8f, 0.48f, 0.38f), UiKit.Ok, new Color(0.7f, 0.48f, 0.3f) }; + string[] rIcon = { "cur_gold", "cur_exp", "cur_gear", "chest_bronze" }; for (int i = 0; i < 4; i++) { var line = UiKit.Box("Row" + i, rate, new Vector2(0.5f, 1f), new Vector2(0.5f, 1f), new Vector2(0f, -76f - i * 78f), new Vector2(980f, 68f), new Color(0.95f, 0.92f, 0.86f)); - UiKit.Dot("Dot", line.transform, new Vector2(0f, 0.5f), new Vector2(0f, 0.5f), new Vector2(16f, 0f), 50f, rc[i]); + if (UiKit.Icon(line.transform, rIcon[i], new Vector2(0f, 0.5f), new Vector2(0f, 0.5f), new Vector2(12f, 0f), 58f) == null) + UiKit.Dot("Dot", line.transform, new Vector2(0f, 0.5f), new Vector2(0f, 0.5f), new Vector2(16f, 0f), 50f, rc[i]); UiKit.Label(line.transform, rn[i], 34, UiKit.Ink, TextAnchor.MiddleLeft, new Vector2(0f, 0.5f), new Vector2(0f, 0.5f), new Vector2(86f, 0f), new Vector2(400f, 56f)); UiKit.Label(line.transform, rv[i], 30, UiKit.Ink, TextAnchor.MiddleRight, new Vector2(1f, 0.5f), new Vector2(1f, 0.5f), new Vector2(-20f, 0f), new Vector2(520f, 56f), false); } @@ -370,11 +372,9 @@ namespace TKS.OutGame var foot = UiKit.Box("Foot", p, new Vector2(0.5f, 0f), new Vector2(0.5f, 0f), new Vector2(0f, 16f), new Vector2(1032f, 150f), UiKit.Paper); UiKit.Border(foot, UiKit.Line, 3f); - var bp = UiKit.Dot("Bp", foot.transform, new Vector2(0f, 0.5f), new Vector2(0f, 0.5f), new Vector2(20f, 0f), 76f, new Color(0.33f, 0.45f, 0.62f)); - UiKit.FillLabel(bp.transform, "도", 36, UiKit.White); + UiKit.IconOrDot(foot.transform, "cur_blueprint", "도", new Color(0.33f, 0.45f, 0.62f), new Vector2(0f, 0.5f), new Vector2(0f, 0.5f), new Vector2(20f, 0f), 76f); UiKit.Label(foot.transform, "도면 ×" + d.inv.blueprint, 38, UiKit.Ink, TextAnchor.MiddleLeft, new Vector2(0f, 0.5f), new Vector2(0f, 0.5f), new Vector2(110f, 0f), new Vector2(260f, 60f)); - var gd = UiKit.Dot("Gold", foot.transform, new Vector2(0f, 0.5f), new Vector2(0f, 0.5f), new Vector2(380f, 0f), 76f, UiKit.Coin); - UiKit.FillLabel(gd.transform, "골", 36, UiKit.White); + UiKit.IconOrDot(foot.transform, "cur_gold", "골", UiKit.Coin, new Vector2(0f, 0.5f), new Vector2(0f, 0.5f), new Vector2(380f, 0f), 76f); UiKit.Label(foot.transform, d.gold.ToString("N0"), 38, UiKit.Ink, TextAnchor.MiddleLeft, new Vector2(0f, 0.5f), new Vector2(0f, 0.5f), new Vector2(470f, 0f), new Vector2(220f, 60f)); UiKit.Btn("Reset", foot.transform, "트리 초기화\n보옥 " + db.Economy.DevResetGem + " · 도면 환급", 34, UiKit.Dark, UiKit.White, new Vector2(1f, 0.5f), new Vector2(1f, 0.5f), new Vector2(-16f, 0f), new Vector2(320f, 120f), () => { diff --git a/Assets/Scripts/OutGame/Treasure/TreasureScreen.cs b/Assets/Scripts/OutGame/Treasure/TreasureScreen.cs index 231ac34c..de2e6d4c 100644 --- a/Assets/Scripts/OutGame/Treasure/TreasureScreen.cs +++ b/Assets/Scripts/OutGame/Treasure/TreasureScreen.cs @@ -98,7 +98,8 @@ namespace TKS.OutGame var cell = UiKit.Cell(parent, "T_" + it.id, owned ? UiKit.Paper : new Color(0.85f, 0.82f, 0.77f), owned ? (System.Action)(() => Detail(it.id)) : null); UiKit.Border(cell, owned ? GradeColor(it.grade) : new Color(0.7f, 0.66f, 0.62f), 3f); var icon = UiKit.Dot("Icon", cell.transform, new Vector2(0.5f, 1f), new Vector2(0.5f, 1f), new Vector2(0f, -14f), 120f, owned ? new Color(0.94f, 0.9f, 0.83f) : new Color(0.78f, 0.74f, 0.69f)); - UiKit.FillLabel(icon.transform, owned ? it.nameKo.Substring(0, 1) : "?", 60, owned ? GradeColor(it.grade) : new Color(0.6f, 0.56f, 0.52f)); + if (owned && UiKit.HasFinalIcon("tre_" + it.id)) UiKit.Icon(icon.transform, "tre_" + it.id, new Vector2(0.5f, 0.5f), new Vector2(0.5f, 0.5f), Vector2.zero, 100f); + else UiKit.FillLabel(icon.transform, owned ? it.nameKo.Substring(0, 1) : "?", 60, owned ? GradeColor(it.grade) : new Color(0.6f, 0.56f, 0.52f)); if (owned) { if (showShards && st.star < it.starMax) @@ -255,8 +256,8 @@ namespace TKS.OutGame var goalBox = UiKit.TopBand("Points", p, 6f, 150f, 24f, 24f); var gimg = UiKit.Paint(goalBox, UiKit.Paper); UiKit.Border(gimg, UiKit.Line, 3f); - var pd = UiKit.Dot("P", goalBox, new Vector2(0f, 0.5f), new Vector2(0f, 0.5f), new Vector2(20f, 0f), 90f, UiKit.Coin); - UiKit.FillLabel(pd.transform, "P", 44, UiKit.Ink); + if (UiKit.Icon(goalBox, "chest_point", new Vector2(0f, 0.5f), new Vector2(0f, 0.5f), new Vector2(16f, 0f), 100f) == null) + UiKit.FillLabel(UiKit.Dot("P", goalBox, new Vector2(0f, 0.5f), new Vector2(0f, 0.5f), new Vector2(20f, 0f), 90f, UiKit.Coin).transform, "P", 44, UiKit.Ink); var reward = db.Chests.Get(e.ChestPointReward); UiKit.Label(goalBox, (e.ChestPointGoal - d.inv.chestPoints) + "포인트 더 모으면 " + (reward != null ? reward.nameKo : ""), 34, UiKit.Ink, TextAnchor.MiddleLeft, new Vector2(0f, 1f), new Vector2(0f, 1f), new Vector2(130f, -12f), new Vector2(800f, 54f)); var fill = UiKit.Bar("Bar", goalBox, new Vector2(0f, 0f), new Vector2(0f, 0f), new Vector2(130f, 52f), new Vector2(700f, 30f), new Color(0.88f, 0.84f, 0.77f), UiKit.Coin); @@ -268,7 +269,8 @@ namespace TKS.OutGame int count = TreasureRules.ChestCount(d, c.id); var banner = UiKit.Box("Banner", p, new Vector2(0.5f, 1f), new Vector2(0.5f, 1f), new Vector2(0f, -180f), new Vector2(560f, 470f), ChestColor(c.id)); UiKit.Border(banner, new Color(0.25f, 0.2f, 0.18f), 4f); - UiKit.Label(banner.transform, c.nameKo, 60, UiKit.White, TextAnchor.MiddleCenter, new Vector2(0.5f, 1f), new Vector2(0.5f, 1f), new Vector2(0f, -40f), new Vector2(520f, 90f)); + UiKit.Title(UiKit.Label(banner.transform, c.nameKo, 60, UiKit.White, TextAnchor.MiddleCenter, new Vector2(0.5f, 1f), new Vector2(0.5f, 1f), new Vector2(0f, -40f), new Vector2(520f, 90f)), true); + UiKit.Icon(banner.transform, "chest_" + c.id, new Vector2(0f, 1f), new Vector2(0.5f, 0.5f), new Vector2(10f, -10f), 150f); int line = 0; for (int i = 0; i < ChestDb.ProbGrades.Length; i++) { @@ -305,6 +307,7 @@ namespace TKS.OutGame UiKit.Border(b.GetComponent(), i == chestIdx ? UiKit.Coin : UiKit.Line, i == chestIdx ? 5f : 2f); var box = UiKit.Box("Icon", b.transform, new Vector2(0.5f, 1f), new Vector2(0.5f, 1f), new Vector2(0f, -20f), new Vector2(w * 0.7f, 90f), ChestColor(ch.id)); box.raycastTarget = false; + UiKit.Icon(box.transform, "chest_" + ch.id, new Vector2(0.5f, 0.5f), new Vector2(0.5f, 0.5f), new Vector2(0f, 4f), 96f); UiKit.Label(b.transform, ch.nameKo + "\n×" + TreasureRules.ChestCount(d, ch.id) + "", 26, UiKit.Ink, TextAnchor.MiddleCenter, new Vector2(0.5f, 0f), new Vector2(0.5f, 0f), new Vector2(0f, 14f), new Vector2(w, 100f)); } } diff --git a/Assets/Scripts/OutGame/UI/BattleResultPanel.cs b/Assets/Scripts/OutGame/UI/BattleResultPanel.cs index fa4b9245..ad08950f 100644 --- a/Assets/Scripts/OutGame/UI/BattleResultPanel.cs +++ b/Assets/Scripts/OutGame/UI/BattleResultPanel.cs @@ -17,6 +17,9 @@ namespace TKS.OutGame readonly Text conds; readonly Text rewards; readonly Text hint; + readonly Image ribbon; + readonly RectTransform starRow; + readonly Image[] starImg = new Image[3]; public bool Visible { @@ -32,13 +35,32 @@ namespace TKS.OutGame { root = r; var dim = UiKit.Fill("Result", canvas); - UiKit.Paint(dim, new Color(0f, 0f, 0f, 0.55f), false); + UiKit.Paint(dim, UISkin.Col("dim", new Color(0f, 0f, 0f, 0.55f)), false); go = dim.gameObject; - var panel = UiKit.Box("Panel", dim, new Vector2(0.5f, 0.5f), new Vector2(0.5f, 0.5f), new Vector2(0f, 40f), new Vector2(920f, 1180f), UiKit.Paper); - UiKit.Border(panel, UiKit.Line, 4f); - var head = UiKit.TopBand("Head", panel.transform, 0f, 170f); - UiKit.Paint(head, UiKit.Dark); - title = UiKit.FillLabel(head, "", 96, UiKit.White); + Image panel; + if (UISkin.Has("popup")) + { + // 팩 팝업 틀 + 제목 리본(승리 = 붉은 · 패배 = 회색) + 별 아이콘 3 + panel = UiKit.Skin(UiKit.Rect("Panel", dim, new Vector2(0.5f, 0.5f), new Vector2(0.5f, 0.5f), new Vector2(0f, 20f), new Vector2(920f, 1180f)), "popup", UiKit.Paper); + var rib = UiKit.Rect("Ribbon", panel.transform, new Vector2(0.5f, 1f), new Vector2(0.5f, 0.5f), new Vector2(0f, 10f), new Vector2(1000f, 200f)); + ribbon = UiKit.Skin(rib, "ribbon", Color.white); + title = UiKit.Title(UiKit.FillLabel(rib, "", 88, UiKit.White, TextAnchor.MiddleCenter, true, 150f), true); + title.rectTransform.offsetMin = new Vector2(150f, 34f); + starRow = UiKit.Rect("StarRow", panel.transform, new Vector2(0.5f, 1f), new Vector2(0.5f, 1f), new Vector2(0f, -150f), new Vector2(600f, 190f)); + for (int i = 0; i < 3; i++) + { + float s = i == 1 ? 190f : 150f; + starImg[i] = UiKit.Icon(starRow, "star_on", new Vector2(0.5f, 0.5f), new Vector2(0.5f, 0.5f), new Vector2((i - 1) * 180f, i == 1 ? 14f : -10f), s); + } + } + else + { + panel = UiKit.Box("Panel", dim, new Vector2(0.5f, 0.5f), new Vector2(0.5f, 0.5f), new Vector2(0f, 40f), new Vector2(920f, 1180f), UiKit.Paper); + UiKit.Border(panel, UiKit.Line, 4f); + var head = UiKit.TopBand("Head", panel.transform, 0f, 170f); + UiKit.Paint(head, UiKit.Dark); + title = UiKit.FillLabel(head, "", 96, UiKit.White); + } stars = UiKit.Label(panel.transform, "", 120, UiKit.Star, TextAnchor.MiddleCenter, new Vector2(0.5f, 1f), new Vector2(0.5f, 1f), new Vector2(0f, -190f), new Vector2(800f, 150f)); conds = UiKit.Label(panel.transform, "", 34, UiKit.Ink, TextAnchor.UpperLeft, new Vector2(0.5f, 1f), new Vector2(0.5f, 1f), new Vector2(0f, -350f), new Vector2(760f, 180f), false); conds.lineSpacing = 1.15f; @@ -61,6 +83,7 @@ namespace TKS.OutGame hint.text = "화면을 탭하면 월드맵으로"; title.text = (r.win ? "승리" : "패배") + " " + r.chapter + "-" + r.stage + (r.boss ? " 보스" : "") + ""; stars.text = r.win ? UiKit.Stars(r.stars, 3) : UiKit.Stars(0, 3); + ShowStars(r.win ? r.stars : 0, r.win); if (r.win) { conds.text = Mark(r.conds[0]) + " 클리어\n" + @@ -87,10 +110,22 @@ namespace TKS.OutGame } title.text = r.kind == ArenaRules.Raid ? "토벌 종료" : r.win ? "승리" : "패배"; stars.text = ""; + ShowStars(-1, r.win || r.kind == ArenaRules.Raid); conds.text = "" + r.title + ""; rewards.text = string.Join("\n", r.lines.ToArray()); } + /// 별 아이콘(n < 0 = 숨김) · 리본 색(승리 붉은 · 패배 회색) · 테마가 없으면 글자 별만. + void ShowStars(int n, bool win) + { + if (starRow == null) return; + stars.gameObject.SetActive(false); + starRow.gameObject.SetActive(n >= 0); + for (int i = 0; i < 3; i++) + if (starImg[i] != null) starImg[i].sprite = UISkin.Icon(i < n ? "star_on" : "star_off") ?? starImg[i].sprite; + if (ribbon != null && !UISkin.Apply(ribbon, win ? "ribbon" : "ribbon_gray")) ribbon.color = win ? Color.white : UiKit.Disabled; + } + static string Mark(bool ok) { return ok ? "○" : "×"; diff --git a/Assets/Scripts/OutGame/UI/HeroScreens.cs b/Assets/Scripts/OutGame/UI/HeroScreens.cs index 1617a1b4..46ce6169 100644 --- a/Assets/Scripts/OutGame/UI/HeroScreens.cs +++ b/Assets/Scripts/OutGame/UI/HeroScreens.cs @@ -15,22 +15,25 @@ namespace TKS.OutGame var hs = s.Save.Hero(h.id); UiKit.Portrait("Face", cell.transform, h, new Vector2(0f, 0.5f), new Vector2(0f, 0.5f), new Vector2(12f, 8f), new Vector2(116f, 108f), false, 2f, new Color(0.9f, 0.86f, 0.8f)); int star = hs != null ? hs.star : h.rarity; - UiKit.Label(cell.transform, UiKit.Stars(star, star), 22, UiKit.Star, TextAnchor.MiddleCenter, new Vector2(0f, 0f), new Vector2(0f, 0f), new Vector2(12f, 2f), new Vector2(116f, 30f)); + if (UISkin.Icon("star_on") != null) UiKit.StarRow(cell.transform, star, star, new Vector2(0f, 0f), new Vector2(0f, 0f), new Vector2(14f, 2f), 24f); + else UiKit.Label(cell.transform, UiKit.Stars(star, star), 22, UiKit.Star, TextAnchor.MiddleCenter, new Vector2(0f, 0f), new Vector2(0f, 0f), new Vector2(12f, 2f), new Vector2(116f, 30f)); UiKit.TypeBadge(cell.transform, h.type, new Vector2(0f, 1f), new Vector2(0f, 1f), new Vector2(142f, -16f), 40f); - UiKit.Label(cell.transform, owned ? "Lv " + (lv != null ? lv.lv : 1) : "미보유", 30, UiKit.Ink, TextAnchor.MiddleLeft, new Vector2(0f, 1f), new Vector2(0f, 1f), new Vector2(204f, -12f), new Vector2(150f, 48f)); + UiKit.Title(UiKit.Label(cell.transform, owned ? "Lv " + (lv != null ? lv.lv : 1) : "미보유", 30, UiKit.Ink, TextAnchor.MiddleLeft, new Vector2(0f, 1f), new Vector2(0f, 1f), new Vector2(204f, -12f), new Vector2(150f, 48f))); if (deployed) { var b = UiKit.Box("Deployed", cell.transform, new Vector2(1f, 1f), new Vector2(1f, 1f), new Vector2(-12f, -14f), new Vector2(124f, 44f), UiKit.Red); - UiKit.FillLabel(b.transform, "출전 중", 24, UiKit.White); + UiKit.Title(UiKit.FillLabel(b.transform, "출전 중", 24, UiKit.White), true); } if (hs != null) { - var g = UiKit.Box("Grade", cell.transform, new Vector2(1f, 0f), new Vector2(1f, 0f), new Vector2(-12f, 14f), new Vector2(56f, 40f), UiKit.GradeColor(hs.grade)); - UiKit.FillLabel(g.transform, UiKit.GradeKo(hs.grade), 24, UiKit.White); + var g = UiKit.Box("Grade", cell.transform, new Vector2(1f, 0f), new Vector2(1f, 0f), new Vector2(-12f, 14f), new Vector2(56f, 48f), UiKit.GradeColor(hs.grade)); + UiKit.GradeFrame(g, hs.grade); + UiKit.Title(UiKit.FillLabel(g.transform, UiKit.GradeKo(hs.grade), 24, UiKit.White), true); } - var name = UiKit.Label(cell.transform, h.nameKo, 44, owned ? UiKit.Ink : UiKit.InkSoft, TextAnchor.MiddleLeft, new Vector2(0f, 0f), new Vector2(0f, 0f), new Vector2(142f, 12f), new Vector2(290f, 66f)); + var name = UiKit.Title(UiKit.Label(cell.transform, h.nameKo, 44, owned ? UiKit.Ink : UiKit.InkSoft, TextAnchor.MiddleLeft, new Vector2(0f, 0f), new Vector2(0f, 0f), new Vector2(142f, 12f), new Vector2(290f, 66f))); name.horizontalOverflow = HorizontalWrapMode.Overflow; - if (owned && s.CanGrowAny(h.id)) UiKit.Dot("New", cell.transform, new Vector2(0f, 1f), new Vector2(0.5f, 0.5f), new Vector2(14f, -10f), 26f, UiKit.Red); + if (owned && s.CanGrowAny(h.id) && UiKit.Icon(cell.transform, "new_dot", new Vector2(0f, 1f), new Vector2(0.5f, 0.5f), new Vector2(14f, -10f), 34f) == null) + UiKit.Dot("New", cell.transform, new Vector2(0f, 1f), new Vector2(0.5f, 0.5f), new Vector2(14f, -10f), 26f, UiKit.Red); return cell; } } @@ -102,6 +105,9 @@ namespace TKS.OutGame readonly Image[] slotImg = new Image[6]; readonly Text[] slotName = new Text[6]; readonly Text[] slotState = new Text[6]; + readonly Image[] slotIcon = new Image[6]; + readonly Image[] slotMark = new Image[6]; + RectTransform starRow; Image typeDot; Text typeMark; Text nameText; @@ -158,8 +164,24 @@ namespace TKS.OutGame var b = UiKit.Btn("Slot" + i, card, "", 24, UiKit.Slot, UiKit.Ink, a, a, new Vector2(left ? 22f : -22f, -104f - row * 172f), new Vector2(196f, 156f), () => OnSlot(k)); slotImg[i] = b.GetComponent(); UiKit.LabelOf(b).text = ""; - slotName[i] = UiKit.Label(b.transform, "", 30, UiKit.Ink, TextAnchor.MiddleCenter, new Vector2(0.5f, 1f), new Vector2(0.5f, 1f), new Vector2(0f, -12f), new Vector2(186f, 84f)); - slotState[i] = UiKit.Label(b.transform, "", 24, UiKit.InkSoft, TextAnchor.MiddleCenter, new Vector2(0.5f, 0f), new Vector2(0.5f, 0f), new Vector2(0f, 10f), new Vector2(186f, 44f), false); + if (UISkin.On) + { + // 팩 등급 칸(ItemFrame) + 장비 아이콘(테마 gear_ · 임시) + 이름 한 줄 + 상태 + slotIcon[i] = UiKit.Rect("GearIcon", b.transform, new Vector2(0.5f, 0.5f), new Vector2(0.5f, 0.5f), new Vector2(0f, 8f), new Vector2(72f, 72f)).gameObject.AddComponent(); + slotIcon[i].preserveAspect = true; + slotIcon[i].raycastTarget = false; + slotMark[i] = UiKit.Rect("Mark", b.transform, new Vector2(1f, 1f), new Vector2(0.5f, 0.5f), new Vector2(-14f, -14f), new Vector2(44f, 44f)).gameObject.AddComponent(); + slotMark[i].preserveAspect = true; + slotMark[i].raycastTarget = false; + slotName[i] = UiKit.Label(b.transform, "", 28, UiKit.Ink, TextAnchor.MiddleCenter, new Vector2(0.5f, 1f), new Vector2(0.5f, 1f), new Vector2(0f, -6f), new Vector2(186f, 40f)); + slotState[i] = UiKit.Label(b.transform, "", 22, UiKit.Ink, TextAnchor.MiddleCenter, new Vector2(0.5f, 0f), new Vector2(0.5f, 0f), new Vector2(0f, 10f), new Vector2(186f, 34f)); + UISkin.Stroke(slotState[i], UiKit.White, 1.5f); + } + else + { + slotName[i] = UiKit.Label(b.transform, "", 30, UiKit.Ink, TextAnchor.MiddleCenter, new Vector2(0.5f, 1f), new Vector2(0.5f, 1f), new Vector2(0f, -12f), new Vector2(186f, 84f)); + slotState[i] = UiKit.Label(b.transform, "", 24, UiKit.InkSoft, TextAnchor.MiddleCenter, new Vector2(0.5f, 0f), new Vector2(0.5f, 0f), new Vector2(0f, 10f), new Vector2(186f, 44f), false); + } } var band = UiKit.Rect("NameBand", card, new Vector2(0.5f, 0f), new Vector2(0.5f, 0f), Vector2.zero, new Vector2(0f, 116f)); band.anchorMin = new Vector2(0f, 0f); @@ -173,6 +195,8 @@ namespace TKS.OutGame nameText.horizontalOverflow = HorizontalWrapMode.Overflow; subText = UiKit.Label(band, "", 28, new Color(0.85f, 0.8f, 0.75f), TextAnchor.MiddleLeft, new Vector2(0f, 0.5f), new Vector2(0f, 0.5f), new Vector2(420f, 0f), new Vector2(330f, 80f), false); starText = UiKit.Label(band, "", 52, UiKit.Star, TextAnchor.MiddleRight, new Vector2(1f, 0.5f), new Vector2(1f, 0.5f), new Vector2(-24f, 0f), new Vector2(300f, 80f)); + if (UISkin.Icon("star_on") != null) starRow = UiKit.Rect("StarRow", band, new Vector2(1f, 0.5f), new Vector2(1f, 0.5f), new Vector2(-20f, 0f), new Vector2(300f, 60f)); + UiKit.Title(nameText, true); // ② 스킬 정보 var skill = UiKit.TopBand("Skill", body, 752f, 400f, 24f, 24f); @@ -205,8 +229,7 @@ namespace TKS.OutGame // ④ 조각 · 진화 var shRow = UiKit.TopBand("Shard", body, 1290f, 96f, 24f, 24f); - var sd = UiKit.Dot("ShardDot", shRow, new Vector2(0f, 0.5f), new Vector2(0f, 0.5f), new Vector2(0f, -14f), 54f, UiKit.Purple); - UiKit.FillLabel(sd.transform, "조", 28, UiKit.White); + UiKit.IconOrDot(shRow, "cur_shard", "조", UiKit.Purple, new Vector2(0f, 0.5f), new Vector2(0f, 0.5f), new Vector2(0f, -14f), 58f); UiKit.Label(shRow, "영웅 조각", 32, UiKit.Ink, TextAnchor.MiddleLeft, new Vector2(0f, 1f), new Vector2(0f, 1f), new Vector2(64f, 0f), new Vector2(300f, 46f)); shardBar = UiKit.Bar("ShardBar", shRow, new Vector2(0f, 0f), new Vector2(0f, 0f), new Vector2(64f, 4f), new Vector2(690f, 42f), new Color(0.86f, 0.82f, 0.75f), UiKit.Purple); shardText = UiKit.Label(shardBar.parent, "", 28, UiKit.Ink, TextAnchor.MiddleCenter, new Vector2(0.5f, 0.5f), new Vector2(0.5f, 0.5f), Vector2.zero, new Vector2(680f, 42f)); @@ -250,6 +273,24 @@ namespace TKS.OutGame slotImg[i].gameObject.SetActive(need != null); if (need == null) continue; slotName[i].text = g != null ? g.nameKo : need; + if (slotIcon[i] != null) + { + // 등급 칸 + 아이콘 · 장착 = 체크 · 가방 보유 = 알림 점 · 없음 = 아이콘 흐리게(글자 = 흰 + 외곽선) + UiKit.GradeFrame(slotImg[i], g != null ? g.grade : "white"); + var gs = UISkin.Icon(g != null ? "gear_" + g.kind : null); + var ge = gs != null ? UISkin.Theme.IconEntryOf("gear_" + g.kind) : null; + slotIcon[i].sprite = gs; + slotIcon[i].enabled = gs != null; + var tint = ge != null && ge.samguk == null ? ge.tint : Color.white; + slotIcon[i].color = new Color(tint.r, tint.g, tint.b, on || have > 0 ? 1f : 0.4f); + slotMark[i].sprite = UISkin.Icon(on ? "check" : "new_dot"); + slotMark[i].enabled = (on || have > 0) && slotMark[i].sprite != null; + slotMark[i].color = on ? Color.white : UISkin.Theme.IconEntryOf("new_dot") != null ? UISkin.Theme.IconEntryOf("new_dot").tint : UiKit.Red; + string gk = UiKit.GradeKo(g != null ? g.grade : ""); + slotState[i].color = on ? UiKit.Ok : have > 0 ? UiKit.Red : UiKit.InkSoft; + slotState[i].text = on ? "장착 · " + gk : have > 0 ? "탭하여 장착 ×" + have : "없음 · " + gk; + continue; + } if (on) { slotImg[i].color = new Color(0.9f, 0.95f, 0.86f); @@ -272,6 +313,13 @@ namespace TKS.OutGame nameText.text = h.nameKo; subText.text = UnitTypeInfo.Korean(h.type) + " · " + (h.isSoldier ? "병사 유닛" : UiKit.GradeKo(hs.grade) + " 등급"); starText.text = h.isSoldier ? UiKit.Stars(h.rarity, 3) : UiKit.Stars(hs.star, db.Evolve.MaxStar); + if (starRow != null) + { + starText.text = ""; + UiKit.Clear(starRow); + int max = h.isSoldier ? 3 : db.Evolve.MaxStar; + UiKit.StarRow(starRow, h.isSoldier ? h.rarity : hs.star, max, new Vector2(1f, 0.5f), new Vector2(1f, 0.5f), Vector2.zero, 56f); + } var skills = new[] { db.Skills.Get(h.skillActive), db.Skills.Get(h.skillPassive) }; for (int i = 0; i < 2; i++) diff --git a/Assets/Scripts/OutGame/UI/LobbyScreen.cs b/Assets/Scripts/OutGame/UI/LobbyScreen.cs index 062a95f2..633c90ca 100644 --- a/Assets/Scripts/OutGame/UI/LobbyScreen.cs +++ b/Assets/Scripts/OutGame/UI/LobbyScreen.cs @@ -16,14 +16,34 @@ namespace TKS.OutGame Header("본영", "로비", false); var body = Body(); + // 배경 = 테마 bg_lobby(키아트 04 · 어둡게 · 신규 제작 로비 배경이 오면 치환) · 없으면 땅 색 판 + var art = UISkin.Icon("bg_lobby"); + if (art != null) + { + var clip = UiKit.Fill("LobbyBg", body); + clip.gameObject.AddComponent(); + // 위쪽 맞춤 × 1.22 — 키아트 아래쪽 아군 5인은 잘라 내고(편성 5인과 겹치지 않게) 전장·적진만 보이게 + var art2 = UiKit.Rect("Art", clip, new Vector2(0.5f, 1f), new Vector2(0.5f, 1f), Vector2.zero, Vector2.zero); + art2.anchorMin = new Vector2(-0.11f, 1f); + art2.anchorMax = new Vector2(1.11f, 1f); + art2.offsetMin = art2.offsetMax = Vector2.zero; + var bimg = art2.gameObject.AddComponent(); + bimg.sprite = art; + bimg.color = UISkin.Col("lobby_tint", Color.white); + bimg.raycastTarget = false; + var fit = bimg.gameObject.AddComponent(); + fit.aspectMode = AspectRatioFitter.AspectMode.WidthControlsHeight; + fit.aspectRatio = art.rect.width / Mathf.Max(1f, art.rect.height); + } + var chip = UiKit.Box("Progress", body, new Vector2(0.5f, 1f), new Vector2(0.5f, 1f), new Vector2(0f, -28f), new Vector2(760f, 84f), UiKit.Paper); UiKit.Border(chip, UiKit.Line, 2f); progress = UiKit.FillLabel(chip.transform, "", 34, UiKit.Ink); - // 전장 자리(배경 아트 없음 → 땅 색 판) · 출전 편성 5인 + // 전장 자리 · 출전 편성 5인 var ground = UiKit.Fill("Field", body, 24f, 24f, 140f, 520f); - UiKit.Paint(ground, new Color(0.47f, 0.52f, 0.36f)); - var shadow = UiKit.Box("Shadow", ground, new Vector2(0.5f, 0f), new Vector2(0.5f, 0f), new Vector2(0f, 70f), new Vector2(940f, 150f), new Color(0.2f, 0.18f, 0.14f, 0.55f)); + if (art == null) UiKit.Paint(ground, new Color(0.47f, 0.52f, 0.36f)); + var shadow = UiKit.Box("Shadow", ground, new Vector2(0.5f, 0f), new Vector2(0.5f, 0f), new Vector2(0f, 70f), new Vector2(940f, 150f), new Color(0.2f, 0.18f, 0.14f, 0.55f), false); shadow.sprite = UiKit.Circle; shadow.type = Image.Type.Simple; field = UiKit.Fill("Lineup", ground, 20f, 20f, 40f, 40f); @@ -32,28 +52,30 @@ namespace TKS.OutGame var sortie = UiKit.Btn("Sortie", body, "", 40, UiKit.Red, UiKit.White, new Vector2(0.5f, 0f), new Vector2(0.5f, 0f), new Vector2(0f, y), new Vector2(440f, 400f), () => Root.OpenWorldMap()); UiKit.Border(sortie.GetComponent(), new Color(0.98f, 0.86f, 0.7f), 5f); UiKit.LabelOf(sortie).text = ""; - UiKit.Label(sortie.transform, "로비 중앙", 28, new Color(1f, 0.85f, 0.8f), TextAnchor.MiddleCenter, new Vector2(0.5f, 1f), new Vector2(0.5f, 1f), new Vector2(0f, -22f), new Vector2(400f, 50f), false); - UiKit.Label(sortie.transform, "출정", 120, UiKit.White, TextAnchor.MiddleCenter, new Vector2(0.5f, 0.5f), new Vector2(0.5f, 0.5f), new Vector2(0f, 30f), new Vector2(420f, 170f)); + var si = UiKit.Icon(sortie.transform, "btn_sortie", new Vector2(0.5f, 1f), new Vector2(0.5f, 1f), new Vector2(0f, -26f), 92f); + if (si != null) UISkin.Stroke(si, UiKit.Stroke, 3f); + else UiKit.Label(sortie.transform, "로비 중앙", 28, new Color(1f, 0.85f, 0.8f), TextAnchor.MiddleCenter, new Vector2(0.5f, 1f), new Vector2(0.5f, 1f), new Vector2(0f, -22f), new Vector2(400f, 50f), false); + UiKit.Title(UiKit.Label(sortie.transform, "출정", 120, UiKit.White, TextAnchor.MiddleCenter, new Vector2(0.5f, 0.5f), new Vector2(0.5f, 0.5f), new Vector2(0f, 30f), new Vector2(420f, 170f)), true); int stages = Root.Battle != null ? Root.Battle.Config.stages.Length : 0; - UiKit.Label(sortie.transform, "챕터 월드맵\n" + stages + " 스테이지", 34, UiKit.White, TextAnchor.MiddleCenter, new Vector2(0.5f, 0f), new Vector2(0.5f, 0f), new Vector2(0f, 30f), new Vector2(420f, 100f), false); + UiKit.Title(UiKit.Label(sortie.transform, "챕터 월드맵\n" + stages + " 스테이지", 34, UiKit.White, TextAnchor.MiddleCenter, new Vector2(0.5f, 0f), new Vector2(0.5f, 0f), new Vector2(0f, 34f), new Vector2(420f, 100f), false), true); - SideButton(body, "Formation", "편", "편성", "출정 좌측", -1, () => Root.Show(Root.Formation)); - SideButton(body, "Arena", "연", "연무장", "출정 우측", 1, () => + SideButton(body, "Formation", "btn_formation", "편", "편성", "출정 좌측", -1, () => Root.Show(Root.Formation)); + SideButton(body, "Arena", "btn_arena", "연", "연무장", "출정 우측", 1, () => { Root.Arena.SetPage(0); Root.Show(Root.Arena); // 연무장(PD #1093 C) }); } - void SideButton(RectTransform body, string name, string mark, string title, string sub, int side, System.Action onClick) + void SideButton(RectTransform body, string name, string icon, string mark, string title, string sub, int side, System.Action onClick) { float x = side * (220f + 160f); var b = UiKit.Btn(name, body, "", 30, UiKit.Paper, UiKit.Ink, new Vector2(0.5f, 0f), new Vector2(0.5f, 0f), new Vector2(x, 70f), new Vector2(290f, 340f), onClick); UiKit.Border(b.GetComponent(), UiKit.Line, 3f); var dot = UiKit.Dot("Mark", b.transform, new Vector2(0.5f, 1f), new Vector2(0.5f, 1f), new Vector2(0f, -36f), 110f, UiKit.Dark); - UiKit.FillLabel(dot.transform, mark, 50, UiKit.White); - UiKit.Label(b.transform, title, 52, UiKit.Ink, TextAnchor.MiddleCenter, new Vector2(0.5f, 0.5f), new Vector2(0.5f, 0.5f), new Vector2(0f, -40f), new Vector2(280f, 80f)); - UiKit.Label(b.transform, sub, 28, UiKit.InkSoft, TextAnchor.MiddleCenter, new Vector2(0.5f, 0f), new Vector2(0.5f, 0f), new Vector2(0f, 30f), new Vector2(280f, 50f), false); + if (UiKit.Icon(dot.transform, icon, new Vector2(0.5f, 0.5f), new Vector2(0.5f, 0.5f), Vector2.zero, 66f) == null) UiKit.FillLabel(dot.transform, mark, 50, UiKit.White); + UiKit.Title(UiKit.Label(b.transform, title, 52, UiKit.Ink, TextAnchor.MiddleCenter, new Vector2(0.5f, 0.5f), new Vector2(0.5f, 0.5f), new Vector2(0f, -40f), new Vector2(280f, 80f))); + UiKit.Label(b.transform, sub, 28, UiKit.InkSoft, TextAnchor.MiddleCenter, new Vector2(0.5f, 0f), new Vector2(0.5f, 0f), new Vector2(0f, 34f), new Vector2(280f, 50f), false); } public override void Refresh() diff --git a/Assets/Scripts/OutGame/UI/OutGameRoot.cs b/Assets/Scripts/OutGame/UI/OutGameRoot.cs index d1b61afb..84992d63 100644 --- a/Assets/Scripts/OutGame/UI/OutGameRoot.cs +++ b/Assets/Scripts/OutGame/UI/OutGameRoot.cs @@ -32,18 +32,24 @@ namespace TKS.OutGame float x = 36f; if (back) { - UiKit.Btn("Back", band, "◀", 44, UiKit.Dark, UiKit.White, new Vector2(0f, 0.5f), new Vector2(0f, 0.5f), new Vector2(24f, 0f), new Vector2(100f, 76f), () => Root.Back()); + var b = UiKit.Btn("Back", band, "◀", 44, UISkin.On ? UiKit.Red : UiKit.Dark, UiKit.White, new Vector2(0f, 0.5f), new Vector2(0f, 0.5f), new Vector2(24f, 0f), new Vector2(100f, 80f), () => Root.Back()); + if (UiKit.Icon(b.transform, "arrow_back", new Vector2(0.5f, 0.5f), new Vector2(0.5f, 0.5f), new Vector2(0f, 6f), 50f) != null) UiKit.LabelOf(b).text = ""; x = 146f; } - var t = UiKit.Label(band, title, 52, UiKit.Ink, TextAnchor.MiddleLeft, new Vector2(0f, 0.5f), new Vector2(0f, 0.5f), new Vector2(x, 0f), new Vector2(360f, 90f)); + var t = UiKit.Title(UiKit.Label(band, title, 52, UiKit.HeaderText, TextAnchor.MiddleLeft, new Vector2(0f, 0.5f), new Vector2(0f, 0.5f), new Vector2(x, 0f), new Vector2(360f, 90f)), true); t.horizontalOverflow = HorizontalWrapMode.Overflow; - UiKit.Label(band, sub, 30, UiKit.InkSoft, TextAnchor.MiddleLeft, new Vector2(0f, 0.5f), new Vector2(0f, 0.5f), new Vector2(x + t.preferredWidth + 18f, -4f), new Vector2(700f, 60f), false); + UiKit.Label(band, sub, 30, UiKit.HeaderSub, TextAnchor.MiddleLeft, new Vector2(0f, 0.5f), new Vector2(0f, 0.5f), new Vector2(x + t.preferredWidth + 18f, -4f), new Vector2(700f, 60f), false); } - /// 제목 띠 아래 ~ 하단 탭 위 본문. + /// + /// 제목 띠 아래 ~ 하단 탭 위 본문 — 기준(1080×1920)의 본문 높이보다 화면이 낮으면(예 1536×2048 = 3:4) 본문 전체를 같은 비율로 줄여 탭 바 밑으로 숨지 않게 한다(PD #1100 · 배치는 그대로). + /// protected RectTransform Body(string name = "Body") { - return UiKit.Fill(name, Rt, 0f, 0f, OutGameRoot.TopBarH + OutGameRoot.HeaderH, OutGameRoot.TabBarH); + var outer = UiKit.Fill(name, Rt, 0f, 0f, OutGameRoot.TopBarH + OutGameRoot.HeaderH, OutGameRoot.TabBarH); + var inner = UiKit.Rect("Fit", outer, new Vector2(0.5f, 1f), new Vector2(0.5f, 1f), Vector2.zero, new Vector2(OutGameRoot.Reference.x, OutGameRoot.BodyH)); + inner.gameObject.AddComponent().designHeight = OutGameRoot.BodyH; + return inner; } } @@ -60,6 +66,11 @@ namespace TKS.OutGame public const float HeaderH = 104f; public const float TabBarH = 150f; public static readonly Vector2 Reference = new Vector2(1080f, 1920f); + /// 기준 화면의 본문 높이(재화 바 · 제목 띠 · 하단 탭 제외). + public static float BodyH + { + get { return Reference.y - TopBarH - HeaderH - TabBarH; } + } public OutGameSession Session { get; private set; } public BattleManager Battle { get; private set; } @@ -246,7 +257,8 @@ namespace TKS.OutGame for (int i = 0; i < tabImages.Count; i++) { bool on = scr.Tab == i; - tabImages[i].color = on ? UiKit.Red : UiKit.Dark; + if (UISkin.On) tabImages[i].gameObject.SetActive(on); + else tabImages[i].color = on ? UiKit.Red : UiKit.Dark; } scr.OnShow(); scr.Refresh(); @@ -334,24 +346,32 @@ namespace TKS.OutGame void BuildCurrencyBar() { barRoot = UiKit.TopBand("CurrencyBar", TopRoot, 0f, TopBarH); - UiKit.Paint(barRoot, new Color(0.15f, 0.11f, 0.09f), false, true); - goldText = Pill(0, "골", "골드", UiKit.Coin, () => Toast("골드 = 스테이지 보상 · 거래 > 상점 · (구매 상점 준비 중)")); - gemText = Pill(1, "보", "보옥", UiKit.Jade, () => Toast("보옥 구매(과금) = 준비 중 · 첫 클리어 · 보스 보상")); - staminaText = Pill(2, "군", "군량", UiKit.Grain, StaminaModal); + UiKit.Paint(barRoot, UISkin.On ? UiKit.BarColor : new Color(0.15f, 0.11f, 0.09f), false, true); + goldText = Pill(0, "cur_gold", "골", "골드", UiKit.Coin, () => Toast("골드 = 스테이지 보상 · 거래 > 상점 · (구매 상점 준비 중)")); + gemText = Pill(1, "cur_gem", "보", "보옥", UiKit.Jade, () => Toast("보옥 구매(과금) = 준비 중 · 첫 클리어 · 보스 보상")); + staminaText = Pill(2, "cur_stamina", "군", "군량", UiKit.Grain, StaminaModal); staminaTimer = staminaText.transform.parent.Find("Name").GetComponent(); } - Text Pill(int i, string mark, string name, Color c, Action plus) + /// 재화 칩(팩 ResourceBar · 아이콘 = 테마 cur_* · 「+」 = 팩 노란 단추). + Text Pill(int i, string icon, string mark, string name, Color c, Action plus) { float w = 336f; - var p = UiKit.Box("Pill" + i, barRoot, new Vector2(0f, 0.5f), new Vector2(0f, 0.5f), new Vector2(18f + i * (w + 18f), 0f), new Vector2(w, 84f), new Color(0.27f, 0.21f, 0.18f)); - var dot = UiKit.Dot("Icon", p.transform, new Vector2(0f, 0.5f), new Vector2(0f, 0.5f), new Vector2(8f, 0f), 64f, c); - UiKit.FillLabel(dot.transform, mark, 32, UiKit.White); - var n = UiKit.Label(p.transform, name, 26, new Color(0.85f, 0.8f, 0.75f), TextAnchor.MiddleLeft, new Vector2(0f, 0.5f), new Vector2(0f, 0.5f), new Vector2(80f, 0f), new Vector2(110f, 60f), false); + var p = UiKit.Rect("Pill" + i, barRoot, new Vector2(0f, 0.5f), new Vector2(0f, 0.5f), new Vector2(18f + i * (w + 18f), 0f), new Vector2(w, 84f)); + UiKit.Skin(p, "pill", UISkin.Col("pill", new Color(0.27f, 0.21f, 0.18f))); + UiKit.IconOrDot(p, icon, mark, c, new Vector2(0f, 0.5f), new Vector2(0f, 0.5f), new Vector2(-4f, 0f), 76f); + var n = UiKit.Label(p, name, 26, UISkin.Col("bar_text_off", new Color(0.85f, 0.8f, 0.75f)), TextAnchor.MiddleLeft, new Vector2(0f, 0.5f), new Vector2(0f, 0.5f), new Vector2(80f, 0f), new Vector2(110f, 60f), false); n.gameObject.name = "Name"; - var v = UiKit.Label(p.transform, "", 34, UiKit.White, TextAnchor.MiddleRight, new Vector2(1f, 0.5f), new Vector2(1f, 0.5f), new Vector2(-70f, 0f), new Vector2(170f, 60f)); + if (i != 2 && UISkin.Icon(icon) != null) n.text = ""; // 아이콘이 이름을 대신(군량 칸은 회복 타이머 자리) + var v = UiKit.Title(UiKit.Label(p, "", 36, UISkin.Col("bar_text", UiKit.White), TextAnchor.MiddleRight, new Vector2(1f, 0.5f), new Vector2(1f, 0.5f), new Vector2(-70f, 0f), new Vector2(170f, 60f)), true); v.horizontalOverflow = HorizontalWrapMode.Overflow; - UiKit.Btn("Plus", p.transform, "+", 40, new Color(0.42f, 0.35f, 0.31f), UiKit.White, new Vector2(1f, 0.5f), new Vector2(1f, 0.5f), new Vector2(-8f, 0f), new Vector2(56f, 56f), plus); + if (UISkin.Has("plus")) + { + var pb = UiKit.Rect("Plus", p, new Vector2(1f, 0.5f), new Vector2(1f, 0.5f), new Vector2(-6f, 0f), new Vector2(60f, 62f)); + UiKit.Skin(pb, "plus", Color.white, true); + pb.gameObject.AddComponent