Expansion for MCEntityType
Link to expansion-for-mcentitytype
Additional methods for easier modification of entity-related loot tables.
Metodi
Link to metodi
Name: addDrop
Adds an IItemStack to the drops of this entity.
Return Type: void
ZenScript CopyMCEntityType.addDrop(uniqueId as string, stack as IItemStack) as void
Parametro | Tipo | Descrizione |
---|---|---|
Parametro uniqueId | Tipo string | Descrizione A unique id for the loot modifier. |
Parametro stack | Tipo IItemStack | Descrizione The stack to add to the drops. |
Name: addDrops
Adds a list of IItemStacks to the drops of this entity.
Return Type: void
ZenScript CopyMCEntityType.addDrops(uniqueId as string, stacks as IItemStack[]) as void
Parametro | Tipo | Descrizione |
---|---|---|
Parametro uniqueId | Tipo string | Descrizione A unique id for the loot modifier. |
Parametro stacks | Tipo IItemStack[] | Descrizione The stacks to add to the drops. |
Name: addLootModifier
Adds an ILootModifier to the current entity.
Return Type: void
ZenScript CopyMCEntityType.addLootModifier(name as string, modifier as ILootModifier) as void
Parametro | Tipo | Descrizione |
---|---|---|
Parametro nome | Tipo string | Descrizione The name of the loot modifier. |
Parametro modifier | Tipo ILootModifier | Descrizione The loot modifier to add to the entity. |
Name: addPlayerOnlyDrop
Adds an IItemStack to the drops of this entity, but only if the entity was killed by a player.
Return Type: void
ZenScript CopyMCEntityType.addPlayerOnlyDrop(uniqueId as string, stack as IItemStack) as void
Parametro | Tipo | Descrizione |
---|---|---|
Parametro uniqueId | Tipo string | Descrizione A unique id for the loot modifier. |
Parametro stack | Tipo IItemStack | Descrizione The stack to add to the drops. |
Name: addPlayerOnlyDrops
Adds a list of IItemStacks to the drops of this entity, but only if the entity was killed by a player.
Return Type: void
ZenScript CopyMCEntityType.addPlayerOnlyDrops(uniqueId as string, stacks as IItemStack[]) as void
Parametro | Tipo | Descrizione |
---|---|---|
Parametro uniqueId | Tipo string | Descrizione A unique id for the loot modifier. |
Parametro stacks | Tipo IItemStack[] | Descrizione The stacks to add to the drops. |
Name: addPlayerOnlyLootModifier
Adds an ILootModifier to the current entity that fires only if the entity was killed by a player.
Return Type: void
ZenScript CopyMCEntityType.addPlayerOnlyLootModifier(name as string, modifier as ILootModifier) as void
Parametro | Tipo | Descrizione |
---|---|---|
Parametro nome | Tipo string | Descrizione The name of the loot modifier. |
Parametro modifier | Tipo ILootModifier | Descrizione The loot modifier to add to the entity. |
Name: addWeaponAndPlayerOnlyDrop
Adds an IItemStack to the drops of this entity, but only if the entity was killed by a player with the given weapon.
Additional parameters that further specify the weapon, such as NBT, count, or damage, are ignored.
Return Type: void
ZenScript CopyMCEntityType.addWeaponAndPlayerOnlyDrop(uniqueId as string, weapon as IItemStack, stack as IItemStack) as void
Parametro | Tipo | Descrizione |
---|---|---|
Parametro uniqueId | Tipo string | Descrizione A unique id for the loot modifier. |
Parametro weapon | Tipo IItemStack | Descrizione The weapon that needs to be used to kill the entity. |
Parametro stack | Tipo IItemStack | Descrizione The stack to add to the drops. |
Name: addWeaponAndPlayerOnlyDrops
Adds a list of IItemStacks to the drops of this entity, but only if the entity was killed by a player with the given weapon.
Additional parameters that further specify the weapon, such as NBT, count, or damage, are ignored.
Return Type: void
ZenScript CopyMCEntityType.addWeaponAndPlayerOnlyDrops(uniqueId as string, weapon as IItemStack, stacks as IItemStack[]) as void
Parametro | Tipo | Descrizione |
---|---|---|
Parametro uniqueId | Tipo string | Descrizione A unique id for the loot modifier. |
Parametro weapon | Tipo IItemStack | Descrizione The weapon that needs to be used to kill the entity. |
Parametro stacks | Tipo IItemStack[] | Descrizione The stacks to add to the drops. |
Name: addWeaponAndPlayerOnlyLootModifier
Adds an ILootModifier to the current entity that fires only if the entity was killed by a player with the given weapon.
Additional parameters that further specify the weapon, such as NBT, count, or damage, are ignored.
Return Type: void
ZenScript CopyMCEntityType.addWeaponAndPlayerOnlyLootModifier(name as string, weapon as IItemStack, modifier as ILootModifier) as void
Parametro | Tipo | Descrizione |
---|---|---|
Parametro nome | Tipo string | Descrizione The name of the loot modifier. |
Parametro weapon | Tipo IItemStack | Descrizione The weapon that needs to be used to kill the entity. |
Parametro modifier | Tipo ILootModifier | Descrizione The loot modifier to add to the entity. |
Name: addWeaponAndPlayerOnlyLootModifier
Adds an ILootModifier to the current entity that fires only if the entity was killed by a player with the given weapon, optionally considering its damage.
Additional parameters that further specify the weapon, such as NBT, or count, are ignored.
Return Type: void
ZenScript CopyMCEntityType.addWeaponAndPlayerOnlyLootModifier(name as string, weapon as IItemStack, matchDamage as boolean, modifier as ILootModifier) as void
Parametro | Tipo | Descrizione |
---|---|---|
Parametro nome | Tipo string | Descrizione The name of the loot modifier. |
Parametro weapon | Tipo IItemStack | Descrizione The weapon that needs to be used to kill the entity. |
Parametro matchDamage | Tipo boolean | Descrizione Whether to consider damage or not when identifying the weapon. |
Parametro modifier | Tipo ILootModifier | Descrizione The loot modifier to add to the entity. |
Name: addWeaponAndPlayerOnlyLootModifier
Adds an ILootModifier to the current entity that fires only if the entity was killed by a player with the given weapon, optionally considering its damage and NBT data.
Additional parameters that further specify the weapon, such as count, are ignored.
Return Type: void
ZenScript CopyMCEntityType.addWeaponAndPlayerOnlyLootModifier(name as string, weapon as IItemStack, matchDamage as boolean, matchNbt as boolean, modifier as ILootModifier) as void
Parametro | Tipo | Descrizione |
---|---|---|
Parametro nome | Tipo string | Descrizione The name of the loot modifier. |
Parametro weapon | Tipo IItemStack | Descrizione The weapon that needs to be used to kill the entity. |
Parametro matchDamage | Tipo boolean | Descrizione Whether to consider damage or not when identifying the weapon. |
Parametro matchNbt | Tipo boolean | Descrizione Whether to consider NBT data or not when identifying the weapon. |
Parametro modifier | Tipo ILootModifier | Descrizione The loot modifier to add to the entity. |
Name: addWeaponOnlyDrop
Adds an IItemStack to the drops of this entity, but only if the entity was killed with the given weapon.
Additional parameters that further specify the weapon, such as NBT, count, or damage, are ignored.
Return Type: void
ZenScript CopyMCEntityType.addWeaponOnlyDrop(uniqueId as string, weapon as IItemStack, stack as IItemStack) as void
Parametro | Tipo | Descrizione |
---|---|---|
Parametro uniqueId | Tipo string | Descrizione A unique id for the loot modifier. |
Parametro weapon | Tipo IItemStack | Descrizione The weapon that needs to be used to kill the entity. |
Parametro stack | Tipo IItemStack | Descrizione The stack to add to the drops. |
Name: addWeaponOnlyDrops
Adds a list of IItemStacks to the drops of this entity, but only if the entity was killed with the given weapon.
Additional parameters that further specify the weapon, such as NBT, count, or damage, are ignored.
Return Type: void
ZenScript CopyMCEntityType.addWeaponOnlyDrops(uniqueId as string, weapon as IItemStack, stacks as IItemStack[]) as void
Parametro | Tipo | Descrizione |
---|---|---|
Parametro uniqueId | Tipo string | Descrizione A unique id for the loot modifier. |
Parametro weapon | Tipo IItemStack | Descrizione The weapon that needs to be used to kill the entity. |
Parametro stacks | Tipo IItemStack[] | Descrizione The stacks to add to the drops. |
Name: addWeaponOnlyLootModifier
Adds an ILootModifier to the current entity that fires only if the entity was killed with the given weapon.
Additional parameters that further specify the weapon, such as NBT, count, or damage, are ignored.
Return Type: void
ZenScript CopyMCEntityType.addWeaponOnlyLootModifier(name as string, weapon as IItemStack, modifier as ILootModifier) as void
Parametro | Tipo | Descrizione |
---|---|---|
Parametro nome | Tipo string | Descrizione The name of the loot modifier. |
Parametro weapon | Tipo IItemStack | Descrizione The weapon that needs to be used to kill the entity. |
Parametro modifier | Tipo ILootModifier | Descrizione The loot modifier to add to the entity. |
Name: addWeaponOnlyLootModifier
Adds an ILootModifier to the current entity that fires only if the entity was killed with the given weapon, optionally considering its damage.
Additional parameters that further specify the weapon, such as NBT, or count, are ignored.
Return Type: void
ZenScript CopyMCEntityType.addWeaponOnlyLootModifier(name as string, weapon as IItemStack, matchDamage as boolean, modifier as ILootModifier) as void
Parametro | Tipo | Descrizione |
---|---|---|
Parametro nome | Tipo string | Descrizione The name of the loot modifier. |
Parametro weapon | Tipo IItemStack | Descrizione The weapon that needs to be used to kill the entity. |
Parametro matchDamage | Tipo boolean | Descrizione Whether to consider damage or not when identifying the weapon. |
Parametro modifier | Tipo ILootModifier | Descrizione The loot modifier to add to the entity. |
Name: addWeaponOnlyLootModifier
Adds an ILootModifier to the current entity that fires only if the entity was killed with the given weapon, optionally considering its damage and NBT data.
Additional parameters that further specify the weapon, such as count, are ignored.
Return Type: void
ZenScript CopyMCEntityType.addWeaponOnlyLootModifier(name as string, weapon as IItemStack, matchDamage as boolean, matchNbt as boolean, modifier as ILootModifier) as void
Parametro | Tipo | Descrizione |
---|---|---|
Parametro nome | Tipo string | Descrizione The name of the loot modifier. |
Parametro weapon | Tipo IItemStack | Descrizione The weapon that needs to be used to kill the entity. |
Parametro matchDamage | Tipo boolean | Descrizione Whether to consider damage or not when identifying the weapon. |
Parametro matchNbt | Tipo boolean | Descrizione Whether to consider NBT data or not when identifying the weapon. |
Parametro modifier | Tipo ILootModifier | Descrizione The loot modifier to add to the entity. |