rostov114
Changes the logic of work of vending machines inside the zone

Supported Games
GameServerKingsGameServerKings
depends on

This plugin implements the logic of NPC vending machines in user vending machines located inside the specified zone. There is support for items with skins.

Configuration

Default Configuration

{  
  "Remove payment item": true,  
  "List zones": []
}  

List zones - The list of zones in which the plugin will work.

Remove payment item - Flag to delete payment item. If set to false, the payment item will not be deleted.

Hooks

object CanGiveSoldItem(VendingMachine vending, Item soldItem, BasePlayer buyer)

Called when a product is purchased at a vending machine located inside the zone. Returning a non-null value overrides default behavior.

object CanTakeCurrencyItem(VendingMachine vending, Item takenCurrencyItem)

Called when trying to remove a payment item from a vending machine inside the zone. Returning a non-null value overrides default behavior.

MIT License

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.