훔쳐보기

This commit is contained in:
Ino 2025-09-20 03:43:24 +09:00
parent f3e6b0b75c
commit e1015a713a
6 changed files with 150 additions and 77 deletions

View File

@ -10,9 +10,9 @@ public class ShowAlbum : MonoBehaviourSingletonTemplate<ShowAlbum>
m_ShowPanel.gameObject.SetActive(false);
}
public void Show<T>(T data)
public void Show<T>(T data, bool preview)
{
m_MainUICanvas.SetActive(false);
m_ShowPanel.Set(data, () => { m_MainUICanvas.SetActive(true); });
m_ShowPanel.Set(data, preview, () => { m_MainUICanvas.SetActive(true); });
}
}

View File

@ -310,7 +310,144 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: 8f6f656bf230b7a488b1a5c0763cbe6f, type: 3}
m_Name:
m_EditorClassIdentifier:
m_MainUICanvas: {fileID: 0}
m_ShowPanel: {fileID: 3645905085550438875}
--- !u!1 &4496871772968282525
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 4552201222623461871}
- component: {fileID: 5389900562015601476}
- component: {fileID: 5746505822520106488}
m_Layer: 5
m_Name: preview
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!224 &4552201222623461871
RectTransform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 4496871772968282525}
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_ConstrainProportionsScale: 0
m_Children: []
m_Father: {fileID: 4838641313505026441}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 1, y: 1}
m_AnchorMax: {x: 1, y: 1}
m_AnchoredPosition: {x: -122, y: 45}
m_SizeDelta: {x: 200, y: 50}
m_Pivot: {x: 0.5, y: 0.5}
--- !u!222 &5389900562015601476
CanvasRenderer:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 4496871772968282525}
m_CullTransparentMesh: 1
--- !u!114 &5746505822520106488
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 4496871772968282525}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: f4688fdb7df04437aeb418b961361dc5, type: 3}
m_Name:
m_EditorClassIdentifier:
m_Material: {fileID: 0}
m_Color: {r: 1, g: 1, b: 1, a: 1}
m_RaycastTarget: 0
m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0}
m_Maskable: 1
m_OnCullStateChanged:
m_PersistentCalls:
m_Calls: []
m_text: "\uD6D4\uCCD0\uBCF4\uAE30 \uC911..."
m_isRightToLeft: 0
m_fontAsset: {fileID: 11400000, guid: 3055b5c28f94e6c4ea6b9a379bb315a5, type: 2}
m_sharedMaterial: {fileID: 2100000, guid: f0e824099790d3445af94a5b86b5cc4a, type: 2}
m_fontSharedMaterials: []
m_fontMaterial: {fileID: 0}
m_fontMaterials: []
m_fontColor32:
serializedVersion: 2
rgba: 4294967295
m_fontColor: {r: 1, g: 1, b: 1, a: 1}
m_enableVertexGradient: 0
m_colorMode: 3
m_fontColorGradient:
topLeft: {r: 1, g: 1, b: 1, a: 1}
topRight: {r: 1, g: 1, b: 1, a: 1}
bottomLeft: {r: 1, g: 1, b: 1, a: 1}
bottomRight: {r: 1, g: 1, b: 1, a: 1}
m_fontColorGradientPreset: {fileID: 0}
m_spriteAsset: {fileID: 0}
m_tintAllSprites: 0
m_StyleSheet: {fileID: 0}
m_TextStyleHashCode: -1183493901
m_overrideHtmlColors: 0
m_faceColor:
serializedVersion: 2
rgba: 4294967295
m_fontSize: 50
m_fontSizeBase: 50
m_fontWeight: 400
m_enableAutoSizing: 0
m_fontSizeMin: 25
m_fontSizeMax: 100
m_fontStyle: 0
m_HorizontalAlignment: 4
m_VerticalAlignment: 4096
m_textAlignment: 65535
m_characterSpacing: 0
m_wordSpacing: 0
m_lineSpacing: 0
m_lineSpacingMax: 0
m_paragraphSpacing: 0
m_charWidthMaxAdj: 0
m_TextWrappingMode: 0
m_wordWrappingRatios: 0.4
m_overflowMode: 0
m_linkedTextComponent: {fileID: 0}
parentLinkedComponent: {fileID: 0}
m_enableKerning: 0
m_ActiveFontFeatures: 6e72656b
m_enableExtraPadding: 0
checkPaddingRequired: 0
m_isRichText: 1
m_EmojiFallbackSupport: 1
m_parseCtrlCharacters: 1
m_isOrthographic: 1
m_isCullingEnabled: 0
m_horizontalMapping: 0
m_verticalMapping: 0
m_uvLineOffset: 0
m_geometrySortingOrder: 0
m_IsTextObjectScaleStatic: 0
m_VertexBufferAutoSizeReduction: 0
m_useMaxVisibleDescender: 1
m_pageToDisplay: 1
m_margin: {x: 0, y: 0, z: 0, w: 0}
m_isUsingLegacyAnimationComponent: 0
m_isVolumetricText: 0
m_hasFontAssetChanged: 0
m_baseMaterial: {fileID: 0}
m_maskOffset: {x: 0, y: 0, z: 0, w: 0}
--- !u!1 &4682878790792817058
GameObject:
m_ObjectHideFlags: 0
@ -812,6 +949,7 @@ RectTransform:
m_ConstrainProportionsScale: 1
m_Children:
- {fileID: 182769047467059713}
- {fileID: 4552201222623461871}
m_Father: {fileID: 456846148437764429}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 0}
@ -871,6 +1009,7 @@ MonoBehaviour:
m_EditorClassIdentifier:
i_image: {fileID: 4592172516078748411}
go_btns: {fileID: 8461513849143437229}
go_preview: {fileID: 4496871772968282525}
isFull: 0
--- !u!1 &8755086048526332932
GameObject:

View File

@ -1,6 +1,5 @@
using System;
using UnityEngine;
using UnityEngine.AddressableAssets;
using UnityEngine.ResourceManagement.AsyncOperations;
public class ShowAlbumBase { public string s_Image; }
@ -8,7 +7,7 @@ public class ShowAlbumBase { public string s_Image; }
public class ShowPanel : MonoBehaviour
{
public SpriteRenderer i_image;
public GameObject go_btns;
public GameObject go_btns, go_preview;
public bool isFull;
int zoomStep = 0;
@ -16,13 +15,14 @@ public class ShowPanel : MonoBehaviour
float original_orthographicSize;
Action act_Close;
public void Set<T>(T data, Action actClose)
public void Set<T>(T data, bool preview, Action actClose)
{
act_Close = actClose;
ADInfo.Ins.Set_Banner(false);
gameObject.SetActive(true);
go_btns.SetActive(true);
go_preview.SetActive(preview);
i_image.enabled = false;
AddrResourceMgr.Ins.LoadObject<Sprite>((data as ShowAlbumBase).s_Image, handle =>

View File

@ -9807,7 +9807,7 @@ RectTransform:
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 180}
m_AnchorMin: {x: 0, y: 1}
m_AnchorMax: {x: 1, y: 1}
m_AnchoredPosition: {x: 0, y: -68.599976}
m_AnchoredPosition: {x: 0, y: -68.6001}
m_SizeDelta: {x: 0, y: 137.1}
m_Pivot: {x: 0.5, y: 0.5}
--- !u!114 &371721586
@ -48970,7 +48970,7 @@ RectTransform:
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 0}
m_AnchorMax: {x: 1, y: 1}
m_AnchoredPosition: {x: 0, y: -44.400024}
m_AnchoredPosition: {x: 0, y: -44.399902}
m_SizeDelta: {x: 0, y: -519.7}
m_Pivot: {x: 0.5, y: 0.5}
--- !u!114 &2093328781
@ -50811,38 +50811,6 @@ PrefabInstance:
serializedVersion: 3
m_TransformParent: {fileID: 0}
m_Modifications:
- target: {fileID: 2569134205668460253, guid: 97b8f0a8fdbe18e4f85c11c67c111688, type: 3}
propertyPath: m_AnchorMax.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 2569134205668460253, guid: 97b8f0a8fdbe18e4f85c11c67c111688, type: 3}
propertyPath: m_AnchorMin.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 2569134205668460253, guid: 97b8f0a8fdbe18e4f85c11c67c111688, type: 3}
propertyPath: m_AnchoredPosition.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 2569134205668460253, guid: 97b8f0a8fdbe18e4f85c11c67c111688, type: 3}
propertyPath: m_AnchoredPosition.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 3113117796968207641, guid: 97b8f0a8fdbe18e4f85c11c67c111688, type: 3}
propertyPath: m_AnchorMax.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 3113117796968207641, guid: 97b8f0a8fdbe18e4f85c11c67c111688, type: 3}
propertyPath: m_AnchorMin.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 3113117796968207641, guid: 97b8f0a8fdbe18e4f85c11c67c111688, type: 3}
propertyPath: m_AnchoredPosition.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 3113117796968207641, guid: 97b8f0a8fdbe18e4f85c11c67c111688, type: 3}
propertyPath: m_AnchoredPosition.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 3831263569033530073, guid: 97b8f0a8fdbe18e4f85c11c67c111688, type: 3}
propertyPath: m_MainUICanvas
value:
@ -50851,38 +50819,6 @@ PrefabInstance:
propertyPath: m_Name
value: ShowAlbum
objectReference: {fileID: 0}
- target: {fileID: 6606483948000639159, guid: 97b8f0a8fdbe18e4f85c11c67c111688, type: 3}
propertyPath: m_AnchorMax.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 6606483948000639159, guid: 97b8f0a8fdbe18e4f85c11c67c111688, type: 3}
propertyPath: m_AnchorMin.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 6606483948000639159, guid: 97b8f0a8fdbe18e4f85c11c67c111688, type: 3}
propertyPath: m_AnchoredPosition.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 6606483948000639159, guid: 97b8f0a8fdbe18e4f85c11c67c111688, type: 3}
propertyPath: m_AnchoredPosition.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 7286985885240280840, guid: 97b8f0a8fdbe18e4f85c11c67c111688, type: 3}
propertyPath: m_AnchorMax.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 7286985885240280840, guid: 97b8f0a8fdbe18e4f85c11c67c111688, type: 3}
propertyPath: m_AnchorMin.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 7286985885240280840, guid: 97b8f0a8fdbe18e4f85c11c67c111688, type: 3}
propertyPath: m_AnchoredPosition.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 7286985885240280840, guid: 97b8f0a8fdbe18e4f85c11c67c111688, type: 3}
propertyPath: m_AnchoredPosition.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 8404604730602711012, guid: 97b8f0a8fdbe18e4f85c11c67c111688, type: 3}
propertyPath: m_LocalPosition.x
value: 0
@ -50923,10 +50859,6 @@ PrefabInstance:
propertyPath: m_LocalEulerAnglesHint.z
value: 0
objectReference: {fileID: 0}
- target: {fileID: 8461513849143437229, guid: 97b8f0a8fdbe18e4f85c11c67c111688, type: 3}
propertyPath: m_IsActive
value: 0
objectReference: {fileID: 0}
m_RemovedComponents: []
m_RemovedGameObjects: []
m_AddedGameObjects: []

View File

@ -51,6 +51,6 @@ public class AlbumCard : CardBase
public void OnClick_Show()
{
if (IsObtain()) ShowAlbum.Ins.Show(m_Data);
if (IsObtain()) ShowAlbum.Ins.Show(m_Data, false);
}
}

View File

@ -52,7 +52,9 @@ public class ProfileCard : MonoBehaviour
{ // 훔쳐보기
ADInfo.Ins.Show_AD(false, () =>
{
var lst = table_album.Ins.Get_DataList(m_Data.n_GirlID);
var rdnData = lst[Random.Range(0, lst.Count)];
ShowAlbum.Ins.Show(rdnData, true);
});
}