Bridge

Bridge

A powerful Hytale plugin library for creating, managing, and orchestrating temporary worlds with ease.

41.0 загрузок
Обновлён 15 дней назад

Описание

Библиотека управления Hytale World

Мощная библиотека плагинов Hytale для создания, управления и организации временных миров с легкостью. Bridge предоставляет надежный API для обработки мирового жизненного цикла, переноса игроков и настраиваемого поведения в мире.

Особенности

- Легкое мировое управлениеСоздавать, активировать, деактивировать и удалять миры с помощью простых вызовов API
- Игровые трансферыБезопасное перемещение игроков между мирами со встроенной безопасностью потоков
- Пользовательское мировое поведениеРасширьте «BridgeWorldComponent», чтобы добавить пользовательскую логику в ваши миры
- Асинхронные операции: Большинство операций выполняются асинхронно с дополнительными обратными вызовами
- Мировая конфигурация: Нарушение блока управления, размещение, сбор и настройки PvP
- События жизненного цикла: Погрузитесь в создание мира, удаление и события игроков

API ссылка

BridgeWorldManager:

  1. createWorld (название строки, компонент BridgeWorldComponent, обратный вызов Consumer<BridgeWorld>)
  2. GetAllVBridgeWorlds() - Получить все управляемые миры
  3. GetDefaultWorldAsBridgeWorld() - Получить мир по умолчанию
  4. удалять Мир (BridgeWorld World) - навсегда удалить мир
  5. активировать World (BridgeWorld World, Consumer<BridgeWorld> callback)
  6. деактивировать Мир (BridgeWorld World, World MovePlayers) К)

 

BridgeWorld:

  1. Активировать (Consumer<BridgeWorld> callback - Загрузить мир в память)
  2. Скачать игру World MovePlayersTo - Unload World
  3. TransferPlayer (PlayerRef Player) - Перенесите игрока в этот мир
  4. Удалить (удалить) этот мир и его файлы
  5. setAllowPvP (boolean enabled) - Toggle PvP
  6. setAllowBlockBreaking (boolean enabled) - блокировка Toggle

Методы жизненного цикла BridgeWorldComponent

  1. Оригинальное название: BridgeWorld World: When World Created
  2. ↑ onDeleteWorld (BridgeWorld World) — Before World Deletion (недоступная ссылка — история).
  3. • onPlayerJoinWorld (BridgeWorld World, PlayerRef Player) пункт
  4. • onPlayerLeaveWorld (BridgeWorld World, PlayerRef Player) пункт
  5. • onPlayerDieInWorld (BridgeWorld World, PlayerRef Player) пункт
  6. onTick (BridgeWorld World, Float deltaTime) - Называется каждый тик
Показать оригинальное описание (English)

Bridge - Hytale World Management Library

A powerful Hytale plugin library for creating, managing, and orchestrating temporary worlds with ease. Bridge provides a robust API for handling world lifecycle, player transfers, and customizable world behavior.

✨ Features

- Easy World Management: Create, activate, deactivate, and delete worlds with simple API calls
- Player Transfers: Safely move players between worlds with built-in thread safety
- Custom World Behavior: Extend `BridgeWorldComponent` to add custom logic to your worlds
- Asynchronous Operations: Most operations run asynchronously with optional callbacks
- World Configuration: Control block breaking, placement, gathering, and PvP settings
- Lifecycle Events: Hook into world creation, deletion, and player events

📖 API Reference

BridgeWorldManager:

  1. createWorld(String name, BridgeWorldComponent component, Consumer<BridgeWorld> callback)
  2. getAllVBridgeWorlds() - Get all managed worlds
  3. getDefaultWorldAsBridgeWorld() - Get the default world
  4. deleteWorld(BridgeWorld world) - Permanently delete a world
  5. activateWorld(BridgeWorld world, Consumer<BridgeWorld> callback)
  6. deactivateWorld(BridgeWorld world, World movePlayersTo)

 

BridgeWorld:

  1. activate(Consumer<BridgeWorld> callback) - Load world into memory
  2. deactivate(World movePlayersTo)` - Unload world
  3. transferPlayer(PlayerRef player) - Move player to this world
  4. delete() - Delete this world and its files
  5. setAllowPvP(boolean enabled) - Toggle PvP
  6. setAllowBlockBreaking(boolean enabled) - Toggle block breaking

BridgeWorldComponent Lifecycle Methods:

  1. onCreateWorld(BridgeWorld world)` - When world is created
  2. onDeleteWorld(BridgeWorld world)` - Before world deletion
  3. onPlayerJoinWorld(BridgeWorld world, PlayerRef player)`
  4. onPlayerLeaveWorld(BridgeWorld world, PlayerRef player)`
  5. onPlayerDieInWorld(BridgeWorld world, PlayerRef player)`
  6. onTick(BridgeWorld world, float deltaTime)` - Called every tick

Последние версии

BridgePlugin-1.0.jar

Early Access 19.01.2026 21.8 КБ
Скачать