9
0
mirror of https://github.com/Xiao-MoMi/craft-engine.git synced 2025-12-25 01:49:30 +00:00

Merge remote-tracking branch 'upstream/dev' into dev

# Conflicts:
#	bukkit/src/main/java/net/momirealms/craftengine/bukkit/item/factory/ComponentItemFactory1_20_5.java
This commit is contained in:
jhqwqmc
2025-08-10 21:01:25 +08:00
10 changed files with 26 additions and 12 deletions

View File

@@ -56,6 +56,22 @@ public final class CraftEngineBlocks {
return place(location, block, UpdateOption.UPDATE_ALL, playSound);
}
/**
* Place a custom block
*
* @param location location
* @param blockId block owner id
* @param playSound whether to play place sounds
* @return success or not
*/
public static boolean place(@NotNull Location location,
@NotNull Key blockId,
boolean playSound) {
CustomBlock block = byId(blockId);
if (block == null) return false;
return place(location, block.defaultState(), UpdateOption.UPDATE_ALL, playSound);
}
/**
* Place a custom block with given properties
*

View File

@@ -345,11 +345,10 @@ public class ComponentItemFactory1_20_5 extends BukkitItemFactory<ComponentItemW
@Override
protected void unbreakable(ComponentItemWrapper item, boolean unbreakable) {
final Tag emptyTag = new CompoundTag();
if (unbreakable) {
item.setSparrowNBTComponent(ComponentTypes.UNBREAKABLE, emptyTag);
item.setJavaComponent(ComponentTypes.UNBREAKABLE, Map.of());
} else {
item.removeComponent(ComponentTypes.UNBREAKABLE);
item.resetComponent(ComponentTypes.UNBREAKABLE);
}
}

View File

@@ -82,7 +82,7 @@ resource-pack:
prompt: "<yellow>To fully experience our server,<newline>please accept our custom resource pack.</yellow>"
# If you are hosting the resource pack by yourself, replace `localhost` with your server ip otherwise it would only work on your local pc
# If using BungeeCord or Velocity, consider using a proxy-side plugin to handle resource pack delivery.
# Read this page for more host types: https://mo-mi.gitbook.io/xiaomomi-plugins/craftengine/plugin-wiki/craftengine/resource-pack/host
# Read this page for more host types: https://xiao-momi.github.io/craft-engine-wiki/getting_start/set_up_host
hosting:
- type: "self"
ip: "localhost"
@@ -171,7 +171,6 @@ block:
# - Sending custom IDs (e.g., craftengine:note_block_0) to vanilla clients WILL CRASH THEM!
# ✅ Solution:
# - Use `client-bound-item-data` to safely sync custom block data to clients.
# Documentation: https://mo-mi.gitbook.io/xiaomomi-plugins/craftengine/plugin-wiki/craftengine/add-new-contents/items/item-data/client-bound-item-data
simplify-adventure-break-check: false
# Similar to the option above, but designed for block placement
simplify-adventure-place-check: false

View File

@@ -303,7 +303,7 @@ warning.config.loot_table.entry.item.missing_item: "<yellow>Problem in Datei <ar
warning.config.loot_table.condition.missing_type: "<yellow>Problem in Datei <arg:0> gefunden - '<arg:1>' hat eine falsch konfigurierte Beutetabelle, einer der Bedingungen fehlt das erforderliche 'type'-Argument.</yellow>"
warning.config.loot_table.condition.invalid_type: "<yellow>Problem in Datei <arg:0> gefunden - '<arg:1>' hat eine falsch konfigurierte Beutetabelle, einer der Bedingungen verwendet einen ungültigen Bedingungstyp '<arg:2>'.</yellow>"
warning.config.host.missing_type: "<yellow>Problem in config.yml im Abschnitt 'resource-pack.delivery.hosting' gefunden - Fehlendes erforderliches 'type'-Argument für den Host.</yellow>"
warning.config.host.invalid_type: "<yellow>Problem in config.yml im Abschnitt 'resource-pack.delivery.hosting' gefunden - Host-Typ '<arg:0>' ist ungültig. Bitte lesen Sie https://mo-mi.gitbook.io/xiaomomi-plugins/craftengine/plugin-wiki/craftengine/resource-pack/host.</yellow>"
warning.config.host.invalid_type: "<yellow>Problem in config.yml im Abschnitt 'resource-pack.delivery.hosting' gefunden - Host-Typ '<arg:0>' ist ungültig. Bitte lesen Sie https://xiao-momi.github.io/craft-engine-wiki/getting_start/set_up_host.</yellow>"
warning.config.host.external.missing_url: "<yellow>Problem in config.yml im Abschnitt 'resource-pack.delivery.hosting' gefunden - Fehlendes erforderliches 'url'-Argument für den externen Host.</yellow>"
warning.config.host.alist.missing_api_url: "<yellow>Problem in config.yml im Abschnitt 'resource-pack.delivery.hosting' gefunden - Fehlendes erforderliches 'api-url'-Argument für den AList-Host.</yellow>"
warning.config.host.alist.missing_username: "<yellow>Problem in config.yml im Abschnitt 'resource-pack.delivery.hosting' gefunden - Fehlendes erforderliches 'username'-Argument oder Umgebungsvariable 'CE_ALIST_USERNAME' für den AList-Host.</yellow>"

View File

@@ -327,7 +327,7 @@ warning.config.loot_table.entry.item.missing_item: "<yellow>Issue found in file
warning.config.loot_table.condition.missing_type: "<yellow>Issue found in file <arg:0> - '<arg:1>' has a misconfigured loot table, one of the conditions is missing the required 'type' argument.</yellow>"
warning.config.loot_table.condition.invalid_type: "<yellow>Issue found in file <arg:0> - '<arg:1>' has a misconfigured loot table, one of the conditions is using an invalid condition type '<arg:2>'.</yellow>"
warning.config.host.missing_type: "<yellow>Issue found in config.yml at 'resource-pack.delivery.hosting' - Missing required 'type' argument for host.</yellow>"
warning.config.host.invalid_type: "<yellow>Issue found in config.yml at 'resource-pack.delivery.hosting' - Host type '<arg:0>' is invalid. Please read https://mo-mi.gitbook.io/xiaomomi-plugins/craftengine/plugin-wiki/craftengine/resource-pack/host.</yellow>"
warning.config.host.invalid_type: "<yellow>Issue found in config.yml at 'resource-pack.delivery.hosting' - Host type '<arg:0>' is invalid. Please read https://xiao-momi.github.io/craft-engine-wiki/getting_start/set_up_host.</yellow>"
warning.config.host.external.missing_url: "<yellow>Issue found in config.yml at 'resource-pack.delivery.hosting' - Missing required 'url' argument for external host.</yellow>"
warning.config.host.alist.missing_api_url: "<yellow>Issue found in config.yml at 'resource-pack.delivery.hosting' - Missing required 'api-url' argument for alist host.</yellow>"
warning.config.host.alist.missing_username: "<yellow>Issue found in config.yml at 'resource-pack.delivery.hosting' - Missing required 'username' argument or environment variable 'CE_ALIST_USERNAME' for alist host.</yellow>"

View File

@@ -232,7 +232,7 @@ warning.config.loot_table.condition.table_bonus.missing_chances: "<yellow>Proble
warning.config.loot_table.number.missing_type: "<yellow>Problema encontrado en el archivo <arg:0> - '<arg:1>' tiene una tabla de botín mal configurada, uno de los números carece del argumento requerido 'type'.</yellow>"
warning.config.loot_table.number.invalid_type: "<yellow>Problema encontrado en el archivo <arg:0> - '<arg:1>' tiene una tabla de botín mal configurada, uno de los números está usando un tipo de número inválido '<arg:2>'.</yellow>"
warning.config.host.missing_type: "<yellow>Problema encontrado en config.yml en la sección 'resource-pack.delivery.hosting' - Argumento requerido 'type' faltante para el host.</yellow>"
warning.config.host.invalid_type: "<yellow>Problema encontrado en config.yml en la sección 'resource-pack.delivery.hosting' - Tipo de host '<arg:0>' inválido. Por favor lee https://mo-mi.gitbook.io/xiaomomi-plugins/craftengine/plugin-wiki/craftengine/resource-pack/host</yellow>"
warning.config.host.invalid_type: "<yellow>Problema encontrado en config.yml en la sección 'resource-pack.delivery.hosting' - Tipo de host '<arg:0>' inválido. Por favor lee https://xiao-momi.github.io/craft-engine-wiki/getting_start/set_up_host</yellow>"
warning.config.host.external.missing_url: "<yellow>Problema encontrado en config.yml en la sección 'resource-pack.delivery.hosting' - Argumento requerido 'url' faltante para el host externo.</yellow>"
warning.config.host.alist.missing_api_url: "<yellow>Problema encontrado en config.yml en la sección 'resource-pack.delivery.hosting' - Argumento requerido 'api-url' faltante para el host alist.</yellow>"
warning.config.host.alist.missing_username: "<yellow>Problema encontrado en config.yml en la sección 'resource-pack.delivery.hosting' - Argumento requerido 'username' o variable de entorno 'CE_ALIST_USERNAME' faltante para el host alist.</yellow>"

View File

@@ -302,7 +302,7 @@ warning.config.loot_table.entry.item.missing_item: "<yellow>Проблема н
warning.config.loot_table.condition.missing_type: "<yellow>Проблема найдена в файле <arg:0> - '<arg:1>' имеет неправильно настроенную таблицу добычи, в одном из условий отсутствует необходимый 'type' аргумент.</yellow>"
warning.config.loot_table.condition.invalid_type: "<yellow>Проблема найдена в файле <arg:0> - '<arg:1>' имеет неправильно настроенную таблицу добычи, одно из условий имеет недействительный тип условия '<arg:2>'.</yellow>"
warning.config.host.missing_type: "<yellow>Проблема обнаружена в config.yml по адресу 'resource-pack.delivery.hosting' - Отсутствует обязательный 'type' аргумент для хостинга.</yellow>"
warning.config.host.invalid_type: "<yellow>Проблема обнаружена в config.yml по адресу 'resource-pack.delivery.hosting' - Тип хоста '<arg:0>' недействителен. Пожалуйста, прочитайте https://mo-mi.gitbook.io/xiaomomi-plugins/craftengine/plugin-wiki/craftengine/resource-pack/host.</yellow>"
warning.config.host.invalid_type: "<yellow>Проблема обнаружена в config.yml по адресу 'resource-pack.delivery.hosting' - Тип хоста '<arg:0>' недействителен. Пожалуйста, прочитайте https://xiao-momi.github.io/craft-engine-wiki/getting_start/set_up_host.</yellow>"
warning.config.host.external.missing_url: "<yellow>Проблема обнаружена в config.yml по адресу 'resource-pack.delivery.hosting' - Отсутствует обязательный 'url' аргумент для внешнего хоста.</yellow>"
warning.config.host.alist.missing_api_url: "<yellow>Проблема обнаружена в config.yml по адресу 'resource-pack.delivery.hosting' - Отсутствует обязательный 'api-url' аргумент для alist хостинга.</yellow>"
warning.config.host.alist.missing_username: "<yellow>Проблема обнаружена в config.yml по адресу 'resource-pack.delivery.hosting' - Отсутствует обязательный 'username' аргумент или переменная среды 'CE_ALIST_USERNAME' для alist хостинга.</yellow>"

View File

@@ -226,7 +226,7 @@ warning.config.loot_table.entry.item.missing_item: "<yellow><arg:0> dosyasında
warning.config.loot_table.condition.missing_type: "<yellow><arg:0> dosyasında sorun bulundu - '<arg:1>', yanlış yapılandırılmış bir ganimet tablosuna sahip, koşullardan biri için gerekli 'type' argümanı eksik.</yellow>"
warning.config.loot_table.condition.invalid_type: "<yellow><arg:0> dosyasında sorun bulundu - '<arg:1>', yanlış yapılandırılmış bir ganimet tablosuna sahip, koşullardan biri geçersiz bir koşul türü '<arg:2>' kullanıyor.</yellow>"
warning.config.host.missing_type: "<yellow>config.yml dosyasında 'resource-pack.delivery.hosting' bölümünde sorun bulundu - Host için gerekli 'type' argümanı eksik.</yellow>"
warning.config.host.invalid_type: "<yellow>config.yml dosyasında 'resource-pack.delivery.hosting' bölümünde sorun bulundu - Host türü '<arg:0>' geçersiz. Lütfen https://mo-mi.gitbook.io/xiaomomi-plugins/craftengine/plugin-wiki/craftengine/resource-pack/host sayfasını okuyun.</yellow>"
warning.config.host.invalid_type: "<yellow>config.yml dosyasında 'resource-pack.delivery.hosting' bölümünde sorun bulundu - Host türü '<arg:0>' geçersiz. Lütfen https://xiao-momi.github.io/craft-engine-wiki/getting_start/set_up_host sayfasını okuyun.</yellow>"
warning.config.host.external.missing_url: "<yellow>config.yml dosyasında 'resource-pack.delivery.hosting' bölümünde sorun bulundu - Harici host için gerekli 'url' argümanı eksik.</yellow>"
warning.config.host.alist.missing_api_url: "<yellow>config.yml dosyasında 'resource-pack.delivery.hosting' bölümünde sorun bulundu - alist host için gerekli 'api-url' argümanı eksik.</yellow>"
warning.config.host.alist.missing_username: "<yellow>config.yml dosyasında 'resource-pack.delivery.hosting' bölümünde sorun bulundu - alist host için gerekli 'username' argümanı veya 'CE_ALIST_USERNAME' ortam değişkeni eksik.</yellow>"

View File

@@ -327,7 +327,7 @@ warning.config.loot_table.entry.item.missing_item: "<yellow>在文件 <arg:0>
warning.config.loot_table.condition.missing_type: "<yellow>在文件 <arg:0> 发现问题 - '<arg:1>' 的战利品表配置错误 某个条件缺少必需的 'type' 参数</yellow>"
warning.config.loot_table.condition.invalid_type: "<yellow>在文件 <arg:0> 发现问题 - '<arg:1>' 的战利品表配置错误 某个条件使用了无效的条件类型 '<arg:2>'</yellow>"
warning.config.host.missing_type: "<yellow>在 config.yml 的 'resource-pack.delivery.hosting' 处发现问题 - 缺少必需的 'type' 参数</yellow>"
warning.config.host.invalid_type: "<yellow>在 config.yml 的 'resource-pack.delivery.hosting' 处发现问题 - 无效的托管类型 '<arg:0>' 请参考 https://mo-mi.gitbook.io/xiaomomi-plugins/craftengine/plugin-wiki/craftengine/resource-pack/host</yellow>"
warning.config.host.invalid_type: "<yellow>在 config.yml 的 'resource-pack.delivery.hosting' 处发现问题 - 无效的托管类型 '<arg:0>' 请参考 https://xiao-momi.github.io/craft-engine-wiki/getting_start/set_up_host</yellow>"
warning.config.host.external.missing_url: "<yellow>在 config.yml 的 'resource-pack.delivery.hosting' 处发现问题 - 外部托管缺少必需的 'url' 参数</yellow>"
warning.config.host.alist.missing_api_url: "<yellow>在 config.yml 的 'resource-pack.delivery.hosting' 处发现问题 - Alist 托管缺少必需的 'api-url' 参数</yellow>"
warning.config.host.alist.missing_username: "<yellow>在 config.yml 的 'resource-pack.delivery.hosting' 处发现问题 - Alist 托管缺少必需的 'username' 参数或环境变量 'CE_ALIST_USERNAME'</yellow>"

View File

@@ -2,7 +2,7 @@ org.gradle.jvmargs=-Xmx1G
# Project settings
# Rule: [major update].[feature update].[bug fix]
project_version=0.0.61.2
project_version=0.0.61.3
config_version=43
lang_version=23
project_group=net.momirealms