Skip to content
Snippets Groups Projects
Commit 840604d5 authored by zohaib's avatar zohaib
Browse files

Added parameter in load

parent 874459b6
No related branches found
No related tags found
No related merge requests found
......@@ -140,7 +140,7 @@ public partial class CityGen : MonoBehaviour {
}
// Load the data about city.
public bool load(){
public bool load(string fileName = "data"){
string cityDataAsJson = System.IO.File.ReadAllText(Application.persistentDataPath + this.jsonFilePath);
city = JsonUtility.FromJson<City>(cityDataAsJson);
return (city != null);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment