Add Shop system with ShopManager, ShopUI, and ShopSlotUI; implement item purchasing and shop UI functionality
This commit is contained in:
@@ -11,7 +11,7 @@ namespace Modifiers
|
||||
|
||||
public Stat stat;
|
||||
public float percent;
|
||||
public string Description => $"{stat} +{percent * 100}%";
|
||||
public string Description => GetDescription();
|
||||
|
||||
public void Apply(CharacterAttributes attributes)
|
||||
{
|
||||
@@ -55,5 +55,11 @@ namespace Modifiers
|
||||
_ => throw new System.ArgumentOutOfRangeException()
|
||||
};
|
||||
}
|
||||
|
||||
private string GetDescription()
|
||||
{
|
||||
var sign = percent >= 0 ? "+" : "";
|
||||
return $"{stat} {sign}{percent * 100}%";
|
||||
}
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user