Interface BattleConfig
-
- All Implemented Interfaces:
public interface BattleConfigMain BattleCards Configuration
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description public classBattleConfig.Companion
-
Method Summary
Modifier and Type Method Description abstract UnitregisterCard(Class<out BattleCard<?>> card)Registers a BattleCard. abstract UnitregisterEquipment(CardEquipment equipment)Registers a CardEquipment. abstract Stringget(String key)Fetches a localized message from the plugin's language file. StringgetMessage(String key)Fetches a localized message from the plugin's language file, with the plugin prefix. abstract CardcreateCardData(BattleCardType type)Creates a Card Data object with no data. abstract BooleanisAvailable(BattleCardType type)Fetches whether this BattleCardType is available on this current MC Version. abstract Set<Class<out BattleCard<?>>>getRegisteredCards()Fetches an immutable set of all of the registered BattleCards. abstract Set<CardEquipment>getRegisteredEquipment()Fetches an immutable set of all of the registered CardEquipments. StringgetLanguage()Fetches the plugin's language. LocalegetLocale()Fetches the plugin's locale. Set<BattleCardType>getDisabledCards()Gets all disabled BattleCards. UnitsetDisabledCards(Set<BattleCardType> disabledCards)Sets the currently disabled BattleCards. BooleanisBasicDropsEnabled()Fetches whether cards of the Rarity.BASIC rarity can be dropped by mobs. UnitsetBasicDropsEnabled(Boolean isBasicDropsEnabled)Sets whether cards of the Rarity.BASIC rarity can be dropped by mobs. DoublegetGrowthPassiveAmount()Fetches the amount of set experience added to cards in a player's inventory every hour. UnitsetGrowthPassiveAmount(Double growthPassiveAmount)Sets the amount of set experience added to cards in a player's inventory every hour. DoublegetGrowthUseMultiplier()Fetches the multiplier by the Card's Level for how much experience will be added upon this card being used. UnitsetGrowthUseMultiplier(Double growthUseMultiplier)Sets the multiplier by the Card's Level for how much experience will be added upon this card being used. DoublegetGrowthKillMultiplier()Fetches the multiplier that will be added to a target's maximum health upon a card killing it to be added to its experience. UnitsetGrowthKillMultiplier(Double growthKillMultiplier)Sets the multiplier that will be added to a target's maximum health upon a card killing it to be added to its experience. DoublegetGrowthKillCardMultiplier()Fetches the multiplier for the kill multiplier when the target is a Battle Card. UnitsetGrowthKillCardMultiplier(Double growthKillCardMultiplier)Sets the multiplier for the kill multiplier when the target is a Battle Card. IntegergetCardCooldown()Fetches the cooldown, in seconds, between when the same BattleCard can be deployed again UnitsetCardCooldown(Integer cardCooldown)Sets the cooldown, in seconds, between when the same BattleCard can be deployed again IntegergetPlayerCooldownCount()Fetches the number of cards that can be deployed by a player before the cooldown is activated. UnitsetPlayerCooldownCount(Integer playerCooldownCount)Sets the number of cards that can be deployed by a player before the cooldown is activated. IntegergetPlayerCooldownTime()Fetches the time, in seconds, that the cooldown will be activated for when the player has deployed the maximum number of cards. UnitsetPlayerCooldownTime(Integer playerCooldownTime)Sets the time, in seconds, that the cooldown will be activated for when the player has deployed the maximum number of cards. List<String>getPlayerCooldownIgnored()Fetches a list of players, permissions, and vault group patterns that will not be affected by the player cooldown. UnitsetPlayerCooldownIgnored(List<String> playerCooldownIgnored)Sets a list of players, permissions, and vault group patterns that will not be affected by the player cooldown. BooleangetCardAttackPlayers()Fetches whether Battle Cards can attack players. UnitsetCardAttackPlayers(Boolean cardAttackPlayers)Sets whether Battle Cards can attack players. BooleangetTargetCards()Fetches whether Non-Card Entities can target Battle Cards. UnitsetTargetCards(Boolean targetCards)Sets whether Non-Card Entities can target Battle Cards. BooleanisCardDestroyedThorns()Fetches whether Battle Cards can be destroyed by a Cactus. UnitsetCardDestroyedThorns(Boolean isCardDestroyedThorns)Sets whether Battle Cards can be destroyed by a Cactus. BooleanisCardDestroyedFire()Fetches whether Battle Cards can be destroyed by Fire. UnitsetCardDestroyedFire(Boolean isCardDestroyedFire)Sets whether Battle Cards can be destroyed by Fire. BooleanisCardDestroyedExplosion()Fetches whether Battle Cards can be destroyed by an Explosion. UnitsetCardDestroyedExplosion(Boolean isCardDestroyedExplosion)Sets whether Battle Cards can be destroyed by an Explosion. BooleanisCardsDespawn()Fetches whether Battle Card Items can despawn. UnitsetCardsDespawn(Boolean isCardsDespawn)Sets whether Battle Card Items can despawn. IntegergetMaxCardsSpawned()Fetches the maximum number of Battle Cards that can be spawned at once. UnitsetMaxCardsSpawned(Integer maxCardsSpawned)Sets the maximum number of Battle Cards that can be spawned at once. DoublegetCardTradesChance()Fetches the chance that a villager will get a BattleCard-related trade. UnitsetCardTradesChance(Double cardTradesChance)Sets the chance that a villager will get a BattleCard-related trade. -
-
Method Detail
-
registerCard
abstract Unit registerCard(Class<out BattleCard<?>> card)
Registers a BattleCard.
- Parameters:
card- BattleCard to register
-
registerEquipment
abstract Unit registerEquipment(CardEquipment equipment)
Registers a CardEquipment.
- Parameters:
equipment- CardEquipment to register
-
get
abstract String get(String key)
Fetches a localized message from the plugin's language file.
- Parameters:
key- Key to fetch
-
getMessage
@Deprecated(message = "Unused as of Messages Revamp in v1.1.1", replaceWith = @ReplaceWith(imports = {}, expression = "get(key)")) String getMessage(String key)
Fetches a localized message from the plugin's language file, with the plugin prefix.
- Parameters:
key- Key to fetch
-
createCardData
abstract Card createCardData(BattleCardType type)
Creates a Card Data object with no data.
- Parameters:
type- Card Type
-
isAvailable
abstract Boolean isAvailable(BattleCardType type)
Fetches whether this BattleCardType is available on this current MC Version.
- Parameters:
type- Card Type
-
getRegisteredCards
abstract Set<Class<out BattleCard<?>>> getRegisteredCards()
Fetches an immutable set of all of the registered BattleCards.
-
getRegisteredEquipment
abstract Set<CardEquipment> getRegisteredEquipment()
Fetches an immutable set of all of the registered CardEquipments.
-
getLanguage
String getLanguage()
Fetches the plugin's language.
-
getDisabledCards
Set<BattleCardType> getDisabledCards()
Gets all disabled BattleCards.
-
setDisabledCards
Unit setDisabledCards(Set<BattleCardType> disabledCards)
Sets the currently disabled BattleCards.
- Parameters:
disabledCards- Set of disabled BattleCards
-
isBasicDropsEnabled
Boolean isBasicDropsEnabled()
Fetches whether cards of the Rarity.BASIC rarity can be dropped by mobs.
-
setBasicDropsEnabled
Unit setBasicDropsEnabled(Boolean isBasicDropsEnabled)
Sets whether cards of the Rarity.BASIC rarity can be dropped by mobs.
- Parameters:
isBasicDropsEnabled- true if can be dropped, false otherwise
-
getGrowthPassiveAmount
Double getGrowthPassiveAmount()
Fetches the amount of set experience added to cards in a player's inventory every hour.
-
setGrowthPassiveAmount
Unit setGrowthPassiveAmount(Double growthPassiveAmount)
Sets the amount of set experience added to cards in a player's inventory every hour.
- Parameters:
growthPassiveAmount- Experience Amount
-
getGrowthUseMultiplier
Double getGrowthUseMultiplier()
Fetches the multiplier by the Card's Level for how much experience will be added upon this card being used.
-
setGrowthUseMultiplier
Unit setGrowthUseMultiplier(Double growthUseMultiplier)
Sets the multiplier by the Card's Level for how much experience will be added upon this card being used.
- Parameters:
growthUseMultiplier- Use Multiplier
-
getGrowthKillMultiplier
Double getGrowthKillMultiplier()
Fetches the multiplier that will be added to a target's maximum health upon a card killing it to be added to its experience.
-
setGrowthKillMultiplier
Unit setGrowthKillMultiplier(Double growthKillMultiplier)
Sets the multiplier that will be added to a target's maximum health upon a card killing it to be added to its experience.
- Parameters:
growthKillMultiplier- Kill Multiplier
-
getGrowthKillCardMultiplier
Double getGrowthKillCardMultiplier()
Fetches the multiplier for the kill multiplier when the target is a Battle Card.
-
setGrowthKillCardMultiplier
Unit setGrowthKillCardMultiplier(Double growthKillCardMultiplier)
Sets the multiplier for the kill multiplier when the target is a Battle Card.
- Parameters:
growthKillCardMultiplier- Kill Card Multiplier
-
getCardCooldown
Integer getCardCooldown()
Fetches the cooldown, in seconds, between when the same BattleCard can be deployed again
-
setCardCooldown
Unit setCardCooldown(Integer cardCooldown)
Sets the cooldown, in seconds, between when the same BattleCard can be deployed again
- Parameters:
cardCooldown- Cooldown
-
getPlayerCooldownCount
Integer getPlayerCooldownCount()
Fetches the number of cards that can be deployed by a player before the cooldown is activated.
-
setPlayerCooldownCount
Unit setPlayerCooldownCount(Integer playerCooldownCount)
Sets the number of cards that can be deployed by a player before the cooldown is activated.
- Parameters:
playerCooldownCount- Card Count
-
getPlayerCooldownTime
Integer getPlayerCooldownTime()
Fetches the time, in seconds, that the cooldown will be activated for when the player has deployed the maximum number of cards.
-
setPlayerCooldownTime
Unit setPlayerCooldownTime(Integer playerCooldownTime)
Sets the time, in seconds, that the cooldown will be activated for when the player has deployed the maximum number of cards.
- Parameters:
playerCooldownTime- Cooldown Time
-
getPlayerCooldownIgnored
List<String> getPlayerCooldownIgnored()
Fetches a list of players, permissions, and vault group patterns that will not be affected by the player cooldown.
-
setPlayerCooldownIgnored
Unit setPlayerCooldownIgnored(List<String> playerCooldownIgnored)
Sets a list of players, permissions, and vault group patterns that will not be affected by the player cooldown.
- Parameters:
playerCooldownIgnored- List of Players
-
getCardAttackPlayers
Boolean getCardAttackPlayers()
Fetches whether Battle Cards can attack players.
-
setCardAttackPlayers
Unit setCardAttackPlayers(Boolean cardAttackPlayers)
Sets whether Battle Cards can attack players.
- Parameters:
cardAttackPlayers- true if can attack players, false otherwise
-
getTargetCards
Boolean getTargetCards()
Fetches whether Non-Card Entities can target Battle Cards.
-
setTargetCards
Unit setTargetCards(Boolean targetCards)
Sets whether Non-Card Entities can target Battle Cards.
- Parameters:
targetCards- true if can target Battle Cards, false otherwise
-
isCardDestroyedThorns
Boolean isCardDestroyedThorns()
Fetches whether Battle Cards can be destroyed by a Cactus.
-
setCardDestroyedThorns
Unit setCardDestroyedThorns(Boolean isCardDestroyedThorns)
Sets whether Battle Cards can be destroyed by a Cactus.
- Parameters:
isCardDestroyedThorns- true if can be destroyed by a Cactus, false otherwise
-
isCardDestroyedFire
Boolean isCardDestroyedFire()
Fetches whether Battle Cards can be destroyed by Fire.
-
setCardDestroyedFire
Unit setCardDestroyedFire(Boolean isCardDestroyedFire)
Sets whether Battle Cards can be destroyed by Fire.
- Parameters:
isCardDestroyedFire- true if can be destroyed by Fire, false otherwise
-
isCardDestroyedExplosion
Boolean isCardDestroyedExplosion()
Fetches whether Battle Cards can be destroyed by an Explosion.
-
setCardDestroyedExplosion
Unit setCardDestroyedExplosion(Boolean isCardDestroyedExplosion)
Sets whether Battle Cards can be destroyed by an Explosion.
- Parameters:
isCardDestroyedExplosion- true if can be destroyed by an Explosion, false otherwise
-
isCardsDespawn
Boolean isCardsDespawn()
Fetches whether Battle Card Items can despawn.
-
setCardsDespawn
Unit setCardsDespawn(Boolean isCardsDespawn)
Sets whether Battle Card Items can despawn.
- Parameters:
isCardsDespawn- true if can despawn, false otherwise
-
getMaxCardsSpawned
Integer getMaxCardsSpawned()
Fetches the maximum number of Battle Cards that can be spawned at once.
-
setMaxCardsSpawned
Unit setMaxCardsSpawned(Integer maxCardsSpawned)
Sets the maximum number of Battle Cards that can be spawned at once.
- Parameters:
maxCardsSpawned- Maximum Cards
-
getCardTradesChance
Double getCardTradesChance()
Fetches the chance that a villager will get a BattleCard-related trade.
-
setCardTradesChance
Unit setCardTradesChance(Double cardTradesChance)
Sets the chance that a villager will get a BattleCard-related trade.
- Parameters:
cardTradesChance- Chance
-
-
-
-