已被占用或您领地的有关信息 | --- ### › [API](https://github.com/kainlighty/LightShowRegion/tree/master/API/src/main/java/ru/kainlight/lightshowregion/API) #### Maven: ```xml
> **依赖项: [PLACEHOLDERAPI](https://github.com/PlaceholderAPI/PlaceholderAPI/releases)**
---
### › 特性
- 显示或隐藏全局区域
- 显示是否是您的区域 _(拥有者或成员)_
- 显示该区域是否被占用 _(如果您不是拥有者或成员)_
- 区域黑名单
- 区域重命名 _(例如,出生区域的输出为 &6SPAWN)_
- 完全支持 WorldGuard
---
### › 预览
---
### › 指令和权限
| 指令 | 描述 | 权限 |
|----------------------------------------------------|-----------------------------------------------------|----------------------------------|
| lightshowregion / lsr | 帮助指令列表 | lightshowregion.help |
| lightshowregion toggle (\/\) | 切换区域显示方式 | lightshowregion.toggle |
| lightshowregion add \ \ | 为区域添加自定义名称 | lightshowregion.add |
| lightshowregion remove \ | 移除自定义名称 | lightshowregion.remove |
| lightshowregion blacklist add \ | 将区域添加到黑名单 | lightshowregion.blacklist.add |
| lightshowregion blacklist remove \ | 将区域从黑名单移除 | lightshowregion.blacklist.remove |
| lightshowregion global | 切换全局区域显示 | lightshowregion.global |
| lightshowregion reload actionbar | 为所有在线玩家重新加载 ActionBar | lightshowregion.reload.actionbar |
| lightshowregion reload bossbar | 为所有在线玩家重新加载 BossBar | lightshowregion.reload.bossbar |
| lightshowregion reload bars | 为所有在线玩家重新加载 ActionBar 和 BossBar | lightshowregion.reload.bars |
| lightshowregion reload config | 重新加载所有配置 | lightshowregion.reload.config |
| 没有指令的权限 | 描述 |
|------------------------------|--------------------------------------------------|
| lightshowregion.blacklist.* | 管理黑名单的所有权限 |
| lightshowregion.reload.* | 重新加载 ActionBar、BossBar 和配置的访问权限 |
| lightshowregion.* | 插件的全部访问权限 |
| 占位符 | 描述 |
|--------------------------|-------------------------------------------------------------------|
| %lightshowregion_custom% | 显示有关免费、
已被占用或您领地的有关信息 | --- ### › [API](https://github.com/kainlighty/LightShowRegion/tree/master/API/src/main/java/ru/kainlight/lightshowregion/API) #### Maven: ```xml
ru.kainlight.lightshowregion
api
CURRENT_VERSION
provided
```
#### Gradle — Groovy DSL:
```groovy
repositories {
mavenCentral()
maven {
name = "GitHubPackages"
url = "https://maven.pkg.github.com/kainlighty/LightShowRegion"
}
}
dependencies {
compileOnly 'ru.kainlight.lightshowregion:api:CURRENT_VERSION'
}
```
#### Gradle — Kotlin DSL:
```kotlin
repositories {
mavenCentral()
maven {
name = "GitHubPackages"
url = uri("https://maven.pkg.github.com/kainlighty/LightShowRegion")
}
}
dependencies {
compileOnly("ru.kainlight.lightshowregion:api:CURRENT_VERSION")
}
```
---
#### 方法:
> 获取提供者: `LightShowRegionAPI.getProvider()`
| API | 描述 |
|-----------------------------------------|------------------------------------------------|
| createShowedPlayer(Player) | 为显示区域创建玩家 |
| getOrCreateShowedPlayer(Player) | 获取或创建玩家以显示区域 |
| deleteShowedPlayer(Player/ShowedPlayer) | 删除显示的玩家 |
| getShowedPlayer(Player) | 获取显示区域的玩家 |
| getShowedPlayers() | 获取玩家列表 |
| isShowedPlayer(Player) | 检查玩家是否为 ShowedPlayer |
| reloadActionbar(Player) | 为玩家重新加载 ActionBar |
| reloadActionbars() | 为所有玩家重新加载 ActionBar |
| unloadActionbars() | 为所有玩家卸载 ActionBar |
| reloadBossbar(Player) | 为玩家重新加载 BossBar |
| reloadBossbars() | 为所有玩家重新加载 BossBar |
| unloadBossbars() | 为所有玩家卸载 BossBar |
| addDisabledWorld(name) | 将区域添加到黑名单 |
| getDisabledWorlds() | 获取已禁用的世界列表 |
| removeDisabledWorld(name) | 从黑名单中移除区域 |
| getRegionHandler() | 获取正在检测的玩家 |
| RegionHandler | 描述 |
|---------------------------------------|----------------------------------------------------|
| addCustomRegion(regionId, regionName) | 添加自定义区域 |
| getCustomRegionName(Player) | 获取玩家所在区域的自定义名称 |
| removeCustomRegion(regionId) | 删除自定义区域 |
| getCustomRegionIds() | 获取自定义区域 ID |
| isCustomRegion(id) | 检查区域是否为自定义 |
| addBlacklist(regionId) | 将区域添加到黑名单 |
| getBlacklist() | 获取黑名单 |
| removeBlacklist(regionId) | 从黑名单中移除区域 |
| isGlobalRegion() | 检查是否启用了全局区域显示 |
| setGlobalRegion () | 设置全局区域显示 |
| ShowedPlayer | 描述 |
|----------------|-----------------------------------------------------------------|
| getPlayer() | 获取一个 bukkit 玩家 |
| getActionbar() | 获取 ActionBar 的参数 |
| getBossbar() | 获取 BossBar 的参数 |
| toggleAll() | 在 ActionBar 和 BossBar 中切换所有区域显示 |
| showAll() | 显示 ActionBar 和 BossBar |
| hideAll() | 隐藏 ActionBar 和 BossBar |
| ActionBar \| Bossbar | 描述 |
|----------------------|------------------------------------------|
| toggle() | 切换显示 |
| show() | 显示 |
| hide() | 隐藏 |
| isActive() | 检查显示是否活跃 |
已被占用或您领地的有关信息 | --- ### › [API](https://github.com/kainlighty/LightShowRegion/tree/master/API/src/main/java/ru/kainlight/lightshowregion/API) #### Maven: ```xml