idTech4.idDict.GetInteger C# (CSharp) Method

GetInteger() public method

public GetInteger ( string key, int defaultValue ) : int
key string
defaultValue int
return int
		public int GetInteger(string key, int defaultValue = 0)
		{
			string str;

			if(_dict.TryGetValue(key, out str) == true)
			{
				int tmp;
				int.TryParse(str, out tmp);

				return tmp;
			}

			return defaultValue;
		}