org.bukkit.Server.getTicksPerAnimalSpawns()方法的使用及代码示例

x33g5p2x  于2022-01-30 转载在 其他  
字(1.4k)|赞(0)|评价(0)|浏览(114)

本文整理了Java中org.bukkit.Server.getTicksPerAnimalSpawns()方法的一些代码示例,展示了Server.getTicksPerAnimalSpawns()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Server.getTicksPerAnimalSpawns()方法的具体详情如下:
包路径:org.bukkit.Server
类名称:Server
方法名:getTicksPerAnimalSpawns

Server.getTicksPerAnimalSpawns介绍

[英]Gets default ticks per animal spawns value.

Example Usage:

  • A value of 1 will mean the server will attempt to spawn monsters every tick.
  • A value of 400 will mean the server will attempt to spawn monsters every 400th tick.
  • A value below 0 will be reset back to Minecraft's default.

Note: If set to 0, animal spawning will be disabled. We recommend using spawn-animals to control this instead.

Minecraft default: 400.
[中]

代码示例

代码示例来源:origin: Bukkit/Bukkit

/**
 * @see Server#getTicksPerAnimalSpawns()
 */
public static int getTicksPerAnimalSpawns() {
  return server.getTicksPerAnimalSpawns();
}

代码示例来源:origin: SpigotMC/Spigot-API

/**
 * @see Server#getTicksPerAnimalSpawns()
 */
public static int getTicksPerAnimalSpawns() {
  return server.getTicksPerAnimalSpawns();
}

代码示例来源:origin: EngineHub/WorldGuard

spawning.append("Animal Spawn Limit", server.getAnimalSpawnLimit());
spawning.append("Monster Spawn Limit", server.getMonsterSpawnLimit());
spawning.append("Ticks per Animal Spawn", server.getTicksPerAnimalSpawns());
spawning.append("Ticks per Monster Spawn", server.getTicksPerMonsterSpawns());
append(spawning.getTitle(), spawning);

相关文章

Server类方法