Overview
Theget_project_structure tool provides intelligent hierarchy generation for your Roblox game project. This key tool generates a complete structural overview with configurable depth exploration and optional script-only filtering.
Performance Tip: Use
maxDepth values between 5-10 for comprehensive exploration. The default depth of 3 may not reveal deeper nested structures.Parameters
Optional path to start exploration from using dot notation (e.g.,
game.Workspace, game.ServerStorage.Weapons).- Defaults to workspace root if empty
- Supports full Roblox instance paths
- Enables focused exploration of specific areas
Maximum depth to traverse the hierarchy. RECOMMENDED: Use 5-10 for thorough exploration.
- Default: 3 (may be too shallow for complex projects)
- Recommended: 5-10 for comprehensive structure analysis
- Higher values provide more complete structure but take longer to process
- Critical for discovering deeply nested components
Filter flag to show only scripts and script containers.
true: Returns only Script, LocalScript, ModuleScript, and their parent containersfalse: Returns complete hierarchy including all instance types- Useful for code analysis and script dependency mapping
Service Overview
When called without a path,get_project_structure returns a comprehensive service overview:
- Lists all major Roblox services (Workspace, ServerScriptService, ReplicatedStorage, etc.)
- Shows child counts for each service
- Provides high-level project organization view
- Helps identify where different components are located
Path-Based Exploration
Target specific areas of your project by providing a path:Script-Only Filtering
EnablescriptsOnly to focus exclusively on code structure:
- Shows Script, LocalScript, and ModuleScript instances
- Includes parent folders/containers for context
- Excludes non-script instances (Parts, Models, etc.)
- Perfect for understanding code architecture
Rich Metadata
The tool returns comprehensive metadata for each instance:Script Status
- Enabled/Disabled: Indicates if scripts are active
- Source length: Character count of script code
- Script type: Identifies Script, LocalScript, or ModuleScript
GUI Intelligence
- UI element types: Identifies ScreenGui, Frame, TextLabel, etc.
- UI hierarchy: Shows parent-child relationships in interfaces
- Layout structure: Reveals UI organization patterns
General Instance Data
- ClassName: Roblox instance type (Part, Folder, Script, etc.)
- Name: Instance name
- Path: Full dot-notation path for reference
- Children count: Number of child instances
- Properties: Key properties relevant to instance type
Performance Considerations
Depth Selection Strategy
Optimization Tips
- Use path filtering: Target specific areas instead of scanning entire project
- Enable scriptsOnly when appropriate: Dramatically reduces data for code analysis
- Start with lower depth: Increase gradually if needed
- Combine with other tools: Use with
search_objectsorget_instance_childrenfor focused queries
Response Format
Returns a hierarchical JSON structure:Usage Examples
Example 1: Project Overview
Get a high-level view of your entire project:Example 2: Deep Dive into Specific Area
Analyze a complex model or system:Example 3: Script Architecture Analysis
Map all scripts in your project:Example 4: UI Structure Exploration
Examine user interface hierarchy:Example 5: Workspace Organization
Review workspace contents with moderate depth:Common Patterns
Progressive Exploration
Start shallow, then go deeper:Combined with Search
Use structure analysis to inform targeted searches:Related Tools
- get_file_tree: Alternative hierarchy view with different formatting
- search_objects: Find specific instances by name or class
- get_instance_children: Get immediate children of a specific instance
- search_files: Search by name, type, or script content
- get_services: List all available Roblox services
Best Practices
- Always specify maxDepth for complex projects: Default of 3 is often insufficient
- Use path parameter to focus exploration: Avoid scanning entire project when targeting specific areas
- Enable scriptsOnly for code analysis: Significantly reduces noise when reviewing code structure
- Start with service overview: Call without parameters first to understand project organization
- Combine with other tools: Use alongside search and property tools for comprehensive analysis
- Monitor performance: Very deep hierarchies (maxDepth > 10) may take longer to process
Troubleshooting
Structure seems incomplete
Structure seems incomplete
Increase
maxDepth parameter. Default value of 3 may not reach deeper nested instances. Try values between 5-10.Too much data returned
Too much data returned
- Use
pathparameter to focus on specific areas - Enable
scriptsOnlyif analyzing code structure - Reduce
maxDepthto limit traversal
Can't find specific instances
Can't find specific instances
- Ensure
maxDepthis high enough to reach them - Verify path parameter is correct (use dot notation)
- Consider using
search_objectsfor targeted queries
Scripts not showing up
Scripts not showing up
Check that scripts aren’t disabled or archived. Use
scriptsOnly=true to filter for script instances only.Technical Details
HTTP Endpoint
When using HTTP mode, this tool maps to:Request Body
Plugin Implementation
The Studio plugin executes this tool by:- Resolving the starting path (defaults to game root)
- Recursively traversing children up to maxDepth
- Applying scriptsOnly filter if enabled
- Collecting metadata for each instance
- Building hierarchical JSON structure
- Returning complete structure to MCP server