Compare commits

...

3 Commits

Author SHA1 Message Date
HaeinLEE
c2250c28bf [Feat] 드래그 애니메이션 추가 2025-05-06 03:09:43 +09:00
HaeinLEE
a40902a5de [Feat] 튜토리얼 애니메이션 생성 2025-05-05 21:40:47 +09:00
HaeinLEE
f991e82fa9 [Style] 폴더 정리 2025-05-02 18:42:05 +09:00
75 changed files with 642 additions and 360 deletions

View File

@ -1,5 +1,5 @@
fileFormatVersion: 2
guid: 18265c81aaa1344439d5501a08b7a633
guid: dba2935d28b61d24cb995b4b892247b9
folderAsset: yes
DefaultImporter:
externalObjects: {}

BIN
Assets/LIN/Animations/Drag Down Animation.anim (Stored with Git LFS) Normal file

Binary file not shown.

View File

@ -1,8 +1,8 @@
fileFormatVersion: 2
guid: 83b9fc17fee6d884fb0c4ea5fc25e175
guid: f27b3abad6872c44e97912eebec8d88f
NativeFormatImporter:
externalObjects: {}
mainObjectFileID: 11400000
mainObjectFileID: 7400000
userData:
assetBundleName:
assetBundleVariant:

BIN
Assets/LIN/Animations/Drag Left Animation.anim (Stored with Git LFS) Normal file

Binary file not shown.

View File

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 1508ea9e5623cf14ab2378f0cef9e4f9
NativeFormatImporter:
externalObjects: {}
mainObjectFileID: 7400000
userData:
assetBundleName:
assetBundleVariant:

BIN
Assets/LIN/Animations/Drag Right Animation.anim (Stored with Git LFS) Normal file

Binary file not shown.

View File

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 8702846e8ccd4b34e9e500d748366282
NativeFormatImporter:
externalObjects: {}
mainObjectFileID: 7400000
userData:
assetBundleName:
assetBundleVariant:

BIN
Assets/LIN/Animations/Drag Up Animation.anim (Stored with Git LFS) Normal file

Binary file not shown.

View File

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 8731d87063872e443b687cb8fde04d4d
NativeFormatImporter:
externalObjects: {}
mainObjectFileID: 7400000
userData:
assetBundleName:
assetBundleVariant:

BIN
Assets/LIN/Animations/Finger Animator Controller.controller (Stored with Git LFS) Normal file

Binary file not shown.

View File

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: e9f04be805588144f91257ba68a51876
NativeFormatImporter:
externalObjects: {}
mainObjectFileID: 9100000
userData:
assetBundleName:
assetBundleVariant:

BIN
Assets/LIN/Animations/FingerImage.controller (Stored with Git LFS) Normal file

Binary file not shown.

View File

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 5905112edad17434fb13083581ef0f4f
NativeFormatImporter:
externalObjects: {}
mainObjectFileID: 9100000
userData:
assetBundleName:
assetBundleVariant:

BIN
Assets/LIN/Animations/Touch Animation.anim (Stored with Git LFS) Normal file

Binary file not shown.

View File

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: cd99c947dee3d52458ca54e58f038438
NativeFormatImporter:
externalObjects: {}
mainObjectFileID: 7400000
userData:
assetBundleName:
assetBundleVariant:

BIN
Assets/LIN/Housing Copy.unity (Stored with Git LFS)

Binary file not shown.

BIN
Assets/LIN/Prefabs/Player.prefab (Stored with Git LFS)

Binary file not shown.

BIN
Assets/LIN/Prefabs/TutorialExamplePanel.prefab (Stored with Git LFS) Normal file

Binary file not shown.

View File

@ -1,5 +1,5 @@
fileFormatVersion: 2
guid: 0a190a5b9816abf478788174c2c55c62
guid: b916de1e6eb0c5542884194f24ef6b1d
PrefabImporter:
externalObjects: {}
userData:

View File

@ -0,0 +1,37 @@
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public enum fingerAnimationType
{
None = 0,
Touch = 1,
DragUp = 2,
DragDown = 3,
DragRight = 4,
DragLeft = 5,
}
[RequireComponent(typeof(Animator))]
public class FingerAnimationController : MonoBehaviour
{
private static readonly int AnimationType = Animator.StringToHash("AnimationType");
public fingerAnimationType fingerAnimationType = fingerAnimationType.None;
private Animator animator;
private int _animType;
private void Awake()
{
animator = GetComponent<Animator>();
animator.SetInteger(AnimationType,(int)fingerAnimationType);
}
private void Update()
{
if ((int)fingerAnimationType == animator.GetInteger(AnimationType))
{
return;
}
animator.SetInteger(AnimationType,(int)fingerAnimationType);
}
}

View File

@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: aebdd610e1140f644acb596cc9acec39
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View File

@ -1,53 +0,0 @@
%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: b22d834cf5e26e647be215074940d40e, type: 3}
m_Name: FirstTutorialStep
m_EditorClassIdentifier:
message: "\uD29C\uD1A0\uB9AC\uC5BC\uC744 \uC2DC\uC791\uD569\uB2C8\uB2E4.\n2\uCD08
\uB4A4 \uC790\uB3D9\uC73C\uB85C \uC0AC\uB77C\uC9C0\uB294 \uBA54\uC138\uC9C0\uC785\uB2C8\uB2E4."
onBegin:
m_PersistentCalls:
m_Calls:
- m_Target: {fileID: -3457973789329276246, guid: 7d3bc5ecd8c87f64f8a9e137674ee021,
type: 3}
m_TargetAssemblyTypeName: TutorialPlayerController, Assembly-CSharp
m_MethodName: Show
m_Mode: 1
m_Arguments:
m_ObjectArgument: {fileID: 0}
m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine
m_IntArgument: 0
m_FloatArgument: 0
m_StringArgument:
m_BoolArgument: 0
m_CallState: 2
onComplete:
m_PersistentCalls:
m_Calls:
- m_Target: {fileID: -3457973789329276246, guid: 7d3bc5ecd8c87f64f8a9e137674ee021,
type: 3}
m_TargetAssemblyTypeName: TutorialPlayerController, Assembly-CSharp
m_MethodName: Hide
m_Mode: 1
m_Arguments:
m_ObjectArgument: {fileID: 0}
m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine
m_IntArgument: 0
m_FloatArgument: 0
m_StringArgument:
m_BoolArgument: 0
m_CallState: 2
timeout: 2
requiredKey: 0
touchTargetIndex: -1
deactiveObjectIndex: -1
nextStep: {fileID: 11400000, guid: a6f10decfc8504843b358ab8893c01f7, type: 2}

View File

@ -1,79 +0,0 @@
%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: b22d834cf5e26e647be215074940d40e, type: 3}
m_Name: LastTutorialStep
m_EditorClassIdentifier:
message: "\uC9C0\uAE08 \uD654\uBA74\uC740 \uC544\uBB34\uB370\uB098 \uD074\uB9AD\uD558\uBA74
\uC5C6\uC5B4\uC9D1\uB2C8\uB2E4."
onBegin:
m_PersistentCalls:
m_Calls:
- m_Target: {fileID: 7187599994600413992, guid: 4d761fd80ffc7504cbfe46a9d52a46ef,
type: 3}
m_TargetAssemblyTypeName: JpystickTutorial, Assembly-CSharp
m_MethodName: Show
m_Mode: 1
m_Arguments:
m_ObjectArgument: {fileID: 0}
m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine
m_IntArgument: 0
m_FloatArgument: 0
m_StringArgument:
m_BoolArgument: 0
m_CallState: 2
- m_Target: {fileID: 3325711598849128996, guid: 391f578e16d4f7b43be150d5cb852323,
type: 3}
m_TargetAssemblyTypeName: TutorialAnimPanelController, Assembly-CSharp
m_MethodName: Show
m_Mode: 1
m_Arguments:
m_ObjectArgument: {fileID: 0}
m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine
m_IntArgument: 0
m_FloatArgument: 0
m_StringArgument:
m_BoolArgument: 0
m_CallState: 2
onComplete:
m_PersistentCalls:
m_Calls:
- m_Target: {fileID: 7187599994600413992, guid: 4d761fd80ffc7504cbfe46a9d52a46ef,
type: 3}
m_TargetAssemblyTypeName: JpystickTutorial, Assembly-CSharp
m_MethodName: Hide
m_Mode: 1
m_Arguments:
m_ObjectArgument: {fileID: 0}
m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine
m_IntArgument: 0
m_FloatArgument: 0
m_StringArgument:
m_BoolArgument: 0
m_CallState: 2
- m_Target: {fileID: 3325711598849128996, guid: 391f578e16d4f7b43be150d5cb852323,
type: 3}
m_TargetAssemblyTypeName: TutorialAnimPanelController, Assembly-CSharp
m_MethodName: Hide
m_Mode: 1
m_Arguments:
m_ObjectArgument: {fileID: 0}
m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine
m_IntArgument: 0
m_FloatArgument: 0
m_StringArgument:
m_BoolArgument: 0
m_CallState: 2
timeout: 0
requiredKey: 323
touchTargetIndex: -1
deactiveObjectIndex: -1
nextStep: {fileID: 0}

View File

@ -0,0 +1,15 @@
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
[RequireComponent(typeof(InteractionAnimationPanelController))]
public class PanelTmpController : MonoBehaviour
{
InteractionAnimationPanelController interactionAnimationPanelController;
private void Awake()
{
interactionAnimationPanelController = GetComponent<InteractionAnimationPanelController>();
interactionAnimationPanelController.TutorialSleepAnimation();
}
}

View File

@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: 11e12f4334717874d87ff58d5053e430
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View File

@ -1,81 +0,0 @@
%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: b22d834cf5e26e647be215074940d40e, type: 3}
m_Name: SecondTutorialStep
m_EditorClassIdentifier:
message: "\uC67C\uCABD \uC544\uB798 \uC870\uC774\uC2A4\uD2F1\uC744 \uC704\uB85C
\uB4DC\uB798\uADF8 \uD574\uBCF4\uC138\uC694.\n\uD574\uB2F9 \uC704\uCE58\uC5D0
\uBE68\uAC04 \uC778\uB514\uCF00\uC774\uD130 \uC560\uB2C8\uBA54\uC774\uC158\uC744
\uC7AC\uC0DD\uC911\uC785\uB2C8\uB2E4."
onBegin:
m_PersistentCalls:
m_Calls:
- m_Target: {fileID: 3325711598849128996, guid: bb56cf86788033f41ae91bd4bc593044,
type: 3}
m_TargetAssemblyTypeName: TutorialAnimPanelController, Assembly-CSharp
m_MethodName: Show
m_Mode: 1
m_Arguments:
m_ObjectArgument: {fileID: 0}
m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine
m_IntArgument: 0
m_FloatArgument: 0
m_StringArgument:
m_BoolArgument: 0
m_CallState: 2
- m_Target: {fileID: -3457973789329276246, guid: 7d3bc5ecd8c87f64f8a9e137674ee021,
type: 3}
m_TargetAssemblyTypeName: TutorialPlayerController, Assembly-CSharp
m_MethodName: Show
m_Mode: 1
m_Arguments:
m_ObjectArgument: {fileID: 0}
m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine
m_IntArgument: 0
m_FloatArgument: 0
m_StringArgument:
m_BoolArgument: 0
m_CallState: 2
onComplete:
m_PersistentCalls:
m_Calls:
- m_Target: {fileID: 3325711598849128996, guid: bb56cf86788033f41ae91bd4bc593044,
type: 3}
m_TargetAssemblyTypeName: TutorialAnimPanelController, Assembly-CSharp
m_MethodName: Hide
m_Mode: 1
m_Arguments:
m_ObjectArgument: {fileID: 0}
m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine
m_IntArgument: 0
m_FloatArgument: 0
m_StringArgument:
m_BoolArgument: 0
m_CallState: 2
- m_Target: {fileID: -3457973789329276246, guid: 7d3bc5ecd8c87f64f8a9e137674ee021,
type: 3}
m_TargetAssemblyTypeName: TutorialPlayerController, Assembly-CSharp
m_MethodName: Hide
m_Mode: 1
m_Arguments:
m_ObjectArgument: {fileID: 0}
m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine
m_IntArgument: 0
m_FloatArgument: 0
m_StringArgument:
m_BoolArgument: 0
m_CallState: 2
timeout: 0
requiredKey: 0
touchTargetIndex: 0
deactiveObjectIndex: 0
nextStep: {fileID: 11400000, guid: c25f773b8e1446d45837ee656d510061, type: 2}

View File

@ -1,66 +0,0 @@
%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: b22d834cf5e26e647be215074940d40e, type: 3}
m_Name: ThirdTutorialStep
m_EditorClassIdentifier:
message: "\uAC00\uC9DC \uC870\uC774\uC2A4\uD2F1 \uBC29\uD5A5\uB300\uB85C \uC9C1\uC9C4\uD569\uB2C8\uB2E4..
\uBC29\uD5A5 \uC81C\uD55C\uD560 \uC544\uC774\uB514\uC5B4 \uAD6C\uD574\uC694.."
onBegin:
m_PersistentCalls:
m_Calls:
- m_Target: {fileID: 6973777276245600638, guid: ac48046581f0206449e480caaee1ae59,
type: 3}
m_TargetAssemblyTypeName: FowardFixedJoystickController, Assembly-CSharp
m_MethodName: Show
m_Mode: 1
m_Arguments:
m_ObjectArgument: {fileID: 0}
m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine
m_IntArgument: 0
m_FloatArgument: 0
m_StringArgument:
m_BoolArgument: 0
m_CallState: 2
- m_Target: {fileID: -3457973789329276246, guid: 29492c975fd1aaa40903e821b69daa29,
type: 3}
m_TargetAssemblyTypeName: TutorialPlayerController, Assembly-CSharp
m_MethodName: Show
m_Mode: 1
m_Arguments:
m_ObjectArgument: {fileID: 0}
m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine
m_IntArgument: 0
m_FloatArgument: 0
m_StringArgument:
m_BoolArgument: 0
m_CallState: 2
onComplete:
m_PersistentCalls:
m_Calls:
- m_Target: {fileID: 6973777276245600638, guid: ac48046581f0206449e480caaee1ae59,
type: 3}
m_TargetAssemblyTypeName: FowardFixedJoystickController, Assembly-CSharp
m_MethodName: Hide
m_Mode: 1
m_Arguments:
m_ObjectArgument: {fileID: 0}
m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine
m_IntArgument: 0
m_FloatArgument: 0
m_StringArgument:
m_BoolArgument: 0
m_CallState: 2
timeout: 2.3
requiredKey: 0
touchTargetIndex: -1
deactiveObjectIndex: 0
nextStep: {fileID: 11400000, guid: 3629cede21d4bb340924cd9b1d401bb9, type: 2}

View File

@ -3,35 +3,53 @@ using UnityEngine;
using TMPro;
using UnityEngine.UI;
using System.Collections;
using Unity.VisualScripting;
using UnityEngine.Serialization;
using UnityEngine.Events;
public class TutorialManager : MonoBehaviour
{
[SerializeField] private TutorialStep firstStep;
[SerializeField] private CanvasGroup overlay; // 입력 차단 & 다크닝용
[SerializeField] private TMP_Text tutorialText;
[SerializeField] private Canvas overlayCanvas; // RectTransformUtility를 위한 Canvas
// [SerializeField] private GameObject housingUICanvas; //튜토리얼 동안 입력 제한
[SerializeField] private TutorialStep firstStep; // 인스펙터에서 첫 단계 드래그
[Header("튜토리얼 패널 생성")]
[SerializeField] private GameObject[] tutorialPanelPrefabs;
[FormerlySerializedAs("parentObject")] public Canvas parentCanvas;
private GameObject _tutorialPanelObject;
private TutorialPanelController _tutorialPanelController;
[Header("튜토리얼 터치 타겟들")]
[SerializeField] private GameObject[] touchTargets;
[Header("감춰놓을 게임 오브젝트")]
[SerializeField] private GameObject[] lockTargets;
private Coroutine _runningCoroutine;
private CanvasGroup overlay; // 화면 암전 및 입력 차단
private RectTransform targetRt;
public void Start()
private Canvas overlayCanvas; // RectTransformUtility를 위한 Canvas
private Action onTutorialComplete;
public void Start( )
{
StartTutorial();
StartTutorial(null);
}
public void StartTutorial(Action onTutorialEnd, int panelIndex = 0)
{
if(parentCanvas == null)
parentCanvas = FindObjectOfType(typeof(Canvas)) as Canvas;
if (parentCanvas != null)
{
overlayCanvas = parentCanvas as Canvas;
_tutorialPanelObject = Instantiate(tutorialPanelPrefabs[panelIndex], parentCanvas.GameObject().transform);
overlay = _tutorialPanelObject.GetComponent<CanvasGroup>();
_tutorialPanelController = _tutorialPanelObject.GetComponent<TutorialPanelController>();
}
public void StartTutorial()
{
overlay.gameObject.SetActive(true);
if (_tutorialPanelController != null)
{
onTutorialComplete = onTutorialEnd;
overlay.alpha = 1f;
overlay.blocksRaycasts = true;
RunStep(firstStep);
}
else Debug.Log("패널 생성 실패, 튜토리얼 진행이 불가능합니다.");
}
private void RunStep(TutorialStep step)
@ -43,30 +61,30 @@ public class TutorialManager : MonoBehaviour
private IEnumerator RunStepCoroutine(TutorialStep step)
{
// 단계 시작 이벤트
step.onBegin?.Invoke();
step.onStepBegin?.Invoke();
// 메시지 갱신
tutorialText.text = step.message;
_tutorialPanelController.setTutorialText(step.message);
float elapsed = 0f;
bool done = false;
bool done = false;
//터치해야 할 위치가 있는지 체크
if (step.touchTargetIndex >= 0)
{
targetRt = touchTargets[step.touchTargetIndex].GetComponent<RectTransform>();
touchTargets[step.touchTargetIndex].SetActive(true);
_tutorialPanelController.ShowTouchTarget(step.touchTargetIndex);
targetRt = _tutorialPanelController.touchTargets[step.touchTargetIndex].GetComponent<RectTransform>();
}
//화면에서 숨겨야 할 요소가 있는지 체크
if (step.deactiveObjectIndex >= 0)
if (step.imageIndex >= 0)
{
lockTargets[step.deactiveObjectIndex].SetActive(false);
_tutorialPanelController.ShowImage(step.imageIndex);
}
while (!done)
{
{
// 1) 영역 터치 체크
if (targetRt != null)
{
{
// 클릭 또는 터치 이벤트
bool pressed = Input.GetMouseButtonDown(0) || Input.touchCount > 0;
if (pressed)
@ -81,11 +99,7 @@ public class TutorialManager : MonoBehaviour
{
Debug.Log("타겟 터치");
targetRt = null;
touchTargets[step.touchTargetIndex].SetActive(false);
if (step.deactiveObjectIndex >= 0)
{
lockTargets[step.deactiveObjectIndex].SetActive(true);
}
_tutorialPanelController.HideTouchTarget(step.touchTargetIndex);
done = true;
}
else
@ -94,23 +108,23 @@ public class TutorialManager : MonoBehaviour
}
}
}
// 타임아웃 체크
if (step.timeout > 0f && elapsed >= step.timeout)
done = true;
// 키 입력 체크
if (step.requiredKey != KeyCode.None && Input.GetKeyDown(step.requiredKey))
done = true;
elapsed += Time.deltaTime;
yield return null;
}
// 단계 완료 이벤트
step.onComplete?.Invoke();
step.onStepComplete?.Invoke();
if (step.imageIndex >= 0)
{
_tutorialPanelController.HideImage(step.imageIndex);
}
// 다음 단계로
if (step.nextStep != null)
RunStep(step.nextStep);
@ -120,8 +134,19 @@ public class TutorialManager : MonoBehaviour
private void EndTutorial()
{
tutorialText.text = "";
_tutorialPanelController.setTutorialText("");
overlay.alpha = 0f;
overlay.blocksRaycasts = false;
if(onTutorialComplete!=null)
{
onTutorialComplete?.Invoke();
onTutorialComplete = null;
}
if (_tutorialPanelObject == null)
return;
Destroy(_tutorialPanelObject);
_tutorialPanelController = null;
}
}

View File

@ -0,0 +1,42 @@
using System.Collections;
using System.Collections.Generic;
using TMPro;
using UnityEngine;
[RequireComponent(typeof(CanvasGroup))]
public class TutorialPanelController : MonoBehaviour
{
[SerializeField] private TMP_Text tutorialText;
[Header("튜토리얼 터치 타겟들")]
[SerializeField]
public GameObject[] touchTargets;
[Header("튜토리얼에서 보여줄 이미지 혹은 판넬들")]
[SerializeField] private GameObject[] images;
public void setTutorialText(string tutorialText)
{
this.tutorialText.text = tutorialText;
}
//TODO:RangeCheck
public void ShowTouchTarget(int index)
{
touchTargets[index].SetActive(true);
}
public void HideTouchTarget(int index)
{
touchTargets[index].SetActive(false);
}
public void ShowImage(int index)
{
images[index].SetActive(true);
}
public void HideImage(int index)
{
images[index].SetActive(false);
}
}

View File

@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: 50f463251502b134d9b627d30c30842b
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View File

@ -1,22 +1,24 @@
// TutorialStep.cs
using UnityEngine;
using UnityEngine.Events;
using UnityEngine.Serialization;
[CreateAssetMenu(fileName = "TutorialStep", menuName = "Tutorial/Tutorial Step")]
public class TutorialStep : ScriptableObject
{
[TextArea(2, 5)]
public string message; // 플레이어에게 보여줄 텍스트
public UnityEvent onBegin; // 단계 시작 시 추가로 실행할 이벤트
public UnityEvent onComplete; // 단계 완료 시 실행할 이벤트
public float timeout = 0f; // 0 이상이면 이 시간 경과 후 자동 완료
public KeyCode requiredKey = KeyCode.None; // 지정 Key 입력 시 완료
public float timeout = 2f; // 0 이상이면 이 시간 경과 후 자동 완료
[Tooltip("터치해야 할 위치가 있다면, 게임매니저에게 인덱스 전달")]
[Tooltip("단계별로 시작, 완료시 추가로 실행할 이벤트")]
public UnityEvent onStepBegin; // 단계 시작 시 추가로 실행할 이벤트
public UnityEvent onStepComplete; // 단계 완료 시 실행할 이벤트
[Tooltip("터치해야 할 위치가 있다면, 튜토리얼 매니저에게 인덱스 전달")]
public int touchTargetIndex=-1;
[Tooltip("배경캔버스에서 끌 오브젝트 인덱스 전달")]
public int deactiveObjectIndex=-1;
[Tooltip("보여줄 이미지가 있다면, 튜토리얼 매니저에게 인덱스 전달")]
public int imageIndex=-1;
[Tooltip("다음 단계로 넘어갈 TutorialStep, null이면 튜토리얼 종료")]
public TutorialStep nextStep;

View File

@ -0,0 +1,26 @@
%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: b22d834cf5e26e647be215074940d40e, type: 3}
m_Name: TutorialStep1
m_EditorClassIdentifier:
message: "\uC9D1\uC5D0\uC11C\uB3C4 \uC2AC\uB77C\uC774\uB354\uB97C \uC870\uC791\uD574
\uCE90\uB9AD\uD130\uB97C \uC6C0\uC9C1\uC77C \uC218 \uC788\uC2B5\uB2C8\uB2E4."
timeout: 0
onStepBegin:
m_PersistentCalls:
m_Calls: []
onStepComplete:
m_PersistentCalls:
m_Calls: []
touchTargetIndex: 0
imageIndex: -1
nextStep: {fileID: 11400000, guid: a6f10decfc8504843b358ab8893c01f7, type: 2}

View File

@ -0,0 +1,27 @@
%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: b22d834cf5e26e647be215074940d40e, type: 3}
m_Name: TutorialStep2
m_EditorClassIdentifier:
message: "\uCE68\uB300, \uB0C9\uC7A5\uACE0, \uD604\uAD00 \uADF8\uB9AC\uACE0 \uC8FC\uBC29\uC5D0
\uAC00\uAE4C\uC774 \uAC00\uBA74 \uADF8\uC5D0 \uC5B4\uC6B8\uB9AC\uB294 \uC0C1\uD638\uC791\uC6A9\uC744
\uD560 \uC218 \uC788\uC2B5\uB2C8\uB2E4."
timeout: 0
onStepBegin:
m_PersistentCalls:
m_Calls: []
onStepComplete:
m_PersistentCalls:
m_Calls: []
touchTargetIndex: 1
imageIndex: -1
nextStep: {fileID: 11400000, guid: c25f773b8e1446d45837ee656d510061, type: 2}

View File

@ -10,16 +10,16 @@ MonoBehaviour:
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: b22d834cf5e26e647be215074940d40e, type: 3}
m_Name: FirstTutorialStep
m_Name: TutorialStep3
m_EditorClassIdentifier:
message: Let's begin tutorial. First, touch next button.
onBegin:
m_PersistentCalls:
m_Calls: []
onComplete:
m_PersistentCalls:
m_Calls: []
message: "\uC0C1\uD638\uC791\uC6A9 \uBC84\uD2BC\uC744 \uB20C\uB7EC \uBCF4\uC138\uC694"
timeout: 0
requiredKey: 0
touchTargetIndex: 0
nextStep: {fileID: 11400000, guid: 83b9fc17fee6d884fb0c4ea5fc25e175, type: 2}
onStepBegin:
m_PersistentCalls:
m_Calls: []
onStepComplete:
m_PersistentCalls:
m_Calls: []
touchTargetIndex: 2
imageIndex: 0
nextStep: {fileID: 11400000, guid: 3629cede21d4bb340924cd9b1d401bb9, type: 2}

View File

@ -10,16 +10,16 @@ MonoBehaviour:
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: b22d834cf5e26e647be215074940d40e, type: 3}
m_Name: SecondTutorialStep
m_Name: TutorialStep4
m_EditorClassIdentifier:
message: Well done, now then touch the button which has round shape
onBegin:
message:
timeout: 2
onStepBegin:
m_PersistentCalls:
m_Calls: []
onComplete:
onStepComplete:
m_PersistentCalls:
m_Calls: []
timeout: 0
requiredKey: 0
touchTargetIndex: 1
nextStep: {fileID: 0}
touchTargetIndex: -1
imageIndex: 1
nextStep: {fileID: 11400000, guid: e3d4da4e50044c54394663ac9e7b2afa, type: 2}

View File

@ -0,0 +1,26 @@
%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: b22d834cf5e26e647be215074940d40e, type: 3}
m_Name: TutorialStep5
m_EditorClassIdentifier:
message: "\uB2E4\uC591\uD55C \uC0C1\uD638\uC791\uC6A9\uC744 \uD1B5\uD574 \uB2A5\uB825\uCE58\uB97C
\uC62C\uB9AC\uACE0 \uB358\uC804\uC744 \uACF5\uB7B5\uD574\uBCF4\uC138\uC694."
timeout: 0
onStepBegin:
m_PersistentCalls:
m_Calls: []
onStepComplete:
m_PersistentCalls:
m_Calls: []
touchTargetIndex: 1
imageIndex: -1
nextStep: {fileID: 0}

View File

@ -1,5 +1,5 @@
fileFormatVersion: 2
guid: a7cedb06e57fff540a2335f42ac38e2c
guid: e3d4da4e50044c54394663ac9e7b2afa
NativeFormatImporter:
externalObjects: {}
mainObjectFileID: 11400000

View File

@ -16,6 +16,7 @@ public class InteractionAnimationPanelController : MonoBehaviour
private Coroutine _textAnimCoroutine;
private Coroutine _autoHideCoroutine;
private Canvas _parentCanvas;
public void SetDoingText(string text)
{
@ -102,5 +103,13 @@ public class InteractionAnimationPanelController : MonoBehaviour
_autoHideCoroutine = null;
}
}
public void TutorialSleepAnimation()
{
_parentCanvas = FindObjectOfType(typeof(Canvas)) as Canvas;
HousingConstants.interactions.TryGetValue(ActionType.Sleep, out var interactionTexts);
ShowAnimationPanel(ActionType.Sleep, interactionTexts.AnimationText);
}
}

8
Assets/LIN/Sprites.meta Normal file
View File

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 7406a965318c4c54790e003c4852dee7
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

BIN
Assets/LIN/Sprites/Finger.png (Stored with Git LFS) Normal file

Binary file not shown.

View File

@ -0,0 +1,114 @@
fileFormatVersion: 2
guid: c7de568cd24a02446b221be0785f87f3
TextureImporter:
internalIDToNameTable: []
externalObjects: {}
serializedVersion: 13
mipmaps:
mipMapMode: 0
enableMipMap: 0
sRGBTexture: 1
linearTexture: 0
fadeOut: 0
borderMipMap: 0
mipMapsPreserveCoverage: 0
alphaTestReferenceValue: 0.5
mipMapFadeDistanceStart: 1
mipMapFadeDistanceEnd: 3
bumpmap:
convertToNormalMap: 0
externalNormalMap: 0
heightScale: 0.25
normalMapFilter: 0
flipGreenChannel: 0
isReadable: 0
streamingMipmaps: 0
streamingMipmapsPriority: 0
vTOnly: 0
ignoreMipmapLimit: 0
grayScaleToAlpha: 0
generateCubemap: 6
cubemapConvolution: 0
seamlessCubemap: 0
textureFormat: 1
maxTextureSize: 2048
textureSettings:
serializedVersion: 2
filterMode: 1
aniso: 1
mipBias: 0
wrapU: 1
wrapV: 1
wrapW: 0
nPOTScale: 0
lightmap: 0
compressionQuality: 50
spriteMode: 1
spriteExtrude: 1
spriteMeshType: 1
alignment: 0
spritePivot: {x: 0.5, y: 0.5}
spritePixelsToUnits: 100
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
spriteGenerateFallbackPhysicsShape: 1
alphaUsage: 1
alphaIsTransparency: 1
spriteTessellationDetail: -1
textureType: 8
textureShape: 1
singleChannelComponent: 0
flipbookRows: 1
flipbookColumns: 1
maxTextureSizeSet: 0
compressionQualitySet: 0
textureFormatSet: 0
ignorePngGamma: 0
applyGammaDecoding: 0
swizzle: 50462976
cookieLightType: 0
platformSettings:
- serializedVersion: 3
buildTarget: DefaultTexturePlatform
maxTextureSize: 2048
resizeAlgorithm: 0
textureFormat: -1
textureCompression: 1
compressionQuality: 50
crunchedCompression: 0
allowsAlphaSplitting: 0
overridden: 0
ignorePlatformSupport: 0
androidETC2FallbackOverride: 0
forceMaximumCompressionQuality_BC6H_BC7: 0
- serializedVersion: 3
buildTarget: Standalone
maxTextureSize: 2048
resizeAlgorithm: 0
textureFormat: -1
textureCompression: 1
compressionQuality: 50
crunchedCompression: 0
allowsAlphaSplitting: 0
overridden: 0
ignorePlatformSupport: 0
androidETC2FallbackOverride: 0
forceMaximumCompressionQuality_BC6H_BC7: 0
spriteSheet:
serializedVersion: 2
sprites: []
outline: []
physicsShape: []
bones: []
spriteID: 5e97eb03825dee720800000000000000
internalID: 0
vertices: []
indices:
edges: []
weights: []
secondaryTextures: []
nameFileIdTable: {}
mipmapLimitGroupName:
pSDRemoveMatte: 0
userData:
assetBundleName:
assetBundleVariant:

BIN
Assets/LIN/Sprites/FridgeDungeonUI.png (Stored with Git LFS) Normal file

Binary file not shown.

View File

@ -0,0 +1,114 @@
fileFormatVersion: 2
guid: b8c9a96772b117744ad2781240f3f8f9
TextureImporter:
internalIDToNameTable: []
externalObjects: {}
serializedVersion: 13
mipmaps:
mipMapMode: 0
enableMipMap: 1
sRGBTexture: 1
linearTexture: 0
fadeOut: 0
borderMipMap: 0
mipMapsPreserveCoverage: 0
alphaTestReferenceValue: 0.5
mipMapFadeDistanceStart: 1
mipMapFadeDistanceEnd: 3
bumpmap:
convertToNormalMap: 0
externalNormalMap: 0
heightScale: 0.25
normalMapFilter: 0
flipGreenChannel: 0
isReadable: 0
streamingMipmaps: 0
streamingMipmapsPriority: 0
vTOnly: 0
ignoreMipmapLimit: 0
grayScaleToAlpha: 0
generateCubemap: 6
cubemapConvolution: 0
seamlessCubemap: 0
textureFormat: 1
maxTextureSize: 2048
textureSettings:
serializedVersion: 2
filterMode: 1
aniso: 1
mipBias: 0
wrapU: 0
wrapV: 0
wrapW: 0
nPOTScale: 1
lightmap: 0
compressionQuality: 50
spriteMode: 0
spriteExtrude: 1
spriteMeshType: 1
alignment: 0
spritePivot: {x: 0.5, y: 0.5}
spritePixelsToUnits: 100
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
spriteGenerateFallbackPhysicsShape: 1
alphaUsage: 1
alphaIsTransparency: 0
spriteTessellationDetail: -1
textureType: 0
textureShape: 1
singleChannelComponent: 0
flipbookRows: 1
flipbookColumns: 1
maxTextureSizeSet: 0
compressionQualitySet: 0
textureFormatSet: 0
ignorePngGamma: 0
applyGammaDecoding: 0
swizzle: 50462976
cookieLightType: 0
platformSettings:
- serializedVersion: 3
buildTarget: DefaultTexturePlatform
maxTextureSize: 2048
resizeAlgorithm: 0
textureFormat: -1
textureCompression: 1
compressionQuality: 50
crunchedCompression: 0
allowsAlphaSplitting: 0
overridden: 0
ignorePlatformSupport: 0
androidETC2FallbackOverride: 0
forceMaximumCompressionQuality_BC6H_BC7: 0
- serializedVersion: 3
buildTarget: Standalone
maxTextureSize: 2048
resizeAlgorithm: 0
textureFormat: -1
textureCompression: 1
compressionQuality: 50
crunchedCompression: 0
allowsAlphaSplitting: 0
overridden: 0
ignorePlatformSupport: 0
androidETC2FallbackOverride: 0
forceMaximumCompressionQuality_BC6H_BC7: 0
spriteSheet:
serializedVersion: 2
sprites: []
outline: []
physicsShape: []
bones: []
spriteID:
internalID: 0
vertices: []
indices:
edges: []
weights: []
secondaryTextures: []
nameFileIdTable: {}
mipmapLimitGroupName:
pSDRemoveMatte: 0
userData:
assetBundleName:
assetBundleVariant:

8
Assets/LIN/Tests.meta Normal file
View File

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 6468efabb5f9308459bd0e1662a3816f
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@ -70,7 +70,7 @@ Material:
- _OutlineSoftness: 0
- _OutlineUVSpeedX: 0
- _OutlineUVSpeedY: 0
- _OutlineWidth: 0
- _OutlineWidth: 0.3
- _PerspectiveFilter: 0.875
- _Reflectivity: 10
- _ScaleRatioA: 0.8