public void AddNewShame(PictureData _pData, MatchData mData) { shameData.AddNewShame(_pData.rawData, mData); GameObject shameImageObject = CreateImageInWall(_pData); ShameImage shameHolder = shameImageObject.GetComponent <ShameImage>(); shameHolder.SetDataInText(mData); SaveSystem.FormatAndSaveShameData(this); }
private void LoadShameImages() { WebCamTexture wTexture = wManager.WcTexture(); for (int i = 0; i < shameData.numberOfShames; i++) { PictureData pData = new PictureData(wTexture.width, wTexture.height, shameData.imgBytes[i]); MatchData mData = new MatchData(shameData.playerNames[i], shameData.dates[i], shameData.scores[i]); GameObject shameImageObject = CreateImageInWall(pData); ShameImage shameHolder = shameImageObject.GetComponent <ShameImage>(); shameHolder.SetDataInText(mData); } }