/// <summary> /// Initialize the Pack with the values of the _packServer. /// </summary> /// <param name="_packServer"></param> public virtual void Initialize(PackServer _packServer) { id = _packServer.id; packName = _packServer.itemName; contents = GetContentFromServer(_packServer); image = Resources.Load <Sprite>(_packServer.image); ColorUtility.TryParseHtmlString(_packServer.color, out color); }
private List <PackContent> GetContentFromServer(PackServer _packServer) { contents = _packServer.contents; return(contents); }