// Sets up the house assiging its colour to its renderer and creating the object that is used to uniquely identify it public void Setup(Material wallMaterial, HouseColour colour, GameObject packageTypePrefab, PackageType packageType) { houseInfo = new HouseStruct(colour, packageType); foreach (MeshRenderer renderer in renderers) renderer.material = wallMaterial; }
public void NewPackage() { currentPackage = new HouseStruct(true); currentPackageColourImage.texture = colourTextures[(int)currentPackage.colour]; currentPackageImage.gameObject.SetActive(true); currentPackageImage.texture = packageTypeTextures[(int)currentPackage.packageType]; currentPackageColourText.text = System.Threading.Thread.CurrentThread.CurrentCulture.TextInfo.ToTitleCase(currentPackage.colour.ToString().ToLower()) + " House"; currentPackageTypeText.text = currentPackage.packageType == PackageType.BBQ ?"With " + "BBQ" : "With " + System.Threading.Thread.CurrentThread.CurrentCulture.TextInfo.ToTitleCase(currentPackage.packageType.ToString().ToLower()); }
public void Setup(GameObject car, HouseStruct packageInfo) { this.car = car; this.packageInfo = packageInfo; }