Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System.Collections;
- using System.Collections.Generic;
- using UnityEngine;
- namespace PaCore.Game.Character
- {
- public enum StatType {
- Core, Defence, MartialSkills,
- MartialOffence, RangedSkills,
- RangedOffence, Meta, Spirit,
- LoreExp, Survival, TradeSpec }
- public enum StatWeight { Alpha, Beta, Capa, Delta }
- public class Stats : MonoBehaviour
- {
- public int StatPoints;
- public static StatBlock CreateStatBlock ()
- {
- StatBlock statBlock = new StatBlock();
- // CREATE STATS
- #region CORE STATS
- #region Physical Development
- // Strength
- List<Dependancy> strDep = new List<Dependancy>();
- statBlock.Stats.Add(CreateStat("Strength", StatType.Core, StatWeight.Capa, strDep));
- // Strength
- List<Dependancy> endDep = new List<Dependancy>();
- statBlock.Stats.Add(CreateStat("Endurance", StatType.Core, StatWeight.Capa, endDep));
- // Strength
- List<Dependancy> dexDep = new List<Dependancy>();
- statBlock.Stats.Add(CreateStat("Dexterity", StatType.Core, StatWeight.Capa, dexDep));
- // Strength
- List<Dependancy> resDep = new List<Dependancy>();
- statBlock.Stats.Add(CreateStat("Resilience", StatType.Core, StatWeight.Capa, resDep));
- #endregion
- #region Mental Development
- // Strength
- List<Dependancy> perDep = new List<Dependancy>();
- statBlock.Stats.Add(CreateStat("Perception", StatType.Core, StatWeight.Capa, perDep));
- // Strength
- List<Dependancy> intDep = new List<Dependancy>();
- statBlock.Stats.Add(CreateStat("Intelligence", StatType.Core, StatWeight.Capa, intDep));
- // Strength
- List<Dependancy> wilDep = new List<Dependancy>();
- statBlock.Stats.Add(CreateStat("Willpower", StatType.Core, StatWeight.Capa, wilDep));
- // Strength
- List<Dependancy> knoDep = new List<Dependancy>();
- statBlock.Stats.Add(CreateStat("Knowledge", StatType.Core, StatWeight.Capa, knoDep));
- #endregion
- #endregion
- #region STATS
- #region Defence
- statBlock.Stats.Add(CreateStat("Evade Melee", StatType.Defence, StatWeight.Capa, CreateDependancies("Dexterity,0,Perception,0,Strength,0")));
- statBlock.Stats.Add(CreateStat("Evade Ranged", StatType.Defence, StatWeight.Capa, CreateDependancies("Dexterity,0,Perception,0,Strength,0")));
- statBlock.Stats.Add(CreateStat("Evade Explosion", StatType.Defence, StatWeight.Capa, CreateDependancies("Dexterity,0,Perception,0,Resilience,0")));
- statBlock.Stats.Add(CreateStat("Deflect", StatType.Defence, StatWeight.Capa, CreateDependancies("Dexterity,0,Strength,0,Perception,0")));
- statBlock.Stats.Add(CreateStat("Mimicry", StatType.Defence, StatWeight.Capa, CreateDependancies("Dexterity,0,Perception,0,Strength,0")));
- #endregion
- #region Martial Skills
- statBlock.Stats.Add(CreateStat("Light Trauma", StatType.MartialSkills, StatWeight.Capa, CreateDependancies("Strength,0,Endurance,0,Dexterity,0")));
- statBlock.Stats.Add(CreateStat("Heavy Trauma", StatType.MartialSkills, StatWeight.Capa, CreateDependancies("Strength,0,Endurance,0,Dexterity,0")));
- statBlock.Stats.Add(CreateStat("Light Slashing", StatType.MartialSkills, StatWeight.Capa, CreateDependancies("Dexterity,0,Strength,0,Endurance,0")));
- statBlock.Stats.Add(CreateStat("Heavy Slashing", StatType.MartialSkills, StatWeight.Capa, CreateDependancies("Dexterity,0,Strength,0,Endurance,0")));
- statBlock.Stats.Add(CreateStat("Light Piercing", StatType.MartialSkills, StatWeight.Capa, CreateDependancies("Dexterity,0,Perception,0,Strength,0")));
- statBlock.Stats.Add(CreateStat("Heavy Piercing", StatType.MartialSkills, StatWeight.Capa, CreateDependancies("Dexterity,0,Strength,0,Perception,0")));
- statBlock.Stats.Add(CreateStat("Light Phys Power", StatType.MartialSkills, StatWeight.Capa, CreateDependancies("Dexterity,0,Strength,0,Endurance,0")));
- statBlock.Stats.Add(CreateStat("Heavy Phys Power", StatType.MartialSkills, StatWeight.Capa, CreateDependancies("Dexterity,0,Strength,0,Endurance,0")));
- statBlock.Stats.Add(CreateStat("Unarmed Skill", StatType.MartialSkills, StatWeight.Capa, CreateDependancies("Dexterity,0,Strength,0,Resilience,0")));
- statBlock.Stats.Add(CreateStat("Unarmed Reflex", StatType.MartialSkills, StatWeight.Capa, CreateDependancies("Dexterity,0,Perception,0")));
- statBlock.Stats.Add(CreateStat("Martial Reflex", StatType.MartialSkills, StatWeight.Capa, CreateDependancies("Dexterity,0,Perception,0")));
- #endregion
- #region Martial Attacks
- statBlock.Stats.Add(CreateStat("Sneak Attack", StatType.MartialOffence, StatWeight.Capa, CreateDependancies("Dexterity,0,Perception,0,Strength,0")));
- statBlock.Stats.Add(CreateStat("Precise Attack", StatType.MartialOffence, StatWeight.Capa, CreateDependancies("Dexterity,0,Perception,0,Strength,0")));
- statBlock.Stats.Add(CreateStat("Counter Attack", StatType.MartialOffence, StatWeight.Capa, CreateDependancies("Dexterity,0,Strength,0,Perception,0")));
- statBlock.Stats.Add(CreateStat("Dirty Fighting", StatType.MartialOffence, StatWeight.Capa, CreateDependancies("Strength,0,Dexterity,0,Enfurance,0")));
- statBlock.Stats.Add(CreateStat("Stunning Attack", StatType.MartialOffence, StatWeight.Capa, CreateDependancies("Perception,0,Strength,0,Dexterity,0")));
- #endregion
- #region Ranged Skills
- statBlock.Stats.Add(CreateStat("Pistols", StatType.RangedSkills, StatWeight.Capa, CreateDependancies("Dexterity,0,Perception,0")));
- statBlock.Stats.Add(CreateStat("Sub-Machine Guns", StatType.RangedSkills, StatWeight.Capa, CreateDependancies("Dexterity,0,Perception,0")));
- statBlock.Stats.Add(CreateStat("Shotguns", StatType.RangedSkills, StatWeight.Capa, CreateDependancies("Dexterity,0,Perception,0,Endurance,0")));
- statBlock.Stats.Add(CreateStat("Energy Weapons", StatType.RangedSkills, StatWeight.Capa, CreateDependancies("Dexterity,0,Perception,0")));
- statBlock.Stats.Add(CreateStat("Artillery Weapons", StatType.RangedSkills, StatWeight.Capa, CreateDependancies("Dexterity,0,Perception,0,Strength,0")));
- statBlock.Stats.Add(CreateStat("Martial Ranged", StatType.RangedSkills, StatWeight.Capa, CreateDependancies("Dexterity,0,Perception,0,Endurance,0")));
- statBlock.Stats.Add(CreateStat("Assault Rifles", StatType.RangedSkills, StatWeight.Capa, CreateDependancies("Dexterity,0,Perception,0,Strength,0")));
- statBlock.Stats.Add(CreateStat("Rifles", StatType.RangedSkills, StatWeight.Capa, CreateDependancies("Dexterity,0,Perception,0,Strength,0")));
- statBlock.Stats.Add(CreateStat("Explosive Weapons", StatType.RangedSkills, StatWeight.Capa, CreateDependancies("Dexterity,0,Perception,0,Strength,0")));
- statBlock.Stats.Add(CreateStat("Exotic Weapons", StatType.RangedSkills, StatWeight.Capa, CreateDependancies("Dexterity,0,Perception,0,Intelligence,0")));
- statBlock.Stats.Add(CreateStat("Ranged Reflex", StatType.RangedSkills, StatWeight.Capa, CreateDependancies("Dexterity,0,Perception,0,Strength,0")));
- #endregion
- #region Ranged Attacks
- statBlock.Stats.Add(CreateStat("Quick Shot", StatType.RangedOffence, StatWeight.Capa, CreateDependancies("Dexterity,0,Perception,0")));
- statBlock.Stats.Add(CreateStat("Burst Fire", StatType.RangedOffence, StatWeight.Capa, CreateDependancies("Dexterity,0,Perception,0,Strength,0")));
- statBlock.Stats.Add(CreateStat("Deflect Shot", StatType.RangedOffence, StatWeight.Capa, CreateDependancies("Dexterity,0,Perception,0")));
- statBlock.Stats.Add(CreateStat("Precise Shot", StatType.RangedOffence, StatWeight.Capa, CreateDependancies("Dexterity,0,Perception,0")));
- statBlock.Stats.Add(CreateStat("Full Auto", StatType.RangedOffence, StatWeight.Capa, CreateDependancies("Dexterity,0,Perception,0,Endurance,0")));
- statBlock.Stats.Add(CreateStat("Speciality", StatType.RangedOffence, StatWeight.Capa, CreateDependancies("Dexterity,0,Perception,0")));
- statBlock.Stats.Add(CreateStat("Run & Gun", StatType.RangedOffence, StatWeight.Capa, CreateDependancies("Dexterity,0,Endurance,0,Strength,0")));
- #endregion
- #region Metamatics
- statBlock.Stats.Add(CreateStat("Meta-Alter", StatType.Meta, StatWeight.Capa, CreateDependancies("Intelligence,0,Willpower,0,Perception,0")));
- statBlock.Stats.Add(CreateStat("Meta-Control", StatType.Meta, StatWeight.Capa, CreateDependancies("Intelligence,0,Willpower,0,Perception,0")));
- statBlock.Stats.Add(CreateStat("Meta-Create", StatType.Meta, StatWeight.Capa, CreateDependancies("Intelligence,0,Willpower,0,Knowledge,0")));
- statBlock.Stats.Add(CreateStat("Meta-Destruct", StatType.Meta, StatWeight.Capa, CreateDependancies("Intelligence,0,Willpower,0,Perception,0")));
- statBlock.Stats.Add(CreateStat("Meta-Augment", StatType.Meta, StatWeight.Capa, CreateDependancies("Intelligence,0,Willpower,0,Knowledge,0")));
- statBlock.Stats.Add(CreateStat("Meta-Biotics", StatType.Meta, StatWeight.Capa, CreateDependancies("Intelligence,0,Willpower,0,Perception,0")));
- statBlock.Stats.Add(CreateStat("Meta-Synergy", StatType.Meta, StatWeight.Capa, CreateDependancies("Intelligence,0,Willpower,0")));
- statBlock.Stats.Add(CreateStat("Meta-Reserve", StatType.Defence, StatWeight.Capa, CreateDependancies("Willpower,0,Intelligence,0")));
- #endregion
- #region Dimensional
- statBlock.Stats.Add(CreateStat("Void Manipulation", StatType.Spirit, StatWeight.Capa, CreateDependancies("Intelligence,0,Willpower,0,Resilience,0")));
- statBlock.Stats.Add(CreateStat("Void Control", StatType.Spirit, StatWeight.Capa, CreateDependancies("Intelligence,0,Willpower,0,Resilience,0")));
- statBlock.Stats.Add(CreateStat("Chatotic Affinity", StatType.Spirit, StatWeight.Capa, CreateDependancies("Intelligence,0,Willpower,0,Knowledge,0")));
- statBlock.Stats.Add(CreateStat("Psionic Affinity", StatType.Spirit, StatWeight.Capa, CreateDependancies("Intelligence,0,Willpower,0,Knowledge,0")));
- statBlock.Stats.Add(CreateStat("Energy Channelling", StatType.Spirit, StatWeight.Capa, CreateDependancies("Intelligence,0,Willpower,0,Resilience,0")));
- #endregion
- #region Lore & Exploration
- statBlock.Stats.Add(CreateStat("Run Speed", StatType.LoreExp, StatWeight.Capa, CreateDependancies("Dexterity,0,Endurance,0,Strength,0")));
- statBlock.Stats.Add(CreateStat("Swim Speed", StatType.LoreExp, StatWeight.Capa, CreateDependancies("Strength,0,Endurance,0,Dexterity,0")));
- statBlock.Stats.Add(CreateStat("Vehicle Proficiency", StatType.LoreExp, StatWeight.Capa, CreateDependancies("Dexterity,0,Perception,0,Knowledge,0")));
- statBlock.Stats.Add(CreateStat("Cartography", StatType.LoreExp, StatWeight.Capa, CreateDependancies("Intelligence,0,Knowledge,0,Perception,0")));
- statBlock.Stats.Add(CreateStat("History", StatType.LoreExp, StatWeight.Capa, CreateDependancies("Knowledge,0,Intelligence,0")));
- statBlock.Stats.Add(CreateStat("Language", StatType.LoreExp, StatWeight.Capa, CreateDependancies("Knowledge,0,Intelligence,0,Perception,0")));
- #endregion
- #region Survival & Awareness
- statBlock.Stats.Add(CreateStat("Concealment", StatType.Survival, StatWeight.Capa, CreateDependancies("Perception,0,Dexterity,0")));
- statBlock.Stats.Add(CreateStat("First Aid", StatType.Survival, StatWeight.Capa, CreateDependancies("Intelligence,0,Knowledge,0,Perception,0")));
- statBlock.Stats.Add(CreateStat("Field Surgery", StatType.Survival, StatWeight.Capa, CreateDependancies("Intelligence,0,Knowledge,0,Perception,0")));
- statBlock.Stats.Add(CreateStat("Awareness", StatType.Survival, StatWeight.Capa, CreateDependancies("Perception,0,Intelligence,0")));
- statBlock.Stats.Add(CreateStat("Negotiation", StatType.Survival, StatWeight.Capa, CreateDependancies("Perception,0,Intelligence,0,Willpower,0")));
- statBlock.Stats.Add(CreateStat("Scavenging", StatType.Survival, StatWeight.Capa, CreateDependancies("Perception,0,Intelligence,0,Resilience,0")));
- #endregion
- #region Trade & Speciality
- statBlock.Stats.Add(CreateStat("Engineering", StatType.TradeSpec, StatWeight.Capa, CreateDependancies("Knowledge,0,Intelligence,0,Perception,0")));
- statBlock.Stats.Add(CreateStat("Material Science", StatType.TradeSpec, StatWeight.Capa, CreateDependancies("Knowledge,0,Intelligence,0")));
- statBlock.Stats.Add(CreateStat("Avionics", StatType.TradeSpec, StatWeight.Capa, CreateDependancies("Knowledge,0,Intelligence,0")));
- statBlock.Stats.Add(CreateStat("Computer Science", StatType.TradeSpec, StatWeight.Capa, CreateDependancies("Knowledge,0,Intelligence,0,Perception,0")));
- statBlock.Stats.Add(CreateStat("Chemisty", StatType.TradeSpec, StatWeight.Capa, CreateDependancies("Knowledge,0,Intelligence,0")));
- statBlock.Stats.Add(CreateStat("Quantum Physics", StatType.TradeSpec, StatWeight.Capa, CreateDependancies("Knowledge,0,Intelligence,0,Perception,0")));
- statBlock.Stats.Add(CreateStat("Pharmacology", StatType.TradeSpec, StatWeight.Capa, CreateDependancies("Knowledge,0,Intelligence,0")));
- statBlock.Stats.Add(CreateStat("Genetics", StatType.TradeSpec, StatWeight.Capa, CreateDependancies("Knowledge,0,Intelligence,0")));
- statBlock.Stats.Add(CreateStat("Neurology", StatType.TradeSpec, StatWeight.Capa, CreateDependancies("Knowledge,0,Intelligence,0")));
- statBlock.Stats.Add(CreateStat("Internal Medicine", StatType.TradeSpec, StatWeight.Capa, CreateDependancies("Knowledge,0,Intelligence,0,Willpower,0")));
- statBlock.Stats.Add(CreateStat("Security", StatType.TradeSpec, StatWeight.Capa, CreateDependancies("Dexterity,0,Knowledge,0,Perception,0")));
- #endregion
- #endregion
- return statBlock;
- }
- static Stat CreateStat (string name, StatType type, StatWeight weight, List<Dependancy> Dependancies)
- {
- Stat newStat = new Stat();
- newStat.Name = name;
- newStat.Type = type;
- newStat.Weight = weight;
- switch (weight)
- {
- case StatWeight.Alpha:
- newStat.BaseValue = 10;
- break;
- case StatWeight.Beta:
- newStat.BaseValue = 8;
- break;
- case StatWeight.Capa:
- newStat.BaseValue = 6;
- break;
- case StatWeight.Delta:
- newStat.BaseValue = 4;
- break;
- }
- newStat.Dependancies = Dependancies;
- return newStat;
- }
- static List<Dependancy> CreateDependancies (string dependancies)
- {
- string[] split = dependancies.Split(',');
- List<Dependancy> depend = new List<Dependancy>();
- foreach (string part in split)
- {
- Debug.Log(part);
- }
- return depend;
- }
- }
- [System.Serializable]
- public class StatBlock
- {
- public List<Stat> Stats = new List<Stat>();
- public void Trickle ()
- {
- }
- }
- [System.Serializable]
- public class Dependancy
- {
- public string name;
- public string value;
- }
- [System.Serializable]
- public class Stat
- {
- private string name;
- public string Name { get { return name; } set { name = value; } }
- private StatType type;
- public StatType Type { get { return type; } set { type = value; } }
- private StatWeight weight;
- public StatWeight Weight { get { return weight; } set { weight = value; } }
- private int baseValue;
- public int BaseValue { get { return baseValue; } set { baseValue = value; } }
- private int currentValue;
- public int CurrentValue { get { return currentValue; } set { currentValue = value; } }
- private List<Dependancy> dependancies = new List<Dependancy>();
- public List<Dependancy> Dependancies { get { return dependancies; } set { dependancies = value; } }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement