PixelCrushers.DialogueSystem.StandardUISubtitleControls Class Reference

Manages subtitle panels for StandardDialogueUI. More...

Inheritance diagram for PixelCrushers.DialogueSystem.StandardUISubtitleControls:
Collaboration diagram for PixelCrushers.DialogueSystem.StandardUISubtitleControls:

Public Member Functions

void Initialize (StandardUISubtitlePanel[] subtitlePanels, StandardUISubtitlePanel defaultNPCSubtitlePanel, StandardUISubtitlePanel defaultPCSubtitlePanel)
 
void ClearCache ()
 
void ClearOverrideCache ()
 
void ForceOverrideSubtitlePanel (StandardUISubtitlePanel customPanel)
 
void OverrideActorPanel (Actor actor, SubtitlePanelNumber subtitlePanelNumber, StandardUISubtitlePanel customPanel=null, bool immediate=false)
 For speakers who do not have DialogueActor components, this method overrides the actor's default panel.
 
void OverrideActorPanel (DialogueActor dialogueActor, SubtitlePanelNumber subtitlePanelNumber, StandardUISubtitlePanel customPanel=null)
 Overrides a DialogueActor's subtitle panel.
 
virtual StandardUISubtitlePanel GetPanel (Subtitle subtitle, out DialogueActor dialogueActor)
 
StandardUISubtitlePanel GetActorTransformPanel (Transform speakerTransform, StandardUISubtitlePanel defaultPanel, out DialogueActor dialogueActor)
 
StandardUISubtitlePanel GetDialogueActorPanel (DialogueActor dialogueActor)
 
StandardUISubtitlePanel GetPanelFromNumber (SubtitlePanelNumber subtitlePanelNumber, StandardUISubtitlePanel customPanel)
 
virtual void SetActorSubtitlePanelNumber (DialogueActor dialogueActor, SubtitlePanelNumber subtitlePanelNumber)
 Changes a dialogue actor's panel for the current conversation.
 
void ShowActorInPanel (Actor actor, SubtitlePanelNumber subtitlePanelNumber, StandardUISubtitlePanel customPanel=null)
 
virtual void RecordActorPanelCache (out List< string > actorGOs, out List< SubtitlePanelNumber > actorGOPanels, out List< int > actorIDs, out List< SubtitlePanelNumber > actorIDPanels, out List< string > actorNames)
 Record the current actor panel cache values for saved games (ConversationStateSaver) so the cache can be restored when loading a game.
 
virtual void QueueSavedActorPanelCache (List< string > actorGOs, List< SubtitlePanelNumber > actorGOPanels, List< int > actorIDs, List< SubtitlePanelNumber > actorIDPanels)
 Queues actor panel caches to be applies when the next conversation starts.
 
virtual void ApplyQueuedActorPanelCache ()
 Apply any actor panel cache values that ConversationStateSaver may have queued when loading a saved game.
 
StandardUISubtitlePanel StageFocusedPanel (Subtitle subtitle)
 Sets the panel that will receive focus for the specified subtitle.
 
override void ShowSubtitle (Subtitle subtitle)
 Shows a subtitle.
 
void HideSubtitle (Subtitle subtitle)
 Hides a subtitle.
 
void Close ()
 Close all panels.
 
bool AreAnyPanelsClosing ()
 
virtual void UnfocusAll ()
 
virtual void HideOnResponseMenu ()
 
override void ShowContinueButton ()
 Shows the continue button.
 
override void HideContinueButton ()
 Hides the continue button.
 
override void SetActive (bool value)
 
override void SetSubtitle (Subtitle subtitle)
 
override void ClearSubtitle ()
 
virtual void ClearSubtitlesOnCustomPanels ()
 
override void SetActorPortraitSprite (string actorName, Sprite portraitSprite)
 Sets the portrait sprite to use in the subtitle if the named actor is the speaker.
 
void OpenSubtitlePanelsOnStartConversation (StandardDialogueUI ui)
 Searches the current conversation for any DialogueActors who use subtitle panels that are configured to appear when the conversation starts.
 
void SetLastActorToUsePanel (StandardUISubtitlePanel panel, int actorID)
 
void OpenSubtitlePanelLikeStart (SubtitlePanelNumber subtitlePanelNumber)
 
virtual float GetTypewriterSpeed ()
 
virtual void SetTypewriterSpeed (float charactersPerSecond)
 
- Public Member Functions inherited from PixelCrushers.DialogueSystem.AbstractUISubtitleControls
void SetSubtitle (Subtitle subtitle)
 Sets the subtitle controls' contents.
 
void ClearSubtitle ()
 Clears the subtitle controls' contents.
 
virtual void SetActorPortraitTexture (string actorName, Texture2D texture)
 
- Public Member Functions inherited from PixelCrushers.DialogueSystem.AbstractUIControls
void SetActive (bool value)
 Sets the controls active/inactive.
 
void Show ()
 Shows the controls by setting them active.
 
void Hide ()
 Hides the controls by setting them inactive.
 

Protected Member Functions

virtual SubtitlePanelNumber GetSubtitlePanelNumberFromPanel (StandardUISubtitlePanel panel)
 
virtual void SupercedeOtherPanels (StandardUISubtitlePanel newPanel)
 
virtual void SupercedeOtherPanelsInList (List< StandardUISubtitlePanel > list, StandardUISubtitlePanel newPanel)
 
Transform GetActorTransform (string actorName)
 

Properties

StandardUISubtitlePanel defaultNPCPanel [get, set]
 
StandardUISubtitlePanel defaultPCPanel [get, set]
 
override bool hasText [get]
 Indicates whether the focused subtitle contains text.
 
virtual bool allowDialogueActorCustomPanels = true [get, set]
 
- Properties inherited from PixelCrushers.DialogueSystem.AbstractUISubtitleControls
bool hasText [get]
 Gets a value indicating whether text has been assigned to the subtitle controls.
 

Additional Inherited Members

- Protected Attributes inherited from PixelCrushers.DialogueSystem.AbstractUISubtitleControls
Subtitle currentSubtitle = null
 

Detailed Description

Manages subtitle panels for StandardDialogueUI.

Member Function Documentation

◆ ApplyQueuedActorPanelCache()

virtual void PixelCrushers.DialogueSystem.StandardUISubtitleControls.ApplyQueuedActorPanelCache ( )
inlinevirtual

Apply any actor panel cache values that ConversationStateSaver may have queued when loading a saved game.

Only applies built-in panel numbers, not custom panels.

◆ AreAnyPanelsClosing()

bool PixelCrushers.DialogueSystem.StandardUISubtitleControls.AreAnyPanelsClosing ( )
inline

◆ ClearCache()

void PixelCrushers.DialogueSystem.StandardUISubtitleControls.ClearCache ( )
inline

◆ ClearOverrideCache()

void PixelCrushers.DialogueSystem.StandardUISubtitleControls.ClearOverrideCache ( )
inline

◆ ClearSubtitle()

override void PixelCrushers.DialogueSystem.StandardUISubtitleControls.ClearSubtitle ( )
inline

◆ ClearSubtitlesOnCustomPanels()

virtual void PixelCrushers.DialogueSystem.StandardUISubtitleControls.ClearSubtitlesOnCustomPanels ( )
inlinevirtual

◆ Close()

void PixelCrushers.DialogueSystem.StandardUISubtitleControls.Close ( )
inline

Close all panels.

◆ ForceOverrideSubtitlePanel()

void PixelCrushers.DialogueSystem.StandardUISubtitleControls.ForceOverrideSubtitlePanel ( StandardUISubtitlePanel  customPanel)
inline

◆ GetActorTransform()

Transform PixelCrushers.DialogueSystem.StandardUISubtitleControls.GetActorTransform ( string  actorName)
inlineprotected

◆ GetActorTransformPanel()

StandardUISubtitlePanel PixelCrushers.DialogueSystem.StandardUISubtitleControls.GetActorTransformPanel ( Transform  speakerTransform,
StandardUISubtitlePanel  defaultPanel,
out DialogueActor  dialogueActor 
)
inline

◆ GetDialogueActorPanel()

StandardUISubtitlePanel PixelCrushers.DialogueSystem.StandardUISubtitleControls.GetDialogueActorPanel ( DialogueActor  dialogueActor)
inline

◆ GetPanel()

virtual StandardUISubtitlePanel PixelCrushers.DialogueSystem.StandardUISubtitleControls.GetPanel ( Subtitle  subtitle,
out DialogueActor  dialogueActor 
)
inlinevirtual

◆ GetPanelFromNumber()

StandardUISubtitlePanel PixelCrushers.DialogueSystem.StandardUISubtitleControls.GetPanelFromNumber ( SubtitlePanelNumber  subtitlePanelNumber,
StandardUISubtitlePanel  customPanel 
)
inline

◆ GetSubtitlePanelNumberFromPanel()

virtual SubtitlePanelNumber PixelCrushers.DialogueSystem.StandardUISubtitleControls.GetSubtitlePanelNumberFromPanel ( StandardUISubtitlePanel  panel)
inlineprotectedvirtual

◆ GetTypewriterSpeed()

virtual float PixelCrushers.DialogueSystem.StandardUISubtitleControls.GetTypewriterSpeed ( )
inlinevirtual

◆ HideContinueButton()

override void PixelCrushers.DialogueSystem.StandardUISubtitleControls.HideContinueButton ( )
inlinevirtual

Hides the continue button.

Reimplemented from PixelCrushers.DialogueSystem.AbstractUISubtitleControls.

◆ HideOnResponseMenu()

virtual void PixelCrushers.DialogueSystem.StandardUISubtitleControls.HideOnResponseMenu ( )
inlinevirtual

◆ HideSubtitle()

void PixelCrushers.DialogueSystem.StandardUISubtitleControls.HideSubtitle ( Subtitle  subtitle)
inline

Hides a subtitle.

Parameters
subtitleSubtitle associated with panel to hide.

◆ Initialize()

void PixelCrushers.DialogueSystem.StandardUISubtitleControls.Initialize ( StandardUISubtitlePanel[]  subtitlePanels,
StandardUISubtitlePanel  defaultNPCSubtitlePanel,
StandardUISubtitlePanel  defaultPCSubtitlePanel 
)
inline

◆ OpenSubtitlePanelLikeStart()

void PixelCrushers.DialogueSystem.StandardUISubtitleControls.OpenSubtitlePanelLikeStart ( SubtitlePanelNumber  subtitlePanelNumber)
inline

◆ OpenSubtitlePanelsOnStartConversation()

void PixelCrushers.DialogueSystem.StandardUISubtitleControls.OpenSubtitlePanelsOnStartConversation ( StandardDialogueUI  ui)
inline

Searches the current conversation for any DialogueActors who use subtitle panels that are configured to appear when the conversation starts.

◆ OverrideActorPanel() [1/2]

void PixelCrushers.DialogueSystem.StandardUISubtitleControls.OverrideActorPanel ( Actor  actor,
SubtitlePanelNumber  subtitlePanelNumber,
StandardUISubtitlePanel  customPanel = null,
bool  immediate = false 
)
inline

For speakers who do not have DialogueActor components, this method overrides the actor's default panel.

◆ OverrideActorPanel() [2/2]

void PixelCrushers.DialogueSystem.StandardUISubtitleControls.OverrideActorPanel ( DialogueActor  dialogueActor,
SubtitlePanelNumber  subtitlePanelNumber,
StandardUISubtitlePanel  customPanel = null 
)
inline

Overrides a DialogueActor's subtitle panel.

Parameters
dialogueActorDialogueActor whose panel to override for this conversation.
subtitlePanelNumberNew subtitle panel number.
customPanelOnly used if subtitlePanelNumber is Custom.

◆ QueueSavedActorPanelCache()

virtual void PixelCrushers.DialogueSystem.StandardUISubtitleControls.QueueSavedActorPanelCache ( List< string >  actorGOs,
List< SubtitlePanelNumber actorGOPanels,
List< int >  actorIDs,
List< SubtitlePanelNumber actorIDPanels 
)
inlinevirtual

Queues actor panel caches to be applies when the next conversation starts.

◆ RecordActorPanelCache()

virtual void PixelCrushers.DialogueSystem.StandardUISubtitleControls.RecordActorPanelCache ( out List< string >  actorGOs,
out List< SubtitlePanelNumber actorGOPanels,
out List< int >  actorIDs,
out List< SubtitlePanelNumber actorIDPanels,
out List< string >  actorNames 
)
inlinevirtual

Record the current actor panel cache values for saved games (ConversationStateSaver) so the cache can be restored when loading a game.

Only saves built-in panel numbers, not custom panels.

◆ SetActive()

override void PixelCrushers.DialogueSystem.StandardUISubtitleControls.SetActive ( bool  value)
inline

◆ SetActorPortraitSprite()

override void PixelCrushers.DialogueSystem.StandardUISubtitleControls.SetActorPortraitSprite ( string  actorName,
Sprite  portraitSprite 
)
inlinevirtual

Sets the portrait sprite to use in the subtitle if the named actor is the speaker.

This is used to immediately update the GUI control if the SetPortrait() sequencer command changes the portrait sprite.

Parameters
actorNameActor name in database.
portraitSpritePortrait sprite.

Reimplemented from PixelCrushers.DialogueSystem.AbstractUISubtitleControls.

◆ SetActorSubtitlePanelNumber()

virtual void PixelCrushers.DialogueSystem.StandardUISubtitleControls.SetActorSubtitlePanelNumber ( DialogueActor  dialogueActor,
SubtitlePanelNumber  subtitlePanelNumber 
)
inlinevirtual

Changes a dialogue actor's panel for the current conversation.

Can still be overridden by [panel=#] tags.

◆ SetLastActorToUsePanel()

void PixelCrushers.DialogueSystem.StandardUISubtitleControls.SetLastActorToUsePanel ( StandardUISubtitlePanel  panel,
int  actorID 
)
inline

◆ SetSubtitle()

override void PixelCrushers.DialogueSystem.StandardUISubtitleControls.SetSubtitle ( Subtitle  subtitle)
inline

◆ SetTypewriterSpeed()

virtual void PixelCrushers.DialogueSystem.StandardUISubtitleControls.SetTypewriterSpeed ( float  charactersPerSecond)
inlinevirtual

◆ ShowActorInPanel()

void PixelCrushers.DialogueSystem.StandardUISubtitleControls.ShowActorInPanel ( Actor  actor,
SubtitlePanelNumber  subtitlePanelNumber,
StandardUISubtitlePanel  customPanel = null 
)
inline

◆ ShowContinueButton()

override void PixelCrushers.DialogueSystem.StandardUISubtitleControls.ShowContinueButton ( )
inlinevirtual

Shows the continue button.

Reimplemented from PixelCrushers.DialogueSystem.AbstractUISubtitleControls.

◆ ShowSubtitle()

override void PixelCrushers.DialogueSystem.StandardUISubtitleControls.ShowSubtitle ( Subtitle  subtitle)
inlinevirtual

Shows a subtitle.

Opens a subtitle panel and sets the content. If the speaker has a DialogueActor component, this may dictate which panel opens.

Parameters
subtitleSubtitle to show.

Reimplemented from PixelCrushers.DialogueSystem.AbstractUISubtitleControls.

◆ StageFocusedPanel()

StandardUISubtitlePanel PixelCrushers.DialogueSystem.StandardUISubtitleControls.StageFocusedPanel ( Subtitle  subtitle)
inline

Sets the panel that will receive focus for the specified subtitle.

When delaying the display of the subtitle while the main dialogue panel is opening, we still need a reference to the subtitle panel to handle continue button stuff once the main panel is open.

◆ SupercedeOtherPanels()

virtual void PixelCrushers.DialogueSystem.StandardUISubtitleControls.SupercedeOtherPanels ( StandardUISubtitlePanel  newPanel)
inlineprotectedvirtual

◆ SupercedeOtherPanelsInList()

virtual void PixelCrushers.DialogueSystem.StandardUISubtitleControls.SupercedeOtherPanelsInList ( List< StandardUISubtitlePanel list,
StandardUISubtitlePanel  newPanel 
)
inlineprotectedvirtual

◆ UnfocusAll()

virtual void PixelCrushers.DialogueSystem.StandardUISubtitleControls.UnfocusAll ( )
inlinevirtual

Property Documentation

◆ allowDialogueActorCustomPanels

virtual bool PixelCrushers.DialogueSystem.StandardUISubtitleControls.allowDialogueActorCustomPanels = true
getset

◆ defaultNPCPanel

StandardUISubtitlePanel PixelCrushers.DialogueSystem.StandardUISubtitleControls.defaultNPCPanel
getset

◆ defaultPCPanel

StandardUISubtitlePanel PixelCrushers.DialogueSystem.StandardUISubtitleControls.defaultPCPanel
getset

◆ hasText

override bool PixelCrushers.DialogueSystem.StandardUISubtitleControls.hasText
get

Indicates whether the focused subtitle contains text.


The documentation for this class was generated from the following file: