▶️ ЗАБЕРИ СВОИ 8 ПОДАРКОВ 🎁 ПРИ СОЗДАНИИ СВОЕГО МАЙНКРАФТ СЕРВЕРА
Моды/Trust API
Trust API

Trust API

This project adds an optimized trust api for plugins and skripts.

1
0

Trust API

Directional trust API for Paper plugins with optional Skript syntax.

Features

  • Java API: TrustService (trust, untrust, trusts, getTrusted)
  • Service registration through Bukkit ServicesManager
  • Persistence to plugins/Trust API/trusts.yml
  • Skript effect:
    • make %player% trust %player%
    • make %player% to trust %player%
    • make %player% not trust %player%
  • Skript condition:
    • %player% trusts %player%
  • Command:
    • /trust add <player> [trusted]
    • /trust remove <player> [trusted]
    • /trust list [player] (opens chest GUI with trusted player heads)

Skript usage

command /testtrust:
  trigger:
    make player to trust arg-1

command /testuntrust:
  trigger:
    make player not trust arg-1

on damage:
  attacker is a player
  victim is a player
  if attacker trusts victim:
    send "You trust this player." to attacker

Java usage

import me.thesnowbound.trustAPI.api.TrustApiProvider;

TrustApiProvider.get().ifPresent(service -> {
    if (service.trusts(attacker.getUniqueId(), victim.getUniqueId())) {
        // your logic
    }
});

Совместимость

Minecraft: Java Edition

26.1.x1.21.x

Платформы

Поддерживаемые окружения

Сервер

Детали

Лицензия:LicenseRef-All-Rights-Reserved
Опубликован:1 неделю назад
Обновлён:1 неделю назад
Главная