Christmas+

Deci

Пользователь
Сообщения
31
Решения
1
Плагин
Christmas+
Ядро сервера
  1. Другое
Версия сервера
  1. 1.19
Кто использовал этот плагин? Есть вопрос. Можно ли добавить в календарь больше 28 дней? Я так понимаю он на это особо не расчитан, ибо создан для "Кристмаса", а не Россиянского НГ. И ещё. Возможно ли Календарь растянуть и на Январь. Насколько понимаю он смотрит серверное время? И на его основе выставляет дату?
 
Последнее редактирование:
Deci, войди в конфиг adventcalendar.yml и найди строчку: days, число 24 меняем на 31
У меня после этого календарь перестаёт работать. Максимальное число, которое выставляется это 28 дней.
 
У меня после этого календарь перестаёт работать. Максимальное число, которое выставляется это 28 дней.
Что-то в консоли пишет? Если да, то можешь выложить с вставкой в
Код:
 
Deci, попробуй этот конфиг:
YAML:
#Name of the advent calendar inventory
inventoryName: "&2&lAdvent calendar"
#Number of the month the advent calendar will be enabled in. Note: Changing this value requires database reset
month: 12
#Number of days in the advent calendar
days: 31
#Choose whether the day number should be displayed as the item quantity in advent calendar GUI
displayDayNumber: true
#Choose whether players should be able to claim gifts from previous days they haven't claimed yet
allowClaimingUnclaimedGifts: true
#Choose whether it should be broadcasted globally when someone claims their gift
broadcastClaimedInfo: true
#Choose whether players should be notified about not claimed gifts when joining the server
notifyUponLogin: true
#Maximal amount of enchantments which can be applied to an item (it applies to enchantment gifts)
maxEnchantments: 3
placeholders:
  #Item placeholder for already claimed gifts
  claimed:
    material: STAINED_GLASS_PANE
    damage: 13
    #%day% is the placeholder for the day number
    name: "&2&lDay %day%"
    lore:
      - "&8Already claimed."
  #Item placeholder for gifts which weren't claimed but can be
  unclaimed:
    material: STAINED_GLASS_PANE
    damage: 5
    name: "&a&lDay %day%"
    lore:
      - "&8Click to claim!"
  #Item placeholder for gifts which weren't claimed and can't be
  expired:
    material: STAINED_GLASS_PANE
    damage: 14
    name: "&c&lDay %day%"
    lore:
      - "&8Gift has expired."
  #Item placeholder for today's gift
  current:
    material: STAINED_GLASS_PANE
    damage: 5
    name: "&a&lDay %day%"
    lore:
      - "&8Click to claim!"
  #Item placeholder for gifts from upcoming days
  upcoming:
    material: STAINED_GLASS_PANE
    damage: 14
    name: "&c&lDay %day%"
    lore:
      - "&8Can't be claimed yet."
  #Item placeholder for not configured gifts
  unavailable:
    material: STAINED_GLASS_PANE
    damage: 14
    name: "&c&lDay %day%"
    lore:
      - "&8This gift is unavailable."
#Gift priorities. The format is PRIORITY:NAME (the name is used in the section below). Basically the higher priority, the earlier player will be checked for the christmasplus.adventcalendar.gift.NAME permissions. "default" is necessary and will be given to all players without any additional permission.
#Example: with 1: default and 2: donor the player will be checked for christmasplus.adventcalendar.gift.donor first, if they don't have it they will receive the "default" one
giftsPriorities:
  1: default
  2: donor
gifts:
  #Day number
  1:
    #Type of the gift, explained above in giftPriorities section
    default:
    #Type of sold item, valid values are item/permission/enchantment/command
      type: item
      item:
        #Material name, full list can be found here: http://wiki.brcdev.net/Materials
        material: BREAD
        #(optional) Quantity of the item
        quantity: 32
        #(optional) Data value, for example 1 for WOOD:1 means spruce wood planks
        damage: 0
        #(optional) Custom name
        name: "&aYummy bread"
        #(optional) Lore, can contain multiple lines
        lore:
          - "&3<3"
    donor:
      type: item
      item:
        material: BREAD
        quantity: 64
  2:
    default:
      type: item
      item:
        material: GOLD_INGOT
        quantity: 16
    donor:
      type: item
      item:
        material: GOLD_INGOT
        quantity: 32
  3:
    default:
      type: item
      item:
        material: IRON_INGOT
        quantity: 32
    donor:
      type: item
      item:
        material: DIAMOND
        quantity: 16
  4:
    default:
      type: enchantment
      enchantment: FORTUNE
      enchantmentLevel: 1
    donor:
      type: enchantment
      enchantment: FORTUNE
      enchantmentLevel: 2
  5:
    default:
      type: command
      commands:
          - "say Merry christmas, %PLAYER%!"
    donor:
      type: command
      commands:
          - "say Merry christmas, %PLAYER%!"
          - "broadcast Merry christmas, everyone!"
 
Deci, попробуй этот конфиг:
YAML:
#Name of the advent calendar inventory
inventoryName: "&2&lAdvent calendar"
#Number of the month the advent calendar will be enabled in. Note: Changing this value requires database reset
month: 12
#Number of days in the advent calendar
days: 31
#Choose whether the day number should be displayed as the item quantity in advent calendar GUI
displayDayNumber: true
#Choose whether players should be able to claim gifts from previous days they haven't claimed yet
allowClaimingUnclaimedGifts: true
#Choose whether it should be broadcasted globally when someone claims their gift
broadcastClaimedInfo: true
#Choose whether players should be notified about not claimed gifts when joining the server
notifyUponLogin: true
#Maximal amount of enchantments which can be applied to an item (it applies to enchantment gifts)
maxEnchantments: 3
placeholders:
  #Item placeholder for already claimed gifts
  claimed:
    material: STAINED_GLASS_PANE
    damage: 13
    #%day% is the placeholder for the day number
    name: "&2&lDay %day%"
    lore:
      - "&8Already claimed."
  #Item placeholder for gifts which weren't claimed but can be
  unclaimed:
    material: STAINED_GLASS_PANE
    damage: 5
    name: "&a&lDay %day%"
    lore:
      - "&8Click to claim!"
  #Item placeholder for gifts which weren't claimed and can't be
  expired:
    material: STAINED_GLASS_PANE
    damage: 14
    name: "&c&lDay %day%"
    lore:
      - "&8Gift has expired."
  #Item placeholder for today's gift
  current:
    material: STAINED_GLASS_PANE
    damage: 5
    name: "&a&lDay %day%"
    lore:
      - "&8Click to claim!"
  #Item placeholder for gifts from upcoming days
  upcoming:
    material: STAINED_GLASS_PANE
    damage: 14
    name: "&c&lDay %day%"
    lore:
      - "&8Can't be claimed yet."
  #Item placeholder for not configured gifts
  unavailable:
    material: STAINED_GLASS_PANE
    damage: 14
    name: "&c&lDay %day%"
    lore:
      - "&8This gift is unavailable."
#Gift priorities. The format is PRIORITY:NAME (the name is used in the section below). Basically the higher priority, the earlier player will be checked for the christmasplus.adventcalendar.gift.NAME permissions. "default" is necessary and will be given to all players without any additional permission.
#Example: with 1: default and 2: donor the player will be checked for christmasplus.adventcalendar.gift.donor first, if they don't have it they will receive the "default" one
giftsPriorities:
  1: default
  2: donor
gifts:
  #Day number
  1:
    #Type of the gift, explained above in giftPriorities section
    default:
    #Type of sold item, valid values are item/permission/enchantment/command
      type: item
      item:
        #Material name, full list can be found here: http://wiki.brcdev.net/Materials
        material: BREAD
        #(optional) Quantity of the item
        quantity: 32
        #(optional) Data value, for example 1 for WOOD:1 means spruce wood planks
        damage: 0
        #(optional) Custom name
        name: "&aYummy bread"
        #(optional) Lore, can contain multiple lines
        lore:
          - "&3<3"
    donor:
      type: item
      item:
        material: BREAD
        quantity: 64
  2:
    default:
      type: item
      item:
        material: GOLD_INGOT
        quantity: 16
    donor:
      type: item
      item:
        material: GOLD_INGOT
        quantity: 32
  3:
    default:
      type: item
      item:
        material: IRON_INGOT
        quantity: 32
    donor:
      type: item
      item:
        material: DIAMOND
        quantity: 16
  4:
    default:
      type: enchantment
      enchantment: FORTUNE
      enchantmentLevel: 1
    donor:
      type: enchantment
      enchantment: FORTUNE
      enchantmentLevel: 2
  5:
    default:
      type: command
      commands:
          - "say Merry christmas, %PLAYER%!"
    donor:
      type: command
      commands:
          - "say Merry christmas, %PLAYER%!"
          - "broadcast Merry christmas, everyone!"
Что-то в консоли пишет? Если да, то можешь выложить с вставкой в
Код:

Код:
[19:09:46 ERROR]: null
org.bukkit.command.CommandException: Unhandled exception executing command 'adventcalendar' in plugin ChristmasPlus v2.16.1
        at org.bukkit.command.PluginCommand.execute(PluginCommand.java:47) ~[patched_1.16.4.jar:git-Yatopia-"a47bfa7"]
        at org.bukkit.command.SimpleCommandMap.dispatch(SimpleCommandMap.java:159) ~[patched_1.16.4.jar:git-Yatopia-"a47bfa7"]
        at org.bukkit.craftbukkit.v1_16_R3.CraftServer.dispatchCommand(CraftServer.java:802) ~[patched_1.16.4.jar:git-Yatopia-"a47bfa7"]
        at net.minecraft.server.v1_16_R3.PlayerConnection.handleCommand(PlayerConnection.java:2032) ~[patched_1.16.4.jar:git-Yatopia-"a47bfa7"]
        at net.minecraft.server.v1_16_R3.PlayerConnection.c(PlayerConnection.java:1843) ~[patched_1.16.4.jar:git-Yatopia-"a47bfa7"]
        at net.minecraft.server.v1_16_R3.PlayerConnection.a(PlayerConnection.java:1796) ~[patched_1.16.4.jar:git-Yatopia-"a47bfa7"]
        at net.minecraft.server.v1_16_R3.PacketPlayInChat.a(PacketPlayInChat.java:47) ~[patched_1.16.4.jar:git-Yatopia-"a47bfa7"]
        at net.minecraft.server.v1_16_R3.PacketPlayInChat.a(PacketPlayInChat.java:5) ~[patched_1.16.4.jar:git-Yatopia-"a47bfa7"]
        at net.minecraft.server.v1_16_R3.PlayerConnectionUtils.lambda$ensureMainThread$1(PlayerConnectionUtils.java:43) ~[patched_1.16.4.jar:git-Yatopia-"a47bfa7"]
        at net.minecraft.server.v1_16_R3.TickTask.run(SourceFile:18) ~[patched_1.16.4.jar:git-Yatopia-"a47bfa7"]
        at net.minecraft.server.v1_16_R3.IAsyncTaskHandler.executeTask(IAsyncTaskHandler.java:151) ~[patched_1.16.4.jar:git-Yatopia-"a47bfa7"]
        at net.minecraft.server.v1_16_R3.IAsyncTaskHandlerReentrant.executeTask(SourceFile:23) ~[patched_1.16.4.jar:git-Yatopia-"a47bfa7"]
        at net.minecraft.server.v1_16_R3.IAsyncTaskHandler.executeNext(IAsyncTaskHandler.java:114) ~[patched_1.16.4.jar:git-Yatopia-"a47bfa7"]
        at net.minecraft.server.v1_16_R3.MinecraftServer.bb(MinecraftServer.java:1205) ~[patched_1.16.4.jar:git-Yatopia-"a47bfa7"]
        at net.minecraft.server.v1_16_R3.MinecraftServer.executeNext(MinecraftServer.java:1198) ~[patched_1.16.4.jar:git-Yatopia-"a47bfa7"]
        at net.minecraft.server.v1_16_R3.IAsyncTaskHandler.awaitTasks(IAsyncTaskHandler.java:125) ~[patched_1.16.4.jar:git-Yatopia-"a47bfa7"]
        at net.minecraft.server.v1_16_R3.MinecraftServer.sleepForTick(MinecraftServer.java:1174) ~[patched_1.16.4.jar:git-Yatopia-"a47bfa7"]
        at net.minecraft.server.v1_16_R3.MinecraftServer.w(MinecraftServer.java:1018) ~[patched_1.16.4.jar:git-Yatopia-"a47bfa7"]
        at net.minecraft.server.v1_16_R3.MinecraftServer.lambda$a$0(MinecraftServer.java:179) ~[patched_1.16.4.jar:git-Yatopia-"a47bfa7"]
        at java.lang.Thread.run(Unknown Source) [?:1.8.0_271]
Caused by: java.lang.IllegalArgumentException: Size for custom inventory must be a multiple of 9 between 9 and 54 slots (got 63)
        at org.apache.commons.lang.Validate.isTrue(Validate.java:136) ~[patched_1.16.4.jar:git-Yatopia-"a47bfa7"]
        at org.bukkit.craftbukkit.v1_16_R3.CraftServer.createInventory(CraftServer.java:1819) ~[patched_1.16.4.jar:git-Yatopia-"a47bfa7"]
        at org.bukkit.Bukkit.createInventory(Bukkit.java:1172) ~[patched_1.16.4.jar:git-Yatopia-"a47bfa7"]
        at net.brcdev.christmas.core.BInventoryHolder.<init>(BInventoryHolder.java:13) ~[?:?]
        at net.brcdev.christmas.inventory.AdventCalendarInventoryHolder.<init>(AdventCalendarInventoryHolder.java:9) ~[?:?]
        at net.brcdev.christmas.adventcalendar.AdventCalendarManager.openAdventCalendar(AdventCalendarManager.java:105) ~[?:?]
        at net.brcdev.christmas.command.CmdAdventCalendar.onCommand(CmdAdventCalendar.java:59) ~[?:?]
        at org.bukkit.command.PluginCommand.execute(PluginCommand.java:45) ~[patched_1.16.4.jar:git-Yatopia-"a47bfa7"]
        ... 19 more

Я так понимаю банально места не хватает. Для 28+ дней
 
Java:
Caused by: java.lang.IllegalArgumentException: Size for custom inventory must be a multiple of 9 between 9 and 54 slots (got 63)
Размер пользовательского инвентаря должен быть кратен 9 между 9 и 54 слотами (получил 63)

Думаю, тут стоит писать разработчику, чтобы сделал больше с помощью добавления страниц или элементов в меню игрока по мимо меню сундука.
 
Назад
Сверху Снизу