NitWikit/docs/插件/papi变量/概览.md

76 lines
1.4 KiB
Markdown
Raw Normal View History

2024-03-23 17:16:16 +08:00
---
sidebar_position: 1
---
2024-03-24 10:33:19 +08:00
# 概览
2024-03-23 21:06:14 +08:00
2024-04-13 21:56:49 +08:00
:::info
2024-05-04 00:30:59 +08:00
`SpigotMC` :https://www.spigotmc.org/resources/.6245/
2024-04-13 21:56:49 +08:00
`GitHub` :https://github.com/PlaceholderAPI/PlaceholderAPI
2024-05-04 00:30:59 +08:00
`Wiki` :https://wiki.placeholderapi.com/
2024-04-13 21:56:49 +08:00
`插件百科(不推荐,老掉牙了)` :https://mineplugin.org/PlaceholderAPI(%E6%97%A7)
:::
2024-03-23 21:06:14 +08:00
2024-05-02 05:10:19 +08:00
PlaceHolderAPI是一个广泛使用的变量插件,它可以做到 Math(数学运算) Checkitem(操作玩家物品) JavaScript(执行js) Progress(制作进度条) 显示变量 等
2024-03-23 21:06:14 +08:00
2024-05-02 05:10:19 +08:00
## 什么是变量?
2024-03-23 21:06:14 +08:00
2024-05-04 00:30:59 +08:00
这里指的变量是形似 `%player_name%`, 即 `%xxx%` 的占位符
2024-05-02 05:10:19 +08:00
它们用来显示一些信息
如`%player_name%` 是显示玩家名字
`%playerpoints_points%`是显示 PlayerPoints 插件的玩家点券
2024-04-04 21:28:16 +08:00
## 更改 boolean
在`plugins\PlaceholderAPI\config.yml`中找到
```
boolean:
'true': 'yes'
'false': 'no'
```
将yes和no改为true false
2024-04-05 05:31:22 +08:00
不改也没事,就是改成true false会更方便判断
2024-05-02 05:10:19 +08:00
## 在哪寻找我要的变量?
2024-04-05 05:31:22 +08:00
2024-04-13 21:56:49 +08:00
:::info
2024-05-04 00:30:59 +08:00
`Wiki` :https://wiki.placeholderapi.com/
2024-04-13 21:56:49 +08:00
2024-05-02 05:14:08 +08:00
`eCloud` :https://api.extendedclip.com/all/
2024-04-13 21:56:49 +08:00
2024-05-04 00:30:59 +08:00
`Placeholder List` :https://wiki.placeholderapi.com/users/placeholder-list/
2024-04-13 21:56:49 +08:00
:::
2024-04-05 05:31:22 +08:00
2024-05-04 00:30:59 +08:00
## 下载变量扩展
2024-04-05 05:31:22 +08:00
```
/papi ecloud download 扩展名
```
2024-05-02 05:11:54 +08:00
然后执行命令 `/papi reload`
2024-05-02 05:10:19 +08:00
### 没法下载?
2024-04-05 05:31:22 +08:00
![](_images/概览/变量下载失败.png)
看起来你连不上ecloud
手动下载吧 https://api.extendedclip.com/all/
2024-05-02 05:11:54 +08:00
把下载的jar文件塞到 `plugins\PlaceholderAPI\expansions` 文件夹
2024-05-04 00:30:59 +08:00
然后执行命令 `/papi reload`