public void Collect(L20nCore.External.InfoCollector info) { info.Add("name", m_Name); info.Add("followers", () => Followers); info.Add("gender", m_Gender); if (BestFriend != null) info.Add("friend", BestFriend); }
public void Collect(L20nCore.External.InfoCollector info) { info.Add("width", () => 1920); info.Add("height", () => 1080); }
public void Collect (L20nCore.External.InfoCollector info) { info.Add ("width", () => Screen.width); info.Add ("height", () => Screen.height); info.Add ("dpi", () => (int)Screen.dpi); info.Add ("orientation", () => { switch (Screen.orientation) { case ScreenOrientation.Landscape: return "landscape"; case ScreenOrientation.LandscapeRight: return "landscape"; case ScreenOrientation.Portrait: return "portrait"; case ScreenOrientation.PortraitUpsideDown: return "portrait"; case ScreenOrientation.AutoRotation: return Screen.width > Screen.height ? "landscape" : "portrait"; } return "unknown"; }); }
public void Collect (L20nCore.External.InfoCollector info) { info.Add ("name", m_Name); info.Add ("count", m_Count); }
/// <summary> /// Get the translation (entity) for the current locale, with the default locale as a fallback. /// This method will return the given id if it could not be translated or found. /// The given <c>parameter_value</c> will get bound with the given <c>parameter_key</c> as an external value ($-syntax), /// and will be available during the translation of the given <c>id</c>. /// </summary> /// <remarks> /// Note that the <c>id</c> can be a simple identifier or a property-expression. /// Meaning that you can have something like `foo` but also `foo.bar` or `foo.bar.baz`. /// A property expression uses the dot `.` syntax and allows you to specify values within your /// hash-tables used as values in your Entity. The default or index will be used in case a property /// identifier couldn't be found. /// For string-values this extra property identifier will simply be ignored. /// Meaning that something like `foo.bar` would be equal to `foo`. /// </remarks> public static string Translate (string id, string parameter_key, L20nCore.External.IHashValue parameter_value) { return GetCore ().Translate (id, parameter_key, parameter_value); }