geforkt von Mirrors/Paper
SPIGOT-5484: Add more spawn tick settings
By: Phoenix616 <mail@moep.tv>
Dieser Commit ist enthalten in:
Ursprung
5fee1ac76f
Commit
b35aa20f22
@ -353,6 +353,50 @@ public final class Bukkit {
|
|||||||
return server.getTicksPerMonsterSpawns();
|
return server.getTicksPerMonsterSpawns();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Gets the default ticks per water mob spawns value.
|
||||||
|
* <p>
|
||||||
|
* <b>Example Usage:</b>
|
||||||
|
* <ul>
|
||||||
|
* <li>A value of 1 will mean the server will attempt to spawn water mobs
|
||||||
|
* every tick.
|
||||||
|
* <li>A value of 400 will mean the server will attempt to spawn water mobs
|
||||||
|
* every 400th tick.
|
||||||
|
* <li>A value below 0 will be reset back to Minecraft's default.
|
||||||
|
* </ul>
|
||||||
|
* <p>
|
||||||
|
* <b>Note:</b> If set to 0, water mobs spawning will be disabled.
|
||||||
|
* <p>
|
||||||
|
* Minecraft default: 1.
|
||||||
|
*
|
||||||
|
* @return the default ticks per water mobs spawn value
|
||||||
|
*/
|
||||||
|
public static int getTicksPerWaterSpawns() {
|
||||||
|
return server.getTicksPerWaterSpawns();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Gets the default ticks per ambient mob spawns value.
|
||||||
|
* <p>
|
||||||
|
* <b>Example Usage:</b>
|
||||||
|
* <ul>
|
||||||
|
* <li>A value of 1 will mean the server will attempt to spawn ambient mobs
|
||||||
|
* every tick.
|
||||||
|
* <li>A value of 400 will mean the server will attempt to spawn ambient mobs
|
||||||
|
* every 400th tick.
|
||||||
|
* <li>A value below 0 will be reset back to Minecraft's default.
|
||||||
|
* </ul>
|
||||||
|
* <p>
|
||||||
|
* <b>Note:</b> If set to 0, ambient mobs spawning will be disabled.
|
||||||
|
* <p>
|
||||||
|
* Minecraft default: 1.
|
||||||
|
*
|
||||||
|
* @return the default ticks per ambient mobs spawn value
|
||||||
|
*/
|
||||||
|
public static int getTicksPerAmbientSpawns() {
|
||||||
|
return server.getTicksPerAmbientSpawns();
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Gets a player object by the given username.
|
* Gets a player object by the given username.
|
||||||
* <p>
|
* <p>
|
||||||
|
@ -294,6 +294,46 @@ public interface Server extends PluginMessageRecipient {
|
|||||||
*/
|
*/
|
||||||
public int getTicksPerMonsterSpawns();
|
public int getTicksPerMonsterSpawns();
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Gets the default ticks per water mob spawns value.
|
||||||
|
* <p>
|
||||||
|
* <b>Example Usage:</b>
|
||||||
|
* <ul>
|
||||||
|
* <li>A value of 1 will mean the server will attempt to spawn water mobs
|
||||||
|
* every tick.
|
||||||
|
* <li>A value of 400 will mean the server will attempt to spawn water mobs
|
||||||
|
* every 400th tick.
|
||||||
|
* <li>A value below 0 will be reset back to Minecraft's default.
|
||||||
|
* </ul>
|
||||||
|
* <p>
|
||||||
|
* <b>Note:</b> If set to 0, water mobs spawning will be disabled.
|
||||||
|
* <p>
|
||||||
|
* Minecraft default: 1.
|
||||||
|
*
|
||||||
|
* @return the default ticks per water mobs spawn value
|
||||||
|
*/
|
||||||
|
public int getTicksPerWaterSpawns();
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Gets the default ticks per ambient mob spawns value.
|
||||||
|
* <p>
|
||||||
|
* <b>Example Usage:</b>
|
||||||
|
* <ul>
|
||||||
|
* <li>A value of 1 will mean the server will attempt to spawn ambient mobs
|
||||||
|
* every tick.
|
||||||
|
* <li>A value of 400 will mean the server will attempt to spawn ambient mobs
|
||||||
|
* every 400th tick.
|
||||||
|
* <li>A value below 0 will be reset back to Minecraft's default.
|
||||||
|
* </ul>
|
||||||
|
* <p>
|
||||||
|
* <b>Note:</b> If set to 0, ambient mobs spawning will be disabled.
|
||||||
|
* <p>
|
||||||
|
* Minecraft default: 1.
|
||||||
|
*
|
||||||
|
* @return the default ticks per ambient mobs spawn value
|
||||||
|
*/
|
||||||
|
public int getTicksPerAmbientSpawns();
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Gets a player object by the given username.
|
* Gets a player object by the given username.
|
||||||
* <p>
|
* <p>
|
||||||
|
@ -1636,6 +1636,104 @@ public interface World extends PluginMessageRecipient, Metadatable {
|
|||||||
*/
|
*/
|
||||||
public void setTicksPerMonsterSpawns(int ticksPerMonsterSpawns);
|
public void setTicksPerMonsterSpawns(int ticksPerMonsterSpawns);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Gets the world's ticks per water mob spawns value
|
||||||
|
* <p>
|
||||||
|
* This value determines how many ticks there are between attempts to
|
||||||
|
* spawn water mobs.
|
||||||
|
* <p>
|
||||||
|
* <b>Example Usage:</b>
|
||||||
|
* <ul>
|
||||||
|
* <li>A value of 1 will mean the server will attempt to spawn water mobs in
|
||||||
|
* this world every tick.
|
||||||
|
* <li>A value of 400 will mean the server will attempt to spawn water mobs
|
||||||
|
* in this world every 400th tick.
|
||||||
|
* <li>A value below 0 will be reset back to Minecraft's default.
|
||||||
|
* </ul>
|
||||||
|
* <p>
|
||||||
|
* <b>Note:</b>
|
||||||
|
* If set to 0, water mobs spawning will be disabled for this world.
|
||||||
|
* <p>
|
||||||
|
* Minecraft default: 1.
|
||||||
|
*
|
||||||
|
* @return The world's ticks per water mob spawns value
|
||||||
|
*/
|
||||||
|
public long getTicksPerWaterSpawns();
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Sets the world's ticks per water mob spawns value
|
||||||
|
* <p>
|
||||||
|
* This value determines how many ticks there are between attempts to
|
||||||
|
* spawn water mobs.
|
||||||
|
* <p>
|
||||||
|
* <b>Example Usage:</b>
|
||||||
|
* <ul>
|
||||||
|
* <li>A value of 1 will mean the server will attempt to spawn water mobs in
|
||||||
|
* this world on every tick.
|
||||||
|
* <li>A value of 400 will mean the server will attempt to spawn water mobs
|
||||||
|
* in this world every 400th tick.
|
||||||
|
* <li>A value below 0 will be reset back to Minecraft's default.
|
||||||
|
* </ul>
|
||||||
|
* <p>
|
||||||
|
* <b>Note:</b>
|
||||||
|
* If set to 0, water mobs spawning will be disabled for this world.
|
||||||
|
* <p>
|
||||||
|
* Minecraft default: 1.
|
||||||
|
*
|
||||||
|
* @param ticksPerWaterSpawns the ticks per water mob spawns value you
|
||||||
|
* want to set the world to
|
||||||
|
*/
|
||||||
|
public void setTicksPerWaterSpawns(int ticksPerWaterSpawns);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Gets the world's ticks per ambient mob spawns value
|
||||||
|
* <p>
|
||||||
|
* This value determines how many ticks there are between attempts to
|
||||||
|
* spawn ambient mobs.
|
||||||
|
* <p>
|
||||||
|
* <b>Example Usage:</b>
|
||||||
|
* <ul>
|
||||||
|
* <li>A value of 1 will mean the server will attempt to spawn ambient mobs in
|
||||||
|
* this world every tick.
|
||||||
|
* <li>A value of 400 will mean the server will attempt to spawn ambient mobs
|
||||||
|
* in this world every 400th tick.
|
||||||
|
* <li>A value below 0 will be reset back to Minecraft's default.
|
||||||
|
* </ul>
|
||||||
|
* <p>
|
||||||
|
* <b>Note:</b>
|
||||||
|
* If set to 0, ambient mobs spawning will be disabled for this world.
|
||||||
|
* <p>
|
||||||
|
* Minecraft default: 1.
|
||||||
|
*
|
||||||
|
* @return The world's ticks per ambient mob spawns value
|
||||||
|
*/
|
||||||
|
public long getTicksPerAmbientSpawns();
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Sets the world's ticks per ambient mob spawns value
|
||||||
|
* <p>
|
||||||
|
* This value determines how many ticks there are between attempts to
|
||||||
|
* spawn ambient mobs.
|
||||||
|
* <p>
|
||||||
|
* <b>Example Usage:</b>
|
||||||
|
* <ul>
|
||||||
|
* <li>A value of 1 will mean the server will attempt to spawn ambient mobs in
|
||||||
|
* this world on every tick.
|
||||||
|
* <li>A value of 400 will mean the server will attempt to spawn ambient mobs
|
||||||
|
* in this world every 400th tick.
|
||||||
|
* <li>A value below 0 will be reset back to Minecraft's default.
|
||||||
|
* </ul>
|
||||||
|
* <p>
|
||||||
|
* <b>Note:</b>
|
||||||
|
* If set to 0, ambient mobs spawning will be disabled for this world.
|
||||||
|
* <p>
|
||||||
|
* Minecraft default: 1.
|
||||||
|
*
|
||||||
|
* @param ticksPerAmbientSpawns the ticks per ambient mob spawns value you
|
||||||
|
* want to set the world to
|
||||||
|
*/
|
||||||
|
public void setTicksPerAmbientSpawns(int ticksPerAmbientSpawns);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Gets limit for number of monsters that can spawn in a chunk in this
|
* Gets limit for number of monsters that can spawn in a chunk in this
|
||||||
* world
|
* world
|
||||||
|
Laden…
In neuem Issue referenzieren
Einen Benutzer sperren