2022-12-11 03:03:30 +00:00
using System ;
using System.Collections ;
2022-11-17 13:19:28 +00:00
using System.Collections.Generic ;
2023-03-15 11:43:15 +00:00
using System.Text.RegularExpressions ;
2022-11-17 13:19:28 +00:00
using UnityEngine ;
namespace SimpleInventorySystem
{
public enum ItemTags
{
Any ,
Helmet ,
Headset ,
Glasses ,
FaceCover ,
Plate ,
Weapon ,
Sidearm ,
MeleeWeapon ,
TacticalRig ,
TacticalRigAttachment ,
MedPouch ,
Backpack ,
Pouch1x1 ,
Pouch2x1 ,
Pouch3x1 ,
Pouch2x2 ,
BodyArmor ,
PlateCarrier ,
HeavyAmmunition ,
MediumAmmunition ,
LightAmmunition ,
ShotgunRounds
}
2023-03-15 11:43:15 +00:00
public enum ItemCategory
{
Gear
}
public enum ItemSubCategory
{
PlateCarriers
}
2022-12-11 03:03:30 +00:00
public enum RarityType
{
Common ,
2023-01-05 02:11:52 +00:00
Uncommon ,
2022-12-11 03:03:30 +00:00
Rare ,
Epic ,
Legendary
}
[Serializable]
public class Rarity
{
public RarityType rarityType ;
public Color color ;
}
2022-11-17 13:19:28 +00:00
public class InventorySystemPreferences
{
// This class is simply there for convenience. The bulk of this file will contain elements that the game developer or programmer can modify to extend their game.
2023-03-15 11:43:15 +00:00
public static Dictionary < ItemCategory , ItemSubCategory > ItemCategorySubcategoryMapping = new Dictionary < ItemCategory , ItemSubCategory > ( )
{
{ ItemCategory . Gear , ItemSubCategory . PlateCarriers }
} ;
public static string SeparateWords ( string input )
{
string output = input ;
//Regex.Replace(output, "(\\B[A-Z])", " $1");
Regex . Replace ( output , "(\\B[A-Z0-9])" , " $1" ) ;
return output ;
}
2022-11-17 13:19:28 +00:00
}
}