Loading...
Searching...
No Matches
AdventureCore.DialogUI Class Reference

Detailed Description

dialog implementation to be used with Unity UI and legacy Text components

https://adventure.softleitner.com/manual/utilities

Inheritance diagram for AdventureCore.DialogUI:
AdventureCore.DialogBase

Public Member Functions

void OnSubmit (BaseEventData eventData)
 
void OnCancel (BaseEventData eventData)
 
void OnPointerClick (PointerEventData eventData)
 
override void Focus ()
 
- Public Member Functions inherited from AdventureCore.DialogBase
virtual void Show (string title, string text, Action< DialogResult > onClose, DialogButtons buttons=DialogButtons.Ok, DialogResult selection=DialogResult.None, DialogInput input=DialogInput.None, string inputValue=null, Sprite image=null)
 
virtual void Show (string title, string[] texts, Action< DialogResult > onClose, DialogButtons buttons=DialogButtons.Ok, DialogResult selection=DialogResult.None, DialogInput input=DialogInput.None, string inputValue=null, Sprite image=null)
 
virtual void Show (string title, string text, Action< DialogResult > onClose, string[] options, DialogResult selection=DialogResult.None, DialogInput input=DialogInput.None, string inputValue=null, Sprite image=null)
 
virtual void Show (string title, string[] texts, Action< DialogResult > onClose, string[] options, DialogResult selection=DialogResult.None, DialogInput input=DialogInput.None, string inputValue=null, Sprite image=null)
 
virtual void SetDefault ()
 
virtual void SetAbort ()
 
virtual void SetOk ()
 
virtual void SetCancel ()
 
virtual void SetDialogResult (DialogResult result)
 
virtual bool Continue ()
 
virtual void StartTimeline (DialogBehaviour behaviour)
 
virtual void EndTimeline (DialogBehaviour behaviour)
 
virtual void SetTimelineProgress (DialogBehaviour behaviour, float value)
 
virtual void SetTimelineWait (DialogBehaviour behaviour)
 
virtual void SetTimelineOpacity (float value)
 

Public Attributes

Text Title
 
Text Content
 
Image Image
 
float CharacterDelay
 
CanvasGroup CharacterDelayControls
 
InputField Input
 
Button Ok
 
Button Yes
 
Button No
 
Button Cancel
 
Button OptionPrefab
 
Transform OptionParent
 
CanvasGroup FadeGroup
 
float FadeDuration
 
- Public Attributes inherited from AdventureCore.DialogBase
string Key
 
bool IsVisible
 
UnityEvent Opening
 
UnityEvent Continuing
 
UnityEvent Waiting
 
UnityEvent< DialogResult > Closing
 
UnityEvent< DialogResult > Closed
 

Protected Member Functions

override void Awake ()
 
override void initialize (string title, string[] texts, Action< DialogResult > onClose, DialogButtons buttons, string[] options, DialogResult selection, DialogInput input, string inputValue, Sprite image)
 
override bool tryContinue ()
 
override void setResult (DialogResult result)
 
override void initializeTimeline ()
 
override void clearTimeline (DialogResult result)
 
override void setTimelineProgress (float value)
 
override void setTimelineWait (DialogButtons buttons, DialogResult selection)
 
override void setTimelineOpacity (float value)
 
- Protected Member Functions inherited from AdventureCore.DialogBase
virtual void OnDestroy ()
 
virtual void OnApplicationFocus (bool focus)
 
virtual void onOpening ()
 
virtual void onContinue ()
 
virtual void onWaiting ()
 
virtual void onClosing (DialogResult result)
 
virtual void onClosed (DialogResult result)
 

Properties

override string InputString [get]
 
override int InputInteger [get]
 
override float InputFloat [get]
 
- Properties inherited from AdventureCore.DialogBase
static bool IsDialogVisible [get]
 
static DialogBase VisibleDialog [get]
 
DialogBehaviour CurrentBehaviour [get]
 
bool IsTimelineWaiting [get]
 
bool IsTimelineActive [get]
 
string TimelineFallbackTitle [get, set]
 
string TimelineFallbackContent [get, set]
 
string TimelineTitle [get]
 
string TimelineContent [get]
 
virtual DialogResult DialogResult [get, protected set]
 
string InputString [get]
 
int InputInteger [get]
 
float InputFloat [get]
 

Additional Inherited Members

- Static Public Member Functions inherited from AdventureCore.DialogBase
static DialogBase GetDialog (string key)
 
- Static Public Attributes inherited from AdventureCore.DialogBase
static DialogBase Main
 
static Dictionary< string, DialogBaseDialogs = new Dictionary<string, DialogBase>()
 
- Protected Attributes inherited from AdventureCore.DialogBase
Action< DialogResult > _onClose
 
bool _isOptionsDialog
 
DialogButtons _buttons
 
DialogResult _selection
 
DialogBehaviour _currentBehaviour
 
PlayableDirector _awaitingDirector
 
double? _targetYesOk
 
double? _targetNo
 
double? _targetCancel
 

Member Function Documentation

◆ Awake()

override void AdventureCore.DialogUI.Awake ( )
inlineprotectedvirtual

Reimplemented from AdventureCore.DialogBase.

◆ clearTimeline()

override void AdventureCore.DialogUI.clearTimeline ( DialogResult result)
inlineprotectedvirtual

Reimplemented from AdventureCore.DialogBase.

◆ Focus()

override void AdventureCore.DialogUI.Focus ( )
inlinevirtual

Reimplemented from AdventureCore.DialogBase.

◆ initialize()

override void AdventureCore.DialogUI.initialize ( string title,
string[] texts,
Action< DialogResult > onClose,
DialogButtons buttons,
string[] options,
DialogResult selection,
DialogInput input,
string inputValue,
Sprite image )
inlineprotectedvirtual

Reimplemented from AdventureCore.DialogBase.

◆ initializeTimeline()

override void AdventureCore.DialogUI.initializeTimeline ( )
inlineprotectedvirtual

Reimplemented from AdventureCore.DialogBase.

◆ setResult()

override void AdventureCore.DialogUI.setResult ( DialogResult result)
inlineprotectedvirtual

Reimplemented from AdventureCore.DialogBase.

◆ setTimelineOpacity()

override void AdventureCore.DialogUI.setTimelineOpacity ( float value)
inlineprotectedvirtual

Reimplemented from AdventureCore.DialogBase.

◆ setTimelineProgress()

override void AdventureCore.DialogUI.setTimelineProgress ( float value)
inlineprotectedvirtual

Reimplemented from AdventureCore.DialogBase.

◆ setTimelineWait()

override void AdventureCore.DialogUI.setTimelineWait ( DialogButtons buttons,
DialogResult selection )
inlineprotectedvirtual

Reimplemented from AdventureCore.DialogBase.

◆ tryContinue()

override bool AdventureCore.DialogUI.tryContinue ( )
inlineprotectedvirtual

Reimplemented from AdventureCore.DialogBase.