Add damage system and processing system to enemy

This commit is contained in:
2024-08-10 17:46:57 +02:00
parent f3623c6036
commit 6e0802163e
24 changed files with 1112 additions and 115 deletions

View File

@@ -0,0 +1,41 @@
using Sirenix.OdinInspector;
using System;
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
[Serializable]
public class Damage
{
public int value;
public static Type[] damageTypes = Type.all;
[ValueDropdown("damageTypes")]
public Type type;
[Serializable]
public class Type
{
private string name;
private Type(string name)
{
this.name = name;
}
public static Type normal = new("normal");
public static Type poison = new("poison");
public static Type[] all = new Type[] {
normal,
poison
};
public override string ToString()
{
return name;
}
}
}

View File

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