Tabletop Simulator

Tabletop Simulator

Not enough ratings
Component Explorer
   
Award
Favorite
Favorited
Unfavorite
Assets: Scripting
File Size
Posted
Updated
16.017 KB
27 Feb, 2020 @ 12:21am
27 Feb, 2020 @ 3:58pm
2 Change Notes ( view )

Subscribe to download
Component Explorer

Description
"I write spaghetti code, so you don't have to." Or maybe so you are now able to.

Tool for viewing child gameObjects, Components, and Variables. Helps with applying the Component scripting API. Generates code helpful for editing Variables, but does not edit anything on its own.

To use, enter an object's GUID in the GUID field and click outside the field. Buttons should appear at the bottom of the tool to navigate the object's Component structure. Blue buttons represent GameObjects, green buttons represent Components, and dark-blue-green buttons represent Variables. Clicking a Variable button will generate code to edit the value of that Variable in the Exported Code field, which you can then copy and paste elsewhere.

Occasionally, parts of the Exported Code will be misinterpreted as BBCode and appear incorrect. Selecting the text in the field fixes this.

You can save the tool object and deploy it elsewhere. Example objects are included in the save. They are not part of the tool.

You may distribute this tool as you wish, as long as you either give credit to Buckwheat or keep the logo on the tool visible.
8 Comments
Hiram Abiff 13 Oct, 2022 @ 2:18am 
This is some really good work. This tool helped me identify the correct component and it even gives me the code needed to adjust the value in my own script. Some real A+ work. :steamthumbsup:
cche 13 Feb, 2022 @ 10:13am 
and THANK YOU!
cche 13 Feb, 2022 @ 9:55am 
Ah! I understand. I changed '...[' ... to '...[ ' and ']...' to ' ]...' in the export_buffer building code, and the output is visible. I think I'm going to make it also log its output for me so I can accumulate a block of text in my atom console. I think that will help my personal workflow.
Buckwheat  [author] 12 Feb, 2022 @ 3:39pm 
@cche

You seem to be experiencing a display glitch due to Tabletop Simulator interpreting the string [11] as a color code. When I test with the example asset, I get the same issue, but I am still able to copy-paste the output text. https://youtu.be/QpbPz8hnq7Y is a recording of this.
cche 12 Feb, 2022 @ 11:36am 
I also noticed that I cannot seem to copy text (using ctrl-c) from the text box, It selects, but doesn't copy. That's not a big deal though. I can probably figure out a way to fix that.
cche 12 Feb, 2022 @ 11:28am 
Here's a screenshot. I have clicked the 11th "Generated", then "BoxCollid" then "enabled". The result is "getObjectFromGUID('c9eebe').getChildren()" I can see from earler entries what this one would be, but I cannot see details for the more interesting at the moment entries farther down.

https://steamhost.cn/steamcommunity_com/sharedfiles/filedetails/?id=2751520935
Buckwheat  [author] 11 Feb, 2022 @ 3:12pm 
@cche
I am not aware of a 10-item limit on arrays of children. In fact, the current version of the workshop contains a poker table whose first GameObject contains over 10 child GameObjects, and I can explore it without issue.

Are you able to provide an example of an asset for which the explorer throws errors?
cche 11 Feb, 2022 @ 10:51am 
My custom objects frequently exceed the ten item limit on the array of children in makeList. I am pretty sure the issue is with the name convention you are using, but that is based on 5 minutes looking at the code. I know it has been some time since you wrote this, but if you could provide some guidance, on the implementation, I would greatly appreciate it.