private Vector3 GetUiLocationVector(UiLocation uiLocation) { if (uiLocation == UiLocation.Left) { return(new Vector3(0.02f, 0.8f, 0)); } return(new Vector3(0.88f, 0.8f, 0)); }
public void InitUi(string id, UiLocation uiLocation) { this.Log($"{nameof(InitUi)}", id, uiLocation); if (heroInfos.ContainsKey(id)) { throw new ArgumentException("This id was already initialized"); } var location = GetUiLocationVector(uiLocation); heroInfos[id] = new HeroInfo(id, location); }