you can now undo a purchase after buying an item from the shop
This commit is contained in:
parent
efc7a3deaf
commit
64b25a2029
12 changed files with 359 additions and 56 deletions
|
|
@ -5,11 +5,13 @@ public class InventorySlot : ItemStorageSlot {
|
|||
* Gets called when the Inventory Slot is clicked
|
||||
*/
|
||||
public override void UseItem() {
|
||||
if(Item.GetType() == typeof(UsableItem)) {
|
||||
((UsableItem) Item).Select();
|
||||
Debug.Log("using " + Item.displayName);
|
||||
} else {
|
||||
Debug.Log("Item not usable " + Item.displayName);
|
||||
if(Item){
|
||||
if(Item.GetType() == typeof(UsableItem)) {
|
||||
((UsableItem)Item).Select();
|
||||
Debug.Log("using " + Item.displayName);
|
||||
} else {
|
||||
Debug.Log("Item not usable " + Item.displayName);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue