Beispiel #1
0
 public DialogueComponent(int _id, int _nextId, string _speaker, string _text)
 {
     speaker       = _speaker;
     text          = _text;
     id            = _id;
     nextId        = _nextId;
     choiceWrapper = new ChoiceWrapper();
 }
Beispiel #2
0
 public DialogueComponent(int _id, int _nextId, string _speaker, string _text, Constants.Action _action)
 {
     speaker       = _speaker;
     text          = _text;
     id            = _id;
     nextId        = _nextId;
     choiceWrapper = new ChoiceWrapper();
     action        = _action;
 }
		private void FillLocationTypeChoice(ChoiceWrapper cho, bool addCompositeTypes)
		{
			cho.Clear();
			LocationTypeInfo typeInfo;
			if (addCompositeTypes)
			{
				typeInfo = Location.LocationTypeInfo(LocationType.Any);
				if (typeInfo.ShowFor(mLocDb.DatabaseType))
					cho.Add(typeInfo.FriendlyName, LocationType.Any);

				typeInfo = Location.LocationTypeInfo(LocationType.AnyPortal);
				if (typeInfo.ShowFor(mLocDb.DatabaseType))
					cho.Add(typeInfo.FriendlyName, LocationType.AnyPortal);
			}
			int customIndex = 0;
			foreach (LocationType type in Enum.GetValues(typeof(LocationType)))
			{
				if (type != LocationType.Any && type != LocationType.AnyPortal && type != LocationType._Unknown)
				{
					if (type == LocationType.Custom)
					{
						customIndex = cho.Count;
					}
					typeInfo = Location.LocationTypeInfo(type);
					if (typeInfo.ShowFor(mLocDb.DatabaseType))
						cho.Add(typeInfo.FriendlyName, type);
				}
			}
			cho.Selected = addCompositeTypes ? 0 : customIndex;
		}
		//
		#region Atlas > Route Tab
		//
		private void LoadRouteChoice(ChoiceWrapper choice, char firstLetter)
		{
			choice.Clear();
			choice.Add("<Custom>", Location.NO_LOCATION);
			foreach (Location loc in mLocDb.GetAlphaIndex(firstLetter))
			{
				choice.Add(loc.Name, loc);
			}
			choice.Selected = 0;
		}