Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var TierChain = Tier{BaseDurability: 166, Name: "chainmail"}
TierChain is the tier of chain armour.
View Source
var TierDiamond = Tier{BaseDurability: 363, Name: "diamond"}
TierDiamond is the tier of diamond armour.
View Source
var TierGold = Tier{BaseDurability: 77, Name: "golden"}
TierGold is the tier of gold armour.
View Source
var TierIron = Tier{BaseDurability: 165, Name: "iron"}
TierIron is the tier of iron armour.
View Source
var TierLeather = Tier{BaseDurability: 55, Name: "leather"}
TierLeather is the tier of leather armour.
View Source
var TierNetherite = Tier{BaseDurability: 408, KnockBackResistance: 0.1, Name: "netherite"}
TierNetherite is the tier of netherite armour.
Functions ¶
This section is empty.
Types ¶
type Armour ¶
type Armour interface { // DefencePoints returns the defence points that the armour provides when worn. DefencePoints() float64 // KnockBackResistance returns a number from 0-1 that decides the amount of knock back force that is // resisted upon being attacked. 1 knock back resistance point client-side translates to 10% knock back // reduction. KnockBackResistance() float64 }
Armour represents an item that may be worn as armour. Generally, these items provide armour points, which reduce damage taken. Some pieces of armour also provide toughness, which negates damage proportional to the total damage dealt.
type Chestplate ¶
Chestplate is an Armour item that can be worn in the chestplate slot.
type Tier ¶
type Tier struct { // BaseDurability is the base durability of armour with this tier. This is otherwise the durability of // the helmet with this tier. BaseDurability float64 // KnockBackResistance is a number from 0-1 that decides the amount of knock back force that is resisted // upon being attacked. 1 knock back resistance point client-side translates to 10% knock back reduction. KnockBackResistance float64 // Name is the name of the tier. Name string }
Tier represents the tier, or material, that a piece of armour is made of.
Click to show internal directories.
Click to hide internal directories.