Skip to content

Artifact

This library is relevant for Epic Encounters only.

The Artifact library contains data and methods related to Epic Encounters Artifacts.

The ArtifactLib_ArtifactDefinition class holds information for each of the artifacts, including slot, item/rune templates, as well as the related keyword activators and mutators (defined manually).

The data is not generated automatically. You must add your own artifacts by calling RegisterArtifact() with the data table filled out. Ideally, this should be done on both contexts, so client scripting can also query the information.

ArtifactLib_ArtifactDefinition Class

@field ID string

@field Slot ItemSlot

@field ItemTemplate GUID

@field RuneTemplate GUID

@field DescriptionHandle TranslatedStringHandle

@field KeywordActivators Keyword[]

@field KeywordMutators Keyword[]

Methods

GetDescription
function ArtifactLib_ArtifactDefinition:GetDescription()
   -> string

Returns the artifact power's description.

GetName
function ArtifactLib_ArtifactDefinition:GetName()
   -> string

Returns the artifact's name.

GetPowerTooltip
function ArtifactLib_ArtifactDefinition:GetPowerTooltip()
   -> TooltipLib_Element[]

Returns a full tooltip showing the artifact's name and power.

HasKeyword
function ArtifactLib_ArtifactDefinition:HasKeyword(keyword)

Returns whether the artifact has a keyword activator or mutator.

@param keyword Keyword

ArtifactLib Class

Inherits from Feature.

Methods

GetData
function ArtifactLib.GetData(artifactID)
   -> ArtifactLib_ArtifactDefinition?

Returns the definition for an artifact.

@param artifactID string

GetEquippedPowers
function ArtifactLib.GetEquippedPowers(char) -- (Server-only)
   -> ArtifactLib_ArtifactDefinition[]

Returns a list of artifact powers active on char.

@param char EsvCharacter

GetEquippedPowers
function ArtifactLib.GetEquippedPowers(char) -- (Client-only)
   -> ArtifactLib_ArtifactDefinition[]

Returns a list of artifact powers active on char.

@param char EclCharacter

IsEquipped
function ArtifactLib.IsEquipped(char, artifact) -- (Server-only)
   -> boolean

Returns whether char has the artifact power active.

@param char EsvCharacter

@param artifact ArtifactLib_ArtifactDefinition|string

IsEquipped
function ArtifactLib.IsEquipped(char, artifact) -- (Client-only)
   -> boolean

Returns whether char has the artifact power active.

@param char EclCharacter

@param artifact ArtifactLib_ArtifactDefinition|string

IsOwnedByParty
function ArtifactLib.IsOwnedByParty(id)

Returns whether the party owns an artifact.

@param id string

RegisterArtifact
function ArtifactLib.RegisterArtifact(data)
   -> ArtifactLib_ArtifactDefinition

Registers the data for an artifact.

@param data ArtifactLib_ArtifactDefinition

Usage examples

This library is used in the Quick Examine UI to display tooltips for artifacts. It is additionally used in the stats tab to check the equipped artifacts of a character.