- Обновления
- Только поддержка
- Языки
- Английский
- Требуемый плагин
-
- Дополнительный плагин
-
При обновлении до версии 1.4.0 вы должны удалить файл Cooking.json в oxide/config/.

Этот плагин добавляет на ваш сервер большое разнообразие ингредиентов, рецептов и эффектов.
Ингредиенты можно найти от попадания в узлы до резки деревьев и сбора конопли, кукурузы, тыквы и картофеля.
Эти ингредиенты имеют свои собственные скины и названия и являются частью многих рецептов, включенных в этот плагин.
Вы также можете добавить свои собственные ингредиенты и создать свои собственные рецепты через конфигурацию, назначив любой из 37 различных типов усиления вместе с желаемой продолжительностью.
Создатели плагинов также могут создавать свои собственные эффекты и подключать их с помощью баффа «Крючок».

Есть более 40 рецептов, которые поставляются с конфигурацией по умолчанию.
Каждый рецепт имеет список до 10 различных ингредиентов и предоставляет один из 37 уникальных баффов на настраиваемую продолжительность.
Рецепты можно легко добавить через конфиг. Единственными требованиями для этого являются уникальный идентификатор скина и ссылка на изображение.
Вышеприведенное видео демонстрирует, как рецепты могут быть легко добавлены в вашу конфигурацию.

Плагин поставляется с более чем 35 уникальными ингредиентами, а также включает в себя некоторые элементы по умолчанию в rust. T
Ингредиенты можно легко добавить в конфигурацию (см. видео выше).
Все нестандартные ингредиенты можно найти из 19 различных источников, включая вырубку деревьев, добычу полезных ископаемых, сбор конопли и т. д.
Скорость выпадения каждого источника можно настроить в соответствии с вашим сервером, а источники ингредиентов можно невероятно легко изменить, просто изменив число. в файле конфигурации.

Существует 19 уникальных источников, из которых можно получить ингредиенты: от рубки деревьев до сбора тыкв.
Вероятность выпадения каждого ингредиента зависит от взаимодействия с этим источником.
Например, сбор тыквы дает 1 шанс, так как сбор тыквы — это 1 взаимодействие, в то время как срезание дерева может дать 10-20 шансов (в зависимости от инструмента), так как для падения дерева требуется несколько ударов.
Когда бросок успешен, он затем перебирает каждый тип предметов и выбирает предмет на основе этого предмета «Вес падения», что позволяет вам делать ингредиенты более или менее распространенными, чем другие в той же таблице выпадения.

Фермерский рынок — это встроенный рынок, который позволяет игрокам покупать и продавать ингредиенты за металлолом или экономику.
По умолчанию запасы на рынке начинаются с 0 и будут увеличиваться только по мере того, как игроки продают ему свои ненужные ингредиенты.
Его можно настроить так, чтобы через него можно было покупать и продавать все предметы или только пользовательские предметы, а также позволяет установить максимальный запас (по умолчанию 100), что означает, что он не может иметь более 100 предметов типа.
Значения покупки/продажи для каждого ингредиента можно настроить в файле конфигурации (по умолчанию покупка 10 долларов, продажа 5 долларов).
Также можно установить начальное количество, если вы не хотите, чтобы рынок начинался с 0.
Доступ к рынку можно получить, введя /market (если конфигурация включена) или поговорив с NPC, имя которого соответствует названию рынка (по умолчанию: рынок фермеров).

Команда: recipemenu
Действие: Открывает меню рецептов из любого места. Остерегайтесь, это не закроет кнопку меню.
Разрешение: cook.recipemenu.chat
Команда: market
Действие: Открывает меню рынка
Разрешение: cook.market.command
Команда: clearrecipebags
Действие: Удаляет все данные о пакетах с ингредиентами.
Разрешение: Cooking.admin
Команда: givemeal
Параметры: <имя блюда>
Действие: Создает желаемое блюдо для игрока.
Пример: /givemeal куриный ужин
Разрешение: cook.admin
Команда: giveingredient
Параметры: <имя ингредиента> <необязательно: количество>
Действие: Создает нужный ингредиент для игрока.
Пример: /givingredient черный перец 20
Разрешение: Cooking.admin
Команда: resetmarket
Действие: Сбрасывает рыночные количества до значений в конфигурации.
Разрешение: Cooking.admin
Команда: toggledrops
Действие: Переключает выпадение ингредиентов при сборе
Разрешение: нет
Команда: setmarketquantity
Параметры: <название ингредиента> <необязательно: количество>
Действие: Устанавливает доступные единицы ингредиента, доступного на рынке, на желаемое количество.
Пример: /setmarketquantityblack перец 20
Разрешение: cook.admin
Команда: updaterecipes
Действие: Добавляет рецепты из конфигурации по умолчанию, которых нет в конфигурации пользователя. Это полезно для владельцев серверов, купивших плагин ранее и не исправивших свою конфигурацию за несколько релизов.
Разрешение: Cooking.admin
Команда: ibag
Действие: Позволяет игроку открыть сумку с ингредиентами без предмета. Помещает предметы прямо в сумку с ингредиентами игрока, если они собраны без предмета.
Разрешение: cook.chat.bag
Команда: cturbo
Действие: Включает режим турбо для лодок, когда активен бафф BoatTurbo.
Разрешение: нет

Cooking.admin — требуется для админ-команд.
Cooking.free - возможность приготовить еду без ингредиентов.
Cooking.instant - приготовление происходит мгновенно.
Cooking.use — требуется для того, чтобы пользователи могли готовить еду.
Cooking.recipemenu.chat — требуется для использования команды /recipemenu cook.market.command
— требуется для использования команды чата для открытия фермерского рынка.
Cooking.chat.bag — требуется для использования команды чата, чтобы открыть пакет с ингредиентами.
Cooking.gather — требуется игрокам для получения выпадающих ингредиентов.

1: HealthOverload - The consumer receives BuffModifier additional health. This allows their health to exceed 100, and will automatically be reduced to 100 health after the duration (Default: 50.0).
2: FoodShare - Anytime the consumer has their calories increased, everyone within BuffModifier meters will also have their calories increased by the same amount for the duration (Default: 20.0m).
3: FoodOverload - Will increase the calorie cap of the consumer to the BuffModifier value for configured hours (Default: 1000 calories. Default 2 hours).
4: Comfort - The consumer will have 100% comfort for the duration.
5: WaterBreathing - The consumer will be able to breath underwater for the duration.
6: FireResist - All fire damage the consumer takes is reduced to 0 for the duration.
7: ColdResist - All cold damage the consumer takes is reduced to 0 for the duration.
8: ExplosionResist - All explosion damage the consumer takes is reduced by BuffModifier% for the duration (Default: 50.0%).
9: AnimalResist - All damage done to the consumer from animals and murderes/scarecrows is reduced to BuffModifier for the duration (Default: 0.25x).
10: MeleeResist - All damage done to the consumer from melee weapons is reduced to BuffModifier for the duration (Default: 0.25x).
11: WoundedResist - When the consumer enters the wounded state for the duration of effect, they are brought back to their feet and receive x health and have all effects removed. This removes the meal effect.
12: Spectre - All turrets and base defences (including sam sites) will not target the consumer for the duration.
13: Madness - Anytime the consumer speaks over voice, their voice is muted and is replaced with horrible screaming for the duration.
14: Wealth - Whenever the consumer breaks a barrel, they are rewarded with economic dollars (equal to the BuffModifier value) for the duration (Default: 1.0).
15: AntiBradleyRadar - The consumer cannot be targeted by bradley tank for the duration.
16: Ingredient - This is simply an ingredient and has no effect.
17: Hook - This is required to trigger a custom hook when a meal is consumed.
18: BarrelSmasher - The consumer instantly destroys barrels when damage is done, regardless of the damage amount, for the duration.
19: CraftingRefund - The consumer has a BuffModifier percentage chance to be fully refunded for their crafting components when crafting an item for the duration (Default: 10.0%).
20: PassiveRegen - The consumer will receive x health every y seconds forthe duration. x is equal to the BuffModifier field and can be recipe specific (Default: 5).
21: HorseStats - When moved into a horses inventory, it will speed the horse up by x for the duration. Does not consume a meal slot. X is equal to the BuffModifier field (Default: 15).
22: Invisible - The consumer enters Vanish mode when consumed for BuffModifier seconds. Requires the Vanish plugin (Default: 5).
23: NoFallDamage - The consumer will not take fall damage for the duration.
24: NoConditionLoss - The consumer will not lose any condition on their active weapon for the duration.
25: IngredientChance - The consumer will have better luck finding ingredients from all sources for the duration.
26: UngradeRefund - The consumer has BuffModifier percentage chance to be refunded the upgrade costs when upgrading a building block (Default: 10%).
27: ResearchRefund - the consumer has BuffModifier percentage chance to be refunded the scrap costs when researching an item on the research table (Default: 10%).
28: NightVision - the consumer will have nightvision enabled for the duration. Requires the NightVision plugin.
29: RolePlay - Inherrits the calorie/hydration modifiers from the base food used. Offers no other buff. Useful for role players.
30: AntiHeliRadar - Makes the consumer invisible to heli's minigun.
31: FishingLuck - Increases the chance of obtaining a casket while fishing by the BuffModifier value (Default: 2.0x) (Requires the FishingTreasure plugin).
32: MiningYield - Increases the amount of resources obtained while mining by the BuffModifier value (Default: 2.0x).
33: WoodcuttingYield - Increases the amount of resources obtained while woodcutting by the BuffModifier value (Default: 2.0x).
34: FarmingYield - Increases the amount of resources obtained while collecting player grown produce (Default: 1.5x).
35: ComponentLuck - Adds a chance (based on BuffModifier) for an additional loot slot to be added, containing a random component (Default: 5%).
36: ElectronicsLuck - Adds a chance (based on BuffModifier) for an additional loot slot to be added, containing a random electric component/item (Default: 3%).
37: DoubleJump - Uses the DoubleJump plugin to give the consumer double jump (Requires the double jump plugin).
38: BoatTurbo - Adjusts the speed of the mounted boat when the /cturbo command is toggled.
39: Permission - Will add the player to the specified permission groups and remove them when the buff ends.
40: NoBleed - Prevents the player from bleeding.
41: RadiationResist - Prevents the player from accumulating radiation.
42: MaxRepair - Resets the items max condition when it is repaired while afftected by this buff.

0: Node - Stone, Metal and Sulfur nodes.
1: TreeAll - All trees.
2: TreePalm - Palm trees.
3: Hemp - All hemp plants.
4: CollectableNode - The small collectable stone, metal and sulfur nodes.
5: BerryBush - Bushes that berries can be picked from.
6: Pumpkin - All Pumpkin patches.
7: Potato - All potato patches.
8: Corn - All corn patches.
9: Fish - Gutting a fish.
10: Boar - Harvested specifically from boars.
11: Chicken - Harvested specifically from chickens.
12: Bear - Harvested specifically from bears.
13: Stag - Harvested specifically from stags.
14: Wolf - Harvested specifically from wolves.
15: Horse - Harvested specifically from horses.
16: Mushroom - All mushroom patches.
17: Animal - All mammals.
18: Default - An item that is obtained by default in Rust.
19: Crafted - An item that needs to be crafted (requires a recipe as well).

HumanNPC - Used if you want the market to be accessed via NPC. Simply adjust the name of the NPC to match what is in the config.
Vanish - Used in the Inivisibility buff type.
NightVision - Used in the NightVision buff type.
Economics - Used for the farmers market and the Wealth buff type.
ServerRewards - Used for the market and the Wealth buff type.

The following calls require an item to have the "Hook" buff type (#17). They can be added to your own plugin and will be called as the plugin requires them.
object GetBuffDescription(ulong skin)
{
if (skin == 2428317574) return "This is sushi and it does stuff";
else return null;
}
This API call is called 30 seconds after the plugin loads, and populates the recipe menu buff description with the relevant info.
void RecipeConsumed(BasePlayer player, string name, string shortname, ulong skin, int duration)
{
Puts($"Consumed food {name} - short: {shortname} - skin: {skin} - duration {duration}");
}
This API call is called when a player eats a meal with the Hook buff type. Returns no information.
object BuffRequiresTimer(BasePlayer player, string name, string shortname, ulong skin)
{
if (skin == 2428317574)
{
return false;
}
return null;
}
This API call is fired just after a meal is consumed to see if the meal requires a buff timer. If false is returned, it will not provide a buff timer/count down, or fire off our next API call.
void RecipeEnded(BasePlayer player, string name, string shortname, ulong skin)
{
Puts($"Effect ended - {name}.");
}
This API call is fired when the buff timer has finished. Returns no information.
bool CanBuyIngredient(BasePlayer player)
{
Puts("Returning false prevents the purchase of an item from the market.");
return false;
}
bool CanSellIngredient(BasePlayer player)
{
Puts("Returning false prevents the sale of an item to the market.");
return false;
}
These API calls are made when a player attempts to buy or sell an ingredient to the farmers market. Returning false prevents the transaction.
void OnIngredientPurchased(BasePlayer player, string ingredient, double cost)
{
Puts($"Player {player.displayName} purchased a {ingredient} from the market for ${cost}");
}
void OnIngredientSold(BasePlayer player, string ingredient, double cost)
{
Puts($"Player {player.displayName} sold an {ingredient} to the market for ${cost}");
}
These calls are made when a player has successfully bought or sold an ingredient to the market.
bool CanGatherIngredient(BasePlayer player, uint source)
Returning a non-null value will prevent players from receiving ingredients from certain drop sources. the source is the networked ID of the entity.
void OnMealCrafed(BasePlayer player, string meal, Dictionary<string, int> ingredients)
Called after a meal has been created and given to the player.

Этот плагин добавляет на ваш сервер большое разнообразие ингредиентов, рецептов и эффектов.
Ингредиенты можно найти от попадания в узлы до резки деревьев и сбора конопли, кукурузы, тыквы и картофеля.
Эти ингредиенты имеют свои собственные скины и названия и являются частью многих рецептов, включенных в этот плагин.
Вы также можете добавить свои собственные ингредиенты и создать свои собственные рецепты через конфигурацию, назначив любой из 37 различных типов усиления вместе с желаемой продолжительностью.
Создатели плагинов также могут создавать свои собственные эффекты и подключать их с помощью баффа «Крючок».

Есть более 40 рецептов, которые поставляются с конфигурацией по умолчанию.
Каждый рецепт имеет список до 10 различных ингредиентов и предоставляет один из 37 уникальных баффов на настраиваемую продолжительность.
Рецепты можно легко добавить через конфиг. Единственными требованиями для этого являются уникальный идентификатор скина и ссылка на изображение.
Вышеприведенное видео демонстрирует, как рецепты могут быть легко добавлены в вашу конфигурацию.

Плагин поставляется с более чем 35 уникальными ингредиентами, а также включает в себя некоторые элементы по умолчанию в rust. T
Ингредиенты можно легко добавить в конфигурацию (см. видео выше).
Все нестандартные ингредиенты можно найти из 19 различных источников, включая вырубку деревьев, добычу полезных ископаемых, сбор конопли и т. д.
Скорость выпадения каждого источника можно настроить в соответствии с вашим сервером, а источники ингредиентов можно невероятно легко изменить, просто изменив число. в файле конфигурации.

Существует 19 уникальных источников, из которых можно получить ингредиенты: от рубки деревьев до сбора тыкв.
Вероятность выпадения каждого ингредиента зависит от взаимодействия с этим источником.
Например, сбор тыквы дает 1 шанс, так как сбор тыквы — это 1 взаимодействие, в то время как срезание дерева может дать 10-20 шансов (в зависимости от инструмента), так как для падения дерева требуется несколько ударов.
Когда бросок успешен, он затем перебирает каждый тип предметов и выбирает предмет на основе этого предмета «Вес падения», что позволяет вам делать ингредиенты более или менее распространенными, чем другие в той же таблице выпадения.

Фермерский рынок — это встроенный рынок, который позволяет игрокам покупать и продавать ингредиенты за металлолом или экономику.
По умолчанию запасы на рынке начинаются с 0 и будут увеличиваться только по мере того, как игроки продают ему свои ненужные ингредиенты.
Его можно настроить так, чтобы через него можно было покупать и продавать все предметы или только пользовательские предметы, а также позволяет установить максимальный запас (по умолчанию 100), что означает, что он не может иметь более 100 предметов типа.
Значения покупки/продажи для каждого ингредиента можно настроить в файле конфигурации (по умолчанию покупка 10 долларов, продажа 5 долларов).
Также можно установить начальное количество, если вы не хотите, чтобы рынок начинался с 0.
Доступ к рынку можно получить, введя /market (если конфигурация включена) или поговорив с NPC, имя которого соответствует названию рынка (по умолчанию: рынок фермеров).

Команда: recipemenu
Действие: Открывает меню рецептов из любого места. Остерегайтесь, это не закроет кнопку меню.
Разрешение: cook.recipemenu.chat
Команда: market
Действие: Открывает меню рынка
Разрешение: cook.market.command
Команда: clearrecipebags
Действие: Удаляет все данные о пакетах с ингредиентами.
Разрешение: Cooking.admin
Команда: givemeal
Параметры: <имя блюда>
Действие: Создает желаемое блюдо для игрока.
Пример: /givemeal куриный ужин
Разрешение: cook.admin
Команда: giveingredient
Параметры: <имя ингредиента> <необязательно: количество>
Действие: Создает нужный ингредиент для игрока.
Пример: /givingredient черный перец 20
Разрешение: Cooking.admin
Команда: resetmarket
Действие: Сбрасывает рыночные количества до значений в конфигурации.
Разрешение: Cooking.admin
Команда: toggledrops
Действие: Переключает выпадение ингредиентов при сборе
Разрешение: нет
Команда: setmarketquantity
Параметры: <название ингредиента> <необязательно: количество>
Действие: Устанавливает доступные единицы ингредиента, доступного на рынке, на желаемое количество.
Пример: /setmarketquantityblack перец 20
Разрешение: cook.admin
Команда: updaterecipes
Действие: Добавляет рецепты из конфигурации по умолчанию, которых нет в конфигурации пользователя. Это полезно для владельцев серверов, купивших плагин ранее и не исправивших свою конфигурацию за несколько релизов.
Разрешение: Cooking.admin
Команда: ibag
Действие: Позволяет игроку открыть сумку с ингредиентами без предмета. Помещает предметы прямо в сумку с ингредиентами игрока, если они собраны без предмета.
Разрешение: cook.chat.bag
Команда: cturbo
Действие: Включает режим турбо для лодок, когда активен бафф BoatTurbo.
Разрешение: нет

Cooking.admin — требуется для админ-команд.
Cooking.free - возможность приготовить еду без ингредиентов.
Cooking.instant - приготовление происходит мгновенно.
Cooking.use — требуется для того, чтобы пользователи могли готовить еду.
Cooking.recipemenu.chat — требуется для использования команды /recipemenu cook.market.command
— требуется для использования команды чата для открытия фермерского рынка.
Cooking.chat.bag — требуется для использования команды чата, чтобы открыть пакет с ингредиентами.
Cooking.gather — требуется игрокам для получения выпадающих ингредиентов.

1: HealthOverload - The consumer receives BuffModifier additional health. This allows their health to exceed 100, and will automatically be reduced to 100 health after the duration (Default: 50.0).
2: FoodShare - Anytime the consumer has their calories increased, everyone within BuffModifier meters will also have their calories increased by the same amount for the duration (Default: 20.0m).
3: FoodOverload - Will increase the calorie cap of the consumer to the BuffModifier value for configured hours (Default: 1000 calories. Default 2 hours).
4: Comfort - The consumer will have 100% comfort for the duration.
5: WaterBreathing - The consumer will be able to breath underwater for the duration.
6: FireResist - All fire damage the consumer takes is reduced to 0 for the duration.
7: ColdResist - All cold damage the consumer takes is reduced to 0 for the duration.
8: ExplosionResist - All explosion damage the consumer takes is reduced by BuffModifier% for the duration (Default: 50.0%).
9: AnimalResist - All damage done to the consumer from animals and murderes/scarecrows is reduced to BuffModifier for the duration (Default: 0.25x).
10: MeleeResist - All damage done to the consumer from melee weapons is reduced to BuffModifier for the duration (Default: 0.25x).
11: WoundedResist - When the consumer enters the wounded state for the duration of effect, they are brought back to their feet and receive x health and have all effects removed. This removes the meal effect.
12: Spectre - All turrets and base defences (including sam sites) will not target the consumer for the duration.
13: Madness - Anytime the consumer speaks over voice, their voice is muted and is replaced with horrible screaming for the duration.
14: Wealth - Whenever the consumer breaks a barrel, they are rewarded with economic dollars (equal to the BuffModifier value) for the duration (Default: 1.0).
15: AntiBradleyRadar - The consumer cannot be targeted by bradley tank for the duration.
16: Ingredient - This is simply an ingredient and has no effect.
17: Hook - This is required to trigger a custom hook when a meal is consumed.
18: BarrelSmasher - The consumer instantly destroys barrels when damage is done, regardless of the damage amount, for the duration.
19: CraftingRefund - The consumer has a BuffModifier percentage chance to be fully refunded for their crafting components when crafting an item for the duration (Default: 10.0%).
20: PassiveRegen - The consumer will receive x health every y seconds forthe duration. x is equal to the BuffModifier field and can be recipe specific (Default: 5).
21: HorseStats - When moved into a horses inventory, it will speed the horse up by x for the duration. Does not consume a meal slot. X is equal to the BuffModifier field (Default: 15).
22: Invisible - The consumer enters Vanish mode when consumed for BuffModifier seconds. Requires the Vanish plugin (Default: 5).
23: NoFallDamage - The consumer will not take fall damage for the duration.
24: NoConditionLoss - The consumer will not lose any condition on their active weapon for the duration.
25: IngredientChance - The consumer will have better luck finding ingredients from all sources for the duration.
26: UngradeRefund - The consumer has BuffModifier percentage chance to be refunded the upgrade costs when upgrading a building block (Default: 10%).
27: ResearchRefund - the consumer has BuffModifier percentage chance to be refunded the scrap costs when researching an item on the research table (Default: 10%).
28: NightVision - the consumer will have nightvision enabled for the duration. Requires the NightVision plugin.
29: RolePlay - Inherrits the calorie/hydration modifiers from the base food used. Offers no other buff. Useful for role players.
30: AntiHeliRadar - Makes the consumer invisible to heli's minigun.
31: FishingLuck - Increases the chance of obtaining a casket while fishing by the BuffModifier value (Default: 2.0x) (Requires the FishingTreasure plugin).
32: MiningYield - Increases the amount of resources obtained while mining by the BuffModifier value (Default: 2.0x).
33: WoodcuttingYield - Increases the amount of resources obtained while woodcutting by the BuffModifier value (Default: 2.0x).
34: FarmingYield - Increases the amount of resources obtained while collecting player grown produce (Default: 1.5x).
35: ComponentLuck - Adds a chance (based on BuffModifier) for an additional loot slot to be added, containing a random component (Default: 5%).
36: ElectronicsLuck - Adds a chance (based on BuffModifier) for an additional loot slot to be added, containing a random electric component/item (Default: 3%).
37: DoubleJump - Uses the DoubleJump plugin to give the consumer double jump (Requires the double jump plugin).
38: BoatTurbo - Adjusts the speed of the mounted boat when the /cturbo command is toggled.
39: Permission - Will add the player to the specified permission groups and remove them when the buff ends.
40: NoBleed - Prevents the player from bleeding.
41: RadiationResist - Prevents the player from accumulating radiation.
42: MaxRepair - Resets the items max condition when it is repaired while afftected by this buff.

0: Node - Stone, Metal and Sulfur nodes.
1: TreeAll - All trees.
2: TreePalm - Palm trees.
3: Hemp - All hemp plants.
4: CollectableNode - The small collectable stone, metal and sulfur nodes.
5: BerryBush - Bushes that berries can be picked from.
6: Pumpkin - All Pumpkin patches.
7: Potato - All potato patches.
8: Corn - All corn patches.
9: Fish - Gutting a fish.
10: Boar - Harvested specifically from boars.
11: Chicken - Harvested specifically from chickens.
12: Bear - Harvested specifically from bears.
13: Stag - Harvested specifically from stags.
14: Wolf - Harvested specifically from wolves.
15: Horse - Harvested specifically from horses.
16: Mushroom - All mushroom patches.
17: Animal - All mammals.
18: Default - An item that is obtained by default in Rust.
19: Crafted - An item that needs to be crafted (requires a recipe as well).

HumanNPC - Used if you want the market to be accessed via NPC. Simply adjust the name of the NPC to match what is in the config.
Vanish - Used in the Inivisibility buff type.
NightVision - Used in the NightVision buff type.
Economics - Used for the farmers market and the Wealth buff type.
ServerRewards - Used for the market and the Wealth buff type.

The following calls require an item to have the "Hook" buff type (#17). They can be added to your own plugin and will be called as the plugin requires them.
object GetBuffDescription(ulong skin)
{
if (skin == 2428317574) return "This is sushi and it does stuff";
else return null;
}
This API call is called 30 seconds after the plugin loads, and populates the recipe menu buff description with the relevant info.
void RecipeConsumed(BasePlayer player, string name, string shortname, ulong skin, int duration)
{
Puts($"Consumed food {name} - short: {shortname} - skin: {skin} - duration {duration}");
}
This API call is called when a player eats a meal with the Hook buff type. Returns no information.
object BuffRequiresTimer(BasePlayer player, string name, string shortname, ulong skin)
{
if (skin == 2428317574)
{
return false;
}
return null;
}
This API call is fired just after a meal is consumed to see if the meal requires a buff timer. If false is returned, it will not provide a buff timer/count down, or fire off our next API call.
void RecipeEnded(BasePlayer player, string name, string shortname, ulong skin)
{
Puts($"Effect ended - {name}.");
}
This API call is fired when the buff timer has finished. Returns no information.
bool CanBuyIngredient(BasePlayer player)
{
Puts("Returning false prevents the purchase of an item from the market.");
return false;
}
bool CanSellIngredient(BasePlayer player)
{
Puts("Returning false prevents the sale of an item to the market.");
return false;
}
These API calls are made when a player attempts to buy or sell an ingredient to the farmers market. Returning false prevents the transaction.
void OnIngredientPurchased(BasePlayer player, string ingredient, double cost)
{
Puts($"Player {player.displayName} purchased a {ingredient} from the market for ${cost}");
}
void OnIngredientSold(BasePlayer player, string ingredient, double cost)
{
Puts($"Player {player.displayName} sold an {ingredient} to the market for ${cost}");
}
These calls are made when a player has successfully bought or sold an ingredient to the market.
bool CanGatherIngredient(BasePlayer player, uint source)
Returning a non-null value will prevent players from receiving ingredients from certain drop sources. the source is the networked ID of the entity.
void OnMealCrafed(BasePlayer player, string meal, Dictionary<string, int> ingredients)
Called after a meal has been created and given to the player.