cocos_add_toggle_container
Attach a radio button group to Cocos Creator nodes so children toggle mutually exclusively, enabling UI controls without manual coding.
Instructions
Attach cc.ToggleContainer (radio group). Children are mutually exclusive.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"scene_path": "<scene_path>",
"node_id": "<node_id>"
},
"name": "cocos_add_toggle_container"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| scene_path | Yes | ||
| node_id | Yes | ||
| allow_switch_off | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |