Added inventory display and item display.
This commit is contained in:
@@ -8,7 +8,6 @@ public class Item
|
||||
public int currentAmount = 0;
|
||||
public double elapsedCraftTime = 0;
|
||||
public int amountCrafted = 0;
|
||||
public Texture2D display;
|
||||
|
||||
public CraftingResult Craft(int amount, double delta)
|
||||
{
|
||||
@@ -31,5 +30,11 @@ public class Item
|
||||
}
|
||||
return CraftingResult.FAILED;
|
||||
}
|
||||
|
||||
public string GetReadableName()
|
||||
{
|
||||
string noUnderscore = data.Id.Replace("_", " ").ToLower();
|
||||
return char.ToUpper(noUnderscore[0]) + noUnderscore.Substring(1);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user