데이터 파이프라인 추가 및 수정 + 크립 및 크립 캠프 배치 자동화
Hierachy > System > MapGenerator 에서 크립 관련 변수 설정 가능 Kaykit PlantWarrior 애셋 추가
This commit is contained in:
37
Assets/Data/Scripts/DataClasses/CreepData.cs
Normal file
37
Assets/Data/Scripts/DataClasses/CreepData.cs
Normal file
@@ -0,0 +1,37 @@
|
||||
// 이 파일은 자동 생성되었습니다. 직접 수정하지 마세요!
|
||||
// 생성 스크립트: DataTools/generate_csharp_classes.py
|
||||
|
||||
using UnityEngine;
|
||||
using System.Collections.Generic; // 리스트 지원을 위해 추가
|
||||
|
||||
namespace Northbound.Data
|
||||
{
|
||||
[CreateAssetMenu(fileName = "CreepData", menuName = "Northbound/Creep Data")]
|
||||
public partial class CreepData : ScriptableObject
|
||||
{
|
||||
[Header("기본 정보")]
|
||||
/// <summary>고유 ID</summary>
|
||||
public int id;
|
||||
/// <summary>기획 메모</summary>
|
||||
public string memo;
|
||||
/// <summary>이동 속도</summary>
|
||||
public float moveSpeed;
|
||||
/// <summary>체력</summary>
|
||||
public int maxHp;
|
||||
/// <summary>사정 거리</summary>
|
||||
public int atkRange;
|
||||
/// <summary>데미지</summary>
|
||||
public int atkDamage;
|
||||
/// <summary>공격 주기</summary>
|
||||
public float atkIntervalSec;
|
||||
/// <summary>몬스터 난이도 점수</summary>
|
||||
public int cost;
|
||||
/// <summary>등장 가중치</summary>
|
||||
public float weight;
|
||||
/// <summary>사용할 모델의 경로</summary>
|
||||
public string modelPath;
|
||||
/// <summary>사용할 애니메이션 컨트롤러의 경로</summary>
|
||||
public string animationControllerPath;
|
||||
|
||||
}
|
||||
}
|
||||
2
Assets/Data/Scripts/DataClasses/CreepData.cs.meta
Normal file
2
Assets/Data/Scripts/DataClasses/CreepData.cs.meta
Normal file
@@ -0,0 +1,2 @@
|
||||
fileFormatVersion: 2
|
||||
guid: f7bb664a82feb0e43b3c5f459ca775f7
|
||||
@@ -7,7 +7,7 @@ using System.Collections.Generic; // 리스트 지원을 위해 추가
|
||||
namespace Northbound.Data
|
||||
{
|
||||
[CreateAssetMenu(fileName = "DefaultSettingsData", menuName = "Northbound/DefaultSettings Data")]
|
||||
public class DefaultSettingsData : ScriptableObject
|
||||
public partial class DefaultSettingsData : ScriptableObject
|
||||
{
|
||||
[Header("기본 정보")]
|
||||
/// <summary>고유 ID</summary>
|
||||
|
||||
@@ -7,7 +7,7 @@ using System.Collections.Generic; // 리스트 지원을 위해 추가
|
||||
namespace Northbound.Data
|
||||
{
|
||||
[CreateAssetMenu(fileName = "MonsterData", menuName = "Northbound/Monster Data")]
|
||||
public class MonsterData : ScriptableObject
|
||||
public partial class MonsterData : ScriptableObject
|
||||
{
|
||||
[Header("기본 정보")]
|
||||
/// <summary>고유 ID</summary>
|
||||
|
||||
@@ -7,7 +7,7 @@ using System.Collections.Generic; // 리스트 지원을 위해 추가
|
||||
namespace Northbound.Data
|
||||
{
|
||||
[CreateAssetMenu(fileName = "PlayerData", menuName = "Northbound/Player Data")]
|
||||
public class PlayerData : ScriptableObject
|
||||
public partial class PlayerData : ScriptableObject
|
||||
{
|
||||
[Header("기본 정보")]
|
||||
/// <summary>고유 ID</summary>
|
||||
|
||||
@@ -1,83 +1,41 @@
|
||||
// 이 파일은 자동 생성되었습니다. 직접 수정하지 마세요!
|
||||
// 생성 스크립트: DataTools/generate_csharp_classes.py
|
||||
|
||||
using UnityEngine;
|
||||
using System.Collections.Generic; // 리스트 지원을 위해 추가
|
||||
|
||||
namespace Northbound.Data
|
||||
{
|
||||
[CreateAssetMenu(fileName = "TowerData", menuName = "Northbound/Tower Data")]
|
||||
public class TowerData : ScriptableObject
|
||||
public partial class TowerData : ScriptableObject
|
||||
{
|
||||
[Header("Building Info")]
|
||||
public string buildingName;
|
||||
public GameObject prefab;
|
||||
[Tooltip("UI에 표시될 건물 아이콘")]
|
||||
public Sprite icon;
|
||||
|
||||
[Header("Basic Info")]
|
||||
[Tooltip("고유 ID")]
|
||||
[Header("기본 정보")]
|
||||
/// <summary>고유 ID</summary>
|
||||
public int id;
|
||||
[Tooltip("기획 메모")]
|
||||
/// <summary>기획 메모</summary>
|
||||
public string memo;
|
||||
[Tooltip("건설 비용")]
|
||||
/// <summary>건물 이름</summary>
|
||||
public string buildingName;
|
||||
/// <summary>건설 비용 (mana=20) (mana=50; iron=10)</summary>
|
||||
public int mana;
|
||||
|
||||
[Header("Grid Size")]
|
||||
[Tooltip("X 그리드 차지 공간")]
|
||||
public int sizeX = 1;
|
||||
[Tooltip("Y 그리드 차지 공간")]
|
||||
public int sizeY = 1;
|
||||
[Tooltip("Z 차지 공간")]
|
||||
public int sizeZ = 2;
|
||||
|
||||
[Header("Placement Settings")]
|
||||
[Tooltip("Offset from grid position")]
|
||||
public Vector3 placementOffset = Vector3.zero;
|
||||
[Tooltip("Can rotate this building?")]
|
||||
public bool allowRotation = true;
|
||||
|
||||
[Header("Construction Settings")]
|
||||
[Tooltip("건설 완료에 필요한 총 작업량")]
|
||||
public float manpower = 100f;
|
||||
|
||||
[Header("Health Settings")]
|
||||
[Tooltip("체력")]
|
||||
public int maxHp = 100;
|
||||
[Tooltip("Can this building be damaged?")]
|
||||
public bool isIndestructible = false;
|
||||
[Tooltip("Auto-regenerate health over time")]
|
||||
public bool autoRegenerate = false;
|
||||
[Tooltip("Health regeneration per second")]
|
||||
public int regenPerSecond = 1;
|
||||
|
||||
[Header("Vision Settings")]
|
||||
[Tooltip("사정거리")]
|
||||
public int atkRange = 15;
|
||||
[Tooltip("Does this building provide vision?")]
|
||||
public bool providesVision = true;
|
||||
|
||||
[Header("Attack Settings")]
|
||||
[Tooltip("데미지")]
|
||||
public int atkDamage = 10;
|
||||
[Tooltip("공격 주기")]
|
||||
public float atkIntervalSec = 1f;
|
||||
|
||||
[Header("Model Settings")]
|
||||
[Tooltip("모델 경로")]
|
||||
/// <summary>건설 노동량</summary>
|
||||
public float manpower;
|
||||
/// <summary>X 그리드 차지 공간</summary>
|
||||
public int sizeX;
|
||||
/// <summary>Y 그리드 차지 공간</summary>
|
||||
public int sizeY;
|
||||
/// <summary>Z 차지 공간</summary>
|
||||
public int sizeZ;
|
||||
/// <summary>체력</summary>
|
||||
public int maxHp;
|
||||
/// <summary>사정거리</summary>
|
||||
public int atkRange;
|
||||
/// <summary>데미지</summary>
|
||||
public int atkDamage;
|
||||
/// <summary>공격 주기</summary>
|
||||
public float atkIntervalSec;
|
||||
/// <summary>모델 경로</summary>
|
||||
public string modelPath;
|
||||
|
||||
[Header("Properties for convenience")]
|
||||
public int width => sizeX;
|
||||
public int length => sizeY;
|
||||
public float height => sizeY;
|
||||
public int maxHealth => maxHp;
|
||||
public float visionRange => atkRange;
|
||||
public float requiredWorkAmount => manpower;
|
||||
|
||||
public Vector3 GetSize(int rotation)
|
||||
{
|
||||
// Rotation 0,180 = normal, 90,270 = swap width/length
|
||||
bool isRotated = (rotation == 1 || rotation == 3);
|
||||
float w = isRotated ? length : width;
|
||||
float l = isRotated ? width : length;
|
||||
return new Vector3(w, sizeY, l);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
52
Assets/Data/Scripts/DataClasses/TowerDataExtensions.cs
Normal file
52
Assets/Data/Scripts/DataClasses/TowerDataExtensions.cs
Normal file
@@ -0,0 +1,52 @@
|
||||
using UnityEngine;
|
||||
using Northbound;
|
||||
|
||||
namespace Northbound.Data
|
||||
{
|
||||
public partial class TowerData
|
||||
{
|
||||
[Header("Runtime References")]
|
||||
[Tooltip("Prefab reference - set by data pipeline")]
|
||||
public GameObject prefab;
|
||||
[Tooltip("UI icon")]
|
||||
public Sprite icon;
|
||||
|
||||
[Header("Placement Settings")]
|
||||
[Tooltip("Offset from grid position")]
|
||||
public Vector3 placementOffset = Vector3.zero;
|
||||
[Tooltip("Can rotate this building?")]
|
||||
public bool allowRotation = true;
|
||||
|
||||
[Header("Health Settings")]
|
||||
[Tooltip("Can this building be damaged?")]
|
||||
public bool isIndestructible = false;
|
||||
[Tooltip("Auto-regenerate health over time")]
|
||||
public bool autoRegenerate = false;
|
||||
[Tooltip("Health regeneration per second")]
|
||||
public int regenPerSecond = 1;
|
||||
|
||||
[Header("Vision Settings")]
|
||||
[Tooltip("Does this building provide vision?")]
|
||||
public bool providesVision = true;
|
||||
|
||||
[Header("Construction Settings")]
|
||||
[Tooltip("건설 시 사용할 도구")]
|
||||
public EquipmentData constructionEquipment;
|
||||
|
||||
[Header("Properties for convenience")]
|
||||
public int width => sizeX;
|
||||
public int length => sizeY;
|
||||
public float height => sizeY;
|
||||
public int maxHealth => maxHp;
|
||||
public float visionRange => atkRange;
|
||||
public float requiredWorkAmount => manpower;
|
||||
|
||||
public Vector3 GetSize(int rotation)
|
||||
{
|
||||
bool isRotated = (rotation == 1 || rotation == 3);
|
||||
float w = isRotated ? length : width;
|
||||
float l = isRotated ? width : length;
|
||||
return new Vector3(w, sizeY, l);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,2 @@
|
||||
fileFormatVersion: 2
|
||||
guid: fc31df76646aef242938ae1ab8547e0d
|
||||
Reference in New Issue
Block a user