001package com.ericlam.mc.minigames.core.registable; 002 003import com.ericlam.mc.minigames.core.SectionTask; 004import com.ericlam.mc.minigames.core.game.GameTeam; 005import com.ericlam.mc.minigames.core.game.InGameState; 006import org.bukkit.inventory.ItemStack; 007 008/** 009 * 可選註冊器。不註冊并不會導致遊戲無法被激活。 010 */ 011public interface Voluntary { 012 013 /** 014 * 註冊大堂倒數和遊戲結束之間的遊戲程序 (順序註冊) 015 * 016 * @param state 所屬場地狀態 017 * @param task 所屬遊戲程序 018 */ 019 void registerGameTask(InGameState state, SectionTask task); 020 021 /** 022 * 添加等待投票物品 023 * 024 * @param slot slot 025 * @param item 物品 026 */ 027 void addJoinItem(int slot, ItemStack item); 028 029 /** 030 * 添加遊戲內隊伍物品 031 * 032 * @param team 隊伍 033 * @param slot slot 034 * @param item 物品 035 */ 036 void addGameItem(GameTeam team, int slot, ItemStack item); 037 038 /** 039 * 添加遊戲內非隊伍物品,僅限沒有隊伍玩家 040 * 041 * @param slot slot 042 * @param item 物品 043 */ 044 void addGameItem(int slot, ItemStack item); 045 046 /** 047 * 添加觀戰隊伍物品 048 * 049 * @param team 隊伍 050 * @param slot slot 051 * @param item 物品 052 */ 053 void addSpectatorItem(GameTeam team, int slot, ItemStack item); 054 055 /** 056 * 添加觀戰非隊伍物品, 僅限沒有隊伍玩家 057 * 058 * @param slot slot 059 * @param item 物品 060 */ 061 void addSpectatorItem(int slot, ItemStack item); 062 063}