Lua.RegisterFunction with enums
Posted: Thu Nov 16, 2023 6:50 pm
Hello!
Is it possible to have enums when registering a custom Lua function?
e.g.
Is it possible to have enums when registering a custom Lua function?
e.g.
Code: Select all
public enum ShopType
{
general,
card,
cardDiscard,
randomCard,
randomItem,
ingredient,
randomIngredient,
armour,
}
public ShopType shopType;
Lua.RegisterFunction(nameof(TriggerShop), this, SymbolExtensions.GetMethodInfo
(() => TriggerShop(DESIGNER INPUTS SHOPTYPE ENUM IN DIALOGUE EDITOR HERE)));
public void TriggerShop(ShopType shopType)
{
InventoryManager.instance.ShowShop(shopType);
}