mirror of
				https://github.com/godotengine/godot.git
				synced 2025-10-31 21:51:22 +00:00 
			
		
		
		
	 2d20fc39aa
			
		
	
	
		2d20fc39aa
		
	
	
	
	
		
			
			We already removed it from the online docs with #35132. Currently it can only be "Built-In Types" (Variant types) or "Core" (everything else), which is of limited use. We might also want to consider dropping it from `ClassDB` altogether in Godot 4.0.
		
			
				
	
	
		
			52 lines
		
	
	
	
		
			2.1 KiB
		
	
	
	
		
			XML
		
	
	
	
	
	
			
		
		
	
	
			52 lines
		
	
	
	
		
			2.1 KiB
		
	
	
	
		
			XML
		
	
	
	
	
	
| <?xml version="1.0" encoding="UTF-8" ?>
 | |
| <class name="ScriptCreateDialog" inherits="ConfirmationDialog" version="3.2">
 | |
| 	<brief_description>
 | |
| 		The Editor's popup dialog for creating new [Script] files.
 | |
| 	</brief_description>
 | |
| 	<description>
 | |
| 		The [ScriptCreateDialog] creates script files according to a given template for a given scripting language. The standard use is to configure its fields prior to calling one of the [method Popup.popup] methods.
 | |
| 		[codeblock]
 | |
| 		func _ready():
 | |
| 		    dialog.config("Node", "res://new_node.gd") # For in-engine types
 | |
| 		    dialog.config("\"res://base_node.gd\"", "res://derived_node.gd") # For script types
 | |
| 		    dialog.popup_centered()
 | |
| 		[/codeblock]
 | |
| 	</description>
 | |
| 	<tutorials>
 | |
| 	</tutorials>
 | |
| 	<methods>
 | |
| 		<method name="config">
 | |
| 			<return type="void">
 | |
| 			</return>
 | |
| 			<argument index="0" name="inherits" type="String">
 | |
| 			</argument>
 | |
| 			<argument index="1" name="path" type="String">
 | |
| 			</argument>
 | |
| 			<argument index="2" name="built_in_enabled" type="bool" default="true">
 | |
| 			</argument>
 | |
| 			<argument index="3" name="load_enabled" type="bool" default="true">
 | |
| 			</argument>
 | |
| 			<description>
 | |
| 				Prefills required fields to configure the ScriptCreateDialog for use.
 | |
| 			</description>
 | |
| 		</method>
 | |
| 	</methods>
 | |
| 	<members>
 | |
| 		<member name="dialog_hide_on_ok" type="bool" setter="set_hide_on_ok" getter="get_hide_on_ok" override="true" default="false" />
 | |
| 		<member name="margin_bottom" type="float" setter="set_margin" getter="get_margin" override="true" default="232.0" />
 | |
| 		<member name="margin_right" type="float" setter="set_margin" getter="get_margin" override="true" default="361.0" />
 | |
| 		<member name="rect_size" type="Vector2" setter="_set_size" getter="get_size" override="true" default="Vector2( 361, 232 )" />
 | |
| 		<member name="window_title" type="String" setter="set_title" getter="get_title" override="true" default=""Attach Node Script"" />
 | |
| 	</members>
 | |
| 	<signals>
 | |
| 		<signal name="script_created">
 | |
| 			<argument index="0" name="script" type="Script">
 | |
| 			</argument>
 | |
| 			<description>
 | |
| 				Emitted when the user clicks the OK button.
 | |
| 			</description>
 | |
| 		</signal>
 | |
| 	</signals>
 | |
| 	<constants>
 | |
| 	</constants>
 | |
| </class>
 |