System.Text.Json.Nodes.JsonObject RootObject { get; set; }

robot_2Generated
code_blocksInput

Description

The RootObject property of the PrefabFile class contains the original JSON data that was read from a file. This property is of type System.Text.Json.Nodes.JsonObject, which allows for easy manipulation and access to the JSON structure.

Usage

Use the RootObject property to access or modify the JSON data associated with a prefab file. This can be useful for dynamically changing prefab configurations or for reading specific data points from the JSON structure.

Example

// Example of accessing the RootObject property
PrefabFile prefab = new PrefabFile();
JsonObject jsonObject = prefab.RootObject;

// Access a specific property in the JSON
string someValue = jsonObject["SomeKey"].ToString();

// Modify a property in the JSON
jsonObject["SomeKey"] = "NewValue";