tModLoader v2024.11
A mod to make and play Terraria mods
SpawnConditionDecorativeOverlayInfoElement Class Reference

Inherits IBestiaryInfoElement, and IBestiaryBackgroundOverlayAndColorProvider.

Public Member Functions

 SpawnConditionDecorativeOverlayInfoElement (string overlayImagePath=null, Color? overlayColor=null)
 
Color? GetBackgroundOverlayColor ()
 
Asset< Texture2D > GetBackgroundOverlayImage ()
 
UIElement ProvideUIElement (BestiaryUICollectionInfo info)
 Use to create the UIElement for this bestiary entry. Called when the bestiary entry is clicked in-game. Use BestiaryUICollectionInfo.UnlockState to dynamically populate the UI according to how fully unlocked this particular bestiary entry is. Return null if no UIElement should be provided, which is usually the case for NPC never encountered. More...
 
UIElement ProvideUIElement (BestiaryUICollectionInfo info)
 Use to create the UIElement for this bestiary entry. Called when the bestiary entry is clicked in-game. Use BestiaryUICollectionInfo.UnlockState to dynamically populate the UI according to how fully unlocked this particular bestiary entry is. Return null if no UIElement should be provided, which is usually the case for NPC never encountered. More...
 
Color? GetBackgroundOverlayColor ()
 
Asset< Texture2D > GetBackgroundOverlayImage ()
 

Properties

float DisplayPriority [get, set]
 
- Properties inherited from IBestiaryBackgroundOverlayAndColorProvider
float DisplayPriority [get]
 

Member Function Documentation

◆ GetBackgroundOverlayColor()

Color? SpawnConditionDecorativeOverlayInfoElement.GetBackgroundOverlayColor ( )

◆ GetBackgroundOverlayImage()

Asset< Texture2D > SpawnConditionDecorativeOverlayInfoElement.GetBackgroundOverlayImage ( )

◆ ProvideUIElement()

UIElement SpawnConditionDecorativeOverlayInfoElement.ProvideUIElement ( BestiaryUICollectionInfo  info)

Use to create the UIElement for this bestiary entry. Called when the bestiary entry is clicked in-game. Use BestiaryUICollectionInfo.UnlockState to dynamically populate the UI according to how fully unlocked this particular bestiary entry is. Return null if no UIElement should be provided, which is usually the case for NPC never encountered.

if (info.UnlockState == BestiaryEntryUnlockState.NotKnownAtAll_0) return null;

// other code creating and returning a UIElement showing info

Implements IBestiaryInfoElement.

Property Documentation

◆ DisplayPriority

float SpawnConditionDecorativeOverlayInfoElement.DisplayPriority
getset