2021-06-11 14:02:28 +02:00
|
|
|
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
|
|
|
From: zbk <zbk@projectsolaris.net>
|
|
|
|
Date: Sun, 26 Apr 2020 23:49:03 -0400
|
|
|
|
Subject: [PATCH] Villager Restocks API
|
|
|
|
|
|
|
|
|
|
|
|
diff --git a/src/main/java/org/bukkit/entity/Villager.java b/src/main/java/org/bukkit/entity/Villager.java
|
2024-07-18 10:13:20 +02:00
|
|
|
index cfa0d4809f9bb4ac150251efa85ba4d1808ab1b2..ecb0f32a4449f8000248c4bebf89a56df186899f 100644
|
2021-06-11 14:02:28 +02:00
|
|
|
--- a/src/main/java/org/bukkit/entity/Villager.java
|
|
|
|
+++ b/src/main/java/org/bukkit/entity/Villager.java
|
2024-07-18 10:13:20 +02:00
|
|
|
@@ -82,6 +82,20 @@ public interface Villager extends AbstractVillager {
|
2021-06-11 14:02:28 +02:00
|
|
|
*/
|
|
|
|
public void setVillagerExperience(int experience);
|
|
|
|
|
|
|
|
+ // Paper start
|
|
|
|
+ /**
|
|
|
|
+ * Gets the amount of times a villager has restocked their trades today
|
|
|
|
+ * @return The amount of trade restocks.
|
|
|
|
+ */
|
|
|
|
+ public int getRestocksToday();
|
|
|
|
+
|
|
|
|
+ /**
|
|
|
|
+ * Sets the amount of times a villager has restocked their trades today
|
|
|
|
+ * @param restocksToday new restock count
|
|
|
|
+ */
|
|
|
|
+ public void setRestocksToday(int restocksToday);
|
|
|
|
+ // Paper end
|
|
|
|
+
|
|
|
|
/**
|
|
|
|
* Attempts to make this villager sleep at the given location.
|
|
|
|
* <br>
|