create balance scriptable object
This commit is contained in:
parent
20cf8c104f
commit
8bc0696bd4
34
ldjam50/Assets/Scripts/Balance/BalanceScriptableObject.cs
Normal file
34
ldjam50/Assets/Scripts/Balance/BalanceScriptableObject.cs
Normal file
@ -0,0 +1,34 @@
|
||||
using System;
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using UnityEngine;
|
||||
using UnityEngine.Serialization;
|
||||
|
||||
public class BalanceScriptableObject : MonoBehaviour
|
||||
{
|
||||
[CreateAssetMenu(fileName = "Data", menuName = "Game Data/Enemies Balance", order = 1)]
|
||||
public class SpawnManagerScriptableObject : ScriptableObject
|
||||
{
|
||||
public enum EnemyTypeEnum
|
||||
{
|
||||
Standart,
|
||||
Heavy,
|
||||
Light,
|
||||
Group
|
||||
}
|
||||
|
||||
[Serializable]
|
||||
public struct EnemyRow
|
||||
{
|
||||
public EnemyTypeEnum enemyTypeEnum;
|
||||
public int count;
|
||||
public int health;
|
||||
public int damage;
|
||||
public float speed;
|
||||
public float upgradePoints;
|
||||
public float floatTimeAfterDeath;
|
||||
}
|
||||
|
||||
[SerializeField] public List<EnemyRow> enemiesList;
|
||||
}
|
||||
}
|
@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 43de2f99e8d8aee00b99f37effd52dbd
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
50
ldjam50/Assets/Scripts/Balance/EnemiesBalance.asset
Normal file
50
ldjam50/Assets/Scripts/Balance/EnemiesBalance.asset
Normal file
@ -0,0 +1,50 @@
|
||||
%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: 0}
|
||||
m_Name: EnemiesBalance
|
||||
m_EditorClassIdentifier: Assembly-CSharp::BalanceScriptableObject/SpawnManagerScriptableObject
|
||||
enemiesList:
|
||||
- enemyTypeEnum: 0
|
||||
count: 1
|
||||
health: 100
|
||||
damage: 10
|
||||
speed: 2
|
||||
upgradePoints: 1
|
||||
floatTimeAfterDeath: 0.005
|
||||
- enemyTypeEnum: 1
|
||||
count: 1
|
||||
health: 200
|
||||
damage: 20
|
||||
speed: 1.5
|
||||
upgradePoints: 2
|
||||
floatTimeAfterDeath: 0.01
|
||||
- enemyTypeEnum: 2
|
||||
count: 1
|
||||
health: 50
|
||||
damage: 5
|
||||
speed: 2.5
|
||||
upgradePoints: 2
|
||||
floatTimeAfterDeath: 0.01
|
||||
- enemyTypeEnum: 3
|
||||
count: 4
|
||||
health: 0
|
||||
damage: 0
|
||||
speed: 0
|
||||
upgradePoints: 0
|
||||
floatTimeAfterDeath: 0
|
||||
- enemyTypeEnum: 0
|
||||
count: 4
|
||||
health: 625
|
||||
damage: 625
|
||||
speed: 1.88
|
||||
upgradePoints: 0.5
|
||||
floatTimeAfterDeath: 0.0025
|
8
ldjam50/Assets/Scripts/Balance/EnemiesBalance.asset.meta
Normal file
8
ldjam50/Assets/Scripts/Balance/EnemiesBalance.asset.meta
Normal file
@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 145dbaa0f1d2a2ff797b13ec2fdc78bf
|
||||
NativeFormatImporter:
|
||||
externalObjects: {}
|
||||
mainObjectFileID: 11400000
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
Loading…
Reference in New Issue
Block a user