Table of Contents

Method Drop

Namespace
GrindFest
Assembly
GrindFest.dll

Drop(ItemBehaviour)

Drops an item from inventory onto the ground.

public static void Drop(ItemBehaviour item)

Parameters

item ItemBehaviour

Item to drop

Remarks

This method will drop an item from the hero's inventory onto the ground at the hero's position.

Drop unwanted items:
var junkItems = Hero.Inventory.Where(item => item.GoldValue < 100).ToList(); // ToList() creates a copy to avoid modifying the collection while iterating
foreach(var item in junkItems)
{
    Hero.Drop(item);
    Hero.Say($"Dropped {item.name}, it's worthless!");
}