Ejemplo n.º 1
0
        public void Save()
        {
            SaveToPlayerPrefs();
            var message = ((localizedText != null) && localizedText.ContainsField(gameSavedMessage))
                                ? localizedText[gameSavedMessage] : gameSavedMessage;

            DialogueManager.ShowAlert(message);
        }
Ejemplo n.º 2
0
 public void UseLocalizedText(LocalizedTextTable localizedText)
 {
     this.localizedText = localizedText;
     if (localizedText != null)
     {
         if (localizedText.ContainsField(originalTextValue))
         {
             text = localizedText[originalTextValue];
         }
     }
 }
Ejemplo n.º 3
0
 public override void OnEnter()
 {
     if (localizedTextTable == null)
     {
         LogError(string.Format("{0}: Localized text table is null.", DialogueDebug.Prefix));
     }
     else if ((field == null) || (string.IsNullOrEmpty(field.Value)))
     {
         LogError(string.Format("{0}: Field is null or blank.", DialogueDebug.Prefix));
     }
     else if (!localizedTextTable.ContainsField(field.Value))
     {
         LogError(string.Format("{0}: Localized text table {1} does not contain a field '{2}'.", new string[] { DialogueDebug.Prefix, localizedTextTable.name, field.Value }));
     }
     else
     {
         if (storeResult != null)
         {
             storeResult.Value = localizedTextTable[field.Value];
         }
     }
     Finish();
 }
Ejemplo n.º 4
0
 public void UseLocalizedText(LocalizedTextTable localizedText)
 {
     this.localizedText = localizedText;
     if (localizedText != null) {
         if (localizedText.ContainsField(originalTextValue)) {
             text = localizedText[originalTextValue];
         }
     }
 }