본문 바로가기

개발일지/게임개발23

Unity 게임 개발 - 세이브 기능 현재 코기 엔진의 세이브 기능을 활용해서 세이브 창을 만들고 있다using System.Collections;using System.Collections.Generic;using UnityEngine;using MoreMountains.Tools;using UnityEngine.SceneManagement; [System.Serializable]public struct SerializableVector3{ public float x, y, z; public SerializableVector3(float x, float y, float z) { this.x = x; this.y = y; this.z = z; } public Serializa.. 2025. 5. 5.
유니티 Talk BackLogBar 개발 미연시와 같은 대화중 대화 기록을 저장하는 기능을 개발한다대화는 기본적으로 name, talk로 나누어져서 구성되어 있으며 이를 대화 박스가 받아들인다 using System;using System.Collections;using System.Collections.Generic;using UnityEngine;using TMPro;public class backLogBar : MonoBehaviour{ public TextMeshProUGUI nameText; public TextMeshProUGUI talkLogText; backLogBar(string name, string talkLog) { nameText.text = name; talkLogText... 2025. 4. 29.
Unity effect maker 제작 using System.Collections;using System.Collections.Generic;using UnityEngine;using UnityEngine.EventSystems;[System.Serializable]public class EffectPair{ public GameObject effect; public Vector3 position;}public class instanceEffect : MonoBehaviour{ public List effectPairs = new List(); public void InstanceEffect(int num) { var pair = effectPairs[num]; GameObject inst.. 2025. 4. 29.
유니티 3D 게임 개발 - 체력, 총알 수 UI 제작 이러한 형태의 일반 상태, 조준상태가 달라지는 UI를 만들어 보려 한다 우선 게임 창에서 작게 검은색 상자 UI를 만들어 준다 이렇게 플레이어를 따라다니는듯한 느낌을 줄 수 있다이제 여기에 플레이어가 조준을 하고 있는가에 따라서 각도 변화를 주기 위한 스크립트를 제작한다 public class PlayerUI : MonoBehaviour{ private PlayerMovement playerMovement; private RectTransform rectTransform; void Start() { playerMovement = GameObject.FindWithTag("Player").GetComponent(); rectTransform = gameObje.. 2024. 12. 4.