gdjson

package
v0.0.0-...-5eaf078 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 4, 2025 License: MIT Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Abstracted = map[string]bool{
	"RenderingDevice": true,
}
View Source
var Callables = map[string][]string{}/* 132 elements not displayed */
View Source
var ClassMethodOwnership = map[string]map[string]map[string]OwnershipSemantics{}/* 124 elements not displayed */
View Source
var Consitution = map[string]map[string]string{
	"AnimatedTexture":               {"MAX_": "int"},
	"AnimationNodeBlendTree":        {"CONNECTION_": "-"},
	"AudioStreamInteractive":        {"CLIP_": "Clip"},
	"AudioStreamPlaybackPolyphonic": {"INVALID_ID": "Stream"},
	"AudioStreamPlaylist":           {"MAX_": "int"},
	"AudioStreamSynchronized":       {"MAX_": "int"},
	"CanvasItem":                    {"NOTIFICATION_": "Object.Notification"},
	"Container":                     {"NOTIFICATION_": "Object.Notification"},
	"Control":                       {"NOTIFICATION_": "Object.Notification"},
	"DisplayServer": {
		"SCREEN_":              "Screen",
		"MAIN_WINDOW_ID":       "Window",
		"INVALID_WINDOW_ID":    "Window",
		"INVALID_INDICATOR_ID": "StatusIndicator",
	},
	"ENetPacketPeer": {
		"PACKET_LOSS_SCALE":     "",
		"PACKET_THROTTLE_SCALE": "",
		"FLAG_":                 "Flags",
	},
	"EditorSceneFormatImporter": {
		"IMPORT_": "Flags",
	},
	"EditorSettings": {"NOTIFICATION_": "Object.Notification"},
	"GLTFState":      {"HANDLE_BINARY_": "BinaryHandler"},
	"GPUParticles3D": {"MAX_": "int"},
	"GridMap":        {"INVALID_CELL_ITEM": "CellItem"},
	"IP": {
		"RESOLVER_MAX":        "",
		"RESOLVER_INVALID_ID": "",
	},
	"Image":             {"MAX_": ""},
	"InputEvent":        {"DEVICE_ID_": "-"},
	"MainLoop":          {"NOTIFICATION_": "Object.Notification"},
	"Material":          {"RENDER_PRIORITY": "RenderPriority"},
	"MultiplayerPeer":   {"TARGET_PEER_": "TargetPeer"},
	"Node":              {"NOTIFICATION_": "Object.Notification"},
	"Node3D":            {"NOTIFICATION_": "Object.Notification"},
	"RDFramebufferPass": {"ATTACHMENT_UNUSED": ""},
	"RenderingDevice":   {"INVALID_ID": "", "INVALID_FORMAT_ID": ""},
	"RenderingServer": {
		"MAX_":                         "int",
		"ARRAY_CUSTOM_COUNT":           "int",
		"ARRAY_WEIGHTS_SIZE":           "int",
		"CANVAS_ITEM_Z_MIN":            "int",
		"CANVAS_ITEM_Z_MAX":            "int",
		"MATERIAL_RENDER_PRIORITY_MIN": "int",
		"MATERIAL_RENDER_PRIORITY_MAX": "int",
		"PARTICLES_EMIT_FLAG":          "ParticlesEmitFlag",
		"NO_INDEX_ARRAY":               "-",
	},
	"ResourceUID": {
		"INVALID_ID": "Resource.UID",
	},
	"Skeleton3D":         {"NOTIFICATION_": "Object.Notification"},
	"TileSetAtlasSource": {"TRANSFORM_": ""},
	"VisualShader":       {"NODE_ID_": "NodeID"},
	"Window":             {"NOTIFICATION_": "Object.Notification"},
}
View Source
var Distinctions = map[string][][3]string{
	"AStar2D":                        {{"id", "int", "Point"}, {"get_id_path ", "PackedInt64Array", "[]Point"}, {"get_point_connections ", "PackedInt64Array", "[]Point"}, {"get_point_ids ", "PackedInt64Array", "[]Point"}},
	"AStar3D":                        {{"id", "int", "Point"}, {"get_id_path ", "PackedInt64Array", "[]Point"}, {"get_point_connections ", "PackedInt64Array", "[]Point"}, {"get_point_ids ", "PackedInt64Array", "[]Point"}},
	"AStarGrid2D":                    {{"id", "Vector2i", "Point"}, {"get_id_path ", "typedarray::Vector2i", "[]Point"}, {"get_point_connections ", "typedarray::Vector2i", "[]Point"}, {"get_point_ids ", "typedarray::Vector2i", "[]Point"}},
	"AudioServer":                    {{"bus_idx", "int", "Bus"}, {"effect_idx", "int", "Effect"}, {"bus index", "int", "Bus"}},
	"AudioStreamInteractive":         {{"clip", "int", "Clip"}},
	"AudioStreamPlaybackInteractive": {{"clip", "int", "AudioStreamInteractive.Clip"}, {"get_current_clip_index ", "int", "AudioStreamInteractive.Clip"}},
	"AudioStreamPlaybackPolyphonic":  {{"stream", "int", "Stream"}},
	"AudioStreamPlayer3D":            {{"angle", "float", "Angle.Radians"}, {"angle ", "float", "Angle.Radians"}, {"angle_degrees", "float", "Angle.Degrees"}, {"angle_degrees ", "float", "Angle.Degrees"}},
	"Bone2D":                         {{"angle", "float", "Angle.Radians"}, {"angle ", "float", "Angle.Radians"}},
	"CanvasItem":                     {{"rotation", "float", "Angle.Radians"}, {"angle ", "float", "Angle.Radians"}, {"angle", "float", "Angle.Radians"}},
	"CanvasLayer":                    {{"rotation", "float", "Angle.Radians"}, {"rotation ", "float", "Angle.Radians"}},
	"Control":                        {{"rotation ", "float", "Angle.Radians"}, {"rotation_degrees ", "float", "Angle.Degrees"}},
	"CharacterBody2D":                {{"angle", "float", "Angle.Radians"}, {"angle ", "float", "Angle.Radians"}, {"rotation_degrees ", "float", "Angle.Degrees"}, {"rotation ", "float", "Angle.Radians"}},
	"CharacterBody3D":                {{"angle", "float", "Angle.Radians"}, {"angle ", "float", "Angle.Radians"}},
	"CPUParticles3D":                 {{"angle", "float", "Angle.Radians"}, {"angle ", "float", "Angle.Radians"}},
	"CSGPolygon3D":                   {{"angle ", "float", "Angle.Radians"}},
	"DisplayServer":                  {{"screen", "int", "Screen"}, {"status_indicator id", "int", "StatusIndicator"}, {"create_status_indicator ", "int", "StatusIndicator"}, {"window_id", "int", "Window"}},
	"ENetPacketPeer":                 {{"flags", "int", "Flags"}},
	"EditorSceneFormatImporter":      {{"import_ flags", "int", "Flags"}},
	"Environment":                    {{"sky_rotation ", "Vector3", "Euler.Radians"}},
	"GLTFState":                      {{"handle_binary_image ", "int", "BinaryHandler"}},
	"GLTFLight":                      {{"angle", "float", "Angle.Radians"}, {"angle ", "float", "Angle.Radians"}},
	"GridMap":                        {{"item", "int", "CellItem"}, {"get_cell_item ", "int", "CellItem"}},
	"ImporterMesh":                   {{"_angle", "float", "Angle.Degrees"}},
	"Input":                          {{"device", "int", "Device"}},
	"InputEvent":                     {{"device value", "int", "Input.Device"}},
	"KinematicCollision2D":           {{"angle ", "float", "Angle.Radians"}},
	"KinematicCollision3D":           {{"angle ", "float", "Angle.Radians"}},
	"LookAtModifier3D":               {{"angle", "float", "Angle.Radians"}, {"angle ", "float", "Angle.Radians"}},
	"Material":                       {{"render_priority ", "int", "RenderPriority"}},
	"MultiplayerPeer":                {{"set_target_peer id", "int", "TargetPeer"}},
	"Node3D":                         {{"angle", "float", "Angle.Radians"}, {"rotation_degrees ", "Vector3", "Euler.Degrees"}, {"rotation ", "Vector3", "Euler.Radians"}},
	"Node2D":                         {{"radians", "float", "Angle.Radians"}, {"rotation_degrees ", "float", "Angle.Degrees"}, {"rotation ", "float", "Angle.Radians"}, {"get_angle_to ", "float", "Angle.Radians"}},
	"OpenXRCompositionLayerCylinder": {{"angle ", "float", "Angle.Radians"}},
	"OpenXRDpadBindingModifier":      {{"angle ", "float", "Angle.Radians"}, {"angle ", "float", "Angle.Radians"}},
	"OpenXRCompositionLayerEquirect": {{"angle ", "float", "Angle.Radians"}, {"angle ", "float", "Angle.Radians"}},
	"Polygon2D":                      {{"rotation", "float", "Angle.Radians"}, {"rotation ", "float", "Angle.Radians"}},
	"ParticleProcessMaterial":        {{"angle", "float", "Angle.Radians"}, {"angle ", "float", "Angle.Radians"}},
	"ProceduralSkyMaterial":          {{"angle", "float", "Angle.Radians"}, {"angle ", "float", "Angle.Radians"}},
	"PhysicalBone3D":                 {{"joint_rotation ", "Vector3", "Euler.Radians"}},
	"RenderingServer":                {{"emit_flags", "int", "ParticlesEmitFlag"}},
	"ResourceUID":                    {{"id", "int", "Resource.UID"}},
	"SkeletonModification2D":         {{"angle", "float", "Angle.Radians"}, {"clamp_angle min", "float", "Angle.Radians"}, {"clamp_angle max", "float", "Angle.Radians"}, {"clamp_angle ", "float", "Angle.Radians"}},
	"SkeletonModification2DLookAt":   {{"angle", "float", "Angle.Radians"}, {"angle ", "float", "Angle.Radians"}, {"rotation", "float", "Angle.Radians"}, {"get_additional_rotation ", "float", "Angle.Radians"}},
	"SkeletonModification2DCCDIK":    {{"angle", "float", "Angle.Radians"}, {"angle ", "float", "Angle.Radians"}, {"clamp_angle max", "float", "Angle.Radians"}},
	"TextureProgressBar":             {{"angle ", "float", "Angle.Radians"}},
	"VisualShader":                   {{"node", "int", "NodeID"}, {"id ", "int", "NodeID"}},
}
View Source
var Relocations = map[string]string{
	"TreeItem.get_tree":                              "Tree.get",
	"BaseButton.get_button_group":                    "ButtonGroup.get",
	"BaseButton.set_button_group":                    "ButtonGroup.set",
	"EditorNode3DGizmo.get_plugin":                   "EditorNode3DGizmoPlugin.get",
	"SkeletonModificationStack2D.add_modification":   "SkeletonModification2D.add",
	"SkeletonModificationStack2D.set_modification":   "SkeletonModification2D.set",
	"SkeletonModificationStack2D.get_modification":   "SkeletonModification2D.get",
	"SkeletonModificationStack2D.get_skeleton":       "Skeleton2D.get",
	"TextEdit.get_syntax_highlighter":                "SyntaxHighlighter.get",
	"TextEdit.set_syntax_highlighter":                "SyntaxHighlighter.set",
	"PackedScene.get_state":                          "SceneState.get",
	"Node.get_viewport":                              "Viewport.get",
	"Node.get_window":                                "Window.get",
	"Node.get_last_exclusive_window":                 "Window.get_last_exclusive",
	"Node.get_tree":                                  "SceneTree.get",
	"Tween.bind_node":                                "Node.bind_tween",
	"CanvasItem.draw_style_box":                      "StyleBox.draw",
	"Viewport.get_embedded_subwindows":               "Window.get_embedded_in_view",
	"OpenXRExtensionWrapperExtension.get_openxr_api": "OpenXRAPIExtension.get_from_wrapper_extension",
	"GLTFNode.get_scene_node_path":                   "GLTFState.get_scene_node_path",
	"GLTFBufferView.load_buffer_view_data":           "GLTFState.load_buffer_view_data",
	"Shape3D.get_debug_mesh":                         "ArrayMesh.get_debug",
	"Resource.get_local_scene":                       "Node.resource_local_scene",
	"StyleBox.draw":                                  "",
	"Tween.tween_property":                           "PropertyTweener.Make",
	"Tween.tween_method":                             "MethodTweener.Make",
}
View Source
var RelocationsReverse = map[string]map[string]string{}
View Source
var Renumeration = map[string]string{
	"Input.MouseMode":        "Input.MouseModeValue",
	"CameraServer.FeedImage": "CameraFeed.ImageType",
	"XRServer.TrackerType":   "XRTracker.Type",

	"Key":             "Input.Key",
	"KeyModifierMask": "Input.KeyModifierMask",
	"KeyLocation":     "Input.KeyLocation",
	"MouseButton":     "Input.MouseButton",
	"MouseButtonMask": "Input.MouseButtonMask",
	"JoyButton":       "Input.JoyButton",
	"JoyAxis":         "Input.JoyAxis",

	"Side":   "Rect2.Side",
	"Corner": "Rect2.Corner",

	"ClockDirection": "Angle.Direction",

	"Orientation":         "GUI.Orientation",
	"HorizontalAlignment": "GUI.HorizontalAlignment",
	"VerticalAlignment":   "GUI.VerticalAlignment",
	"InlineAlignment":     "GUI.InlineAlignment",

	"EulerOrder":  "Angle.Order",
	"MIDIMessage": "InputEventMIDI.Message",
	"Error":       "Error.Code",

	"PropertyHint":       "ClassDB.PropertyHint",
	"PropertyUsageFlags": "ClassDB.PropertyUsageFlags",
	"MethodFlags":        "ClassDB.MethodFlags",

	"Variant.Type":     "Variant.Type",
	"Variant.Operator": "Variant.Operator",
}
View Source
var Resources = map[string]reflect.Type{}/* 1682 elements not displayed */
View Source
var Structables = map[string]reflect.Type{}/* 163 elements not displayed */
View Source
var WavOptions = Named[struct {
	CompressionMode int     `gd:"compress/mode"`
	LoopBegin       int     `gd:"edit/loop_begin"`
	LoopEnd         int     `gd:"edit/loop_end"`
	LoopMode        int     `gd:"edit/loop_mode"`
	Normalize       int     `gd:"edit/normalize"`
	Trim            bool    `gd:"edit/trim"`
	ForceMinRate    bool    `gd:"force/8_bit"`
	ForceMaxRate    bool    `gd:"force/max_rate"`
	ForceMaxRateHz  Float.X `gd:"force/max_rate_hz"`
	ForceMono       bool    `gd:"force/mono"`
}]("Options")

Functions

func ConvertName

func ConvertName(fnName string) string

func IsTheDefaultValueZero

func IsTheDefaultValueZero(value string) bool

func Named

func Named[T any](name string) reflect.Type

Types

type Argument

type Argument struct {
	Name         string  `json:"name"`
	Type         string  `json:"type"`
	Meta         string  `json:"meta"`
	DefaultValue *string `json:"default_value"`
}

type Atlas

type Atlas struct {
	Points []Vector2.XY `gd:"points"`
	Size   Vector2i.XY  `gd:"size"`
}

type AuthorInfo

type AuthorInfo struct {
	LeadDevelopers  []string `gd:"lead_developers"`
	Founders        []string `gd:"founders"`
	ProjectManagers []string `gd:"project_managers"`
	Developers      []string `gd:"developers"`
}

type Class

type Class struct {
	Name    string `json:"name"`
	Rename  string `json:"rename,omitempty"`
	Package string `json:"package,omitempty"`
	IsEnum  bool   `json:"is_enum"`

	Description    string `json:"description"`
	IsRefcounted   bool   `json:"is_refcounted"`
	IsInstantiable bool   `json:"is_instantiable"`
	IsSingleton    bool
	IsEphemeral    bool

	IsKeyed   bool `json:"is_keyed"` // builtin class
	Operators []struct {
		Name       string `json:"name"`
		RightType  string `json:"right_type,omitempty"`
		ReturnType string `json:"return_type"`
	} `json:"operators"` // builtin class
	Constructors []struct {
		Index     int `json:"index"`
		Arguments []struct {
			Name string `json:"name"`
			Type string `json:"type"`
			Meta string `json:"meta"`
		} `json:"arguments,omitempty"`
	} `json:"constructors"` // builtin class
	HasDestructor      bool   `json:"has_destructor"`                 // builtin class
	IndexingReturnType string `json:"indexing_return_type,omitempty"` // builtin class

	Inherits string   `json:"inherits,omitempty"`
	APIType  string   `json:"api_type"`
	Enums    []Enum   `json:"enums,omitempty"`
	Methods  []Method `json:"methods,omitempty"`

	Members []struct {
		Name string `json:"name"`
		Type string `json:"type"`
	} `json:"members,omitempty"` // builtin class

	Signals    []Signal `json:"signals,omitempty"`
	Properties []struct {
		Type        string `json:"type"`
		Name        string `json:"name"`
		Description string `json:"description"`
		Setter      string `json:"setter"`
		Getter      string `json:"getter"`
		Index       *int   `json:"index"`
	} `json:"properties,omitempty"`
	Constants []struct {
		Name  string `json:"name"`
		Type  string `json:"type"` // builtin class
		Value any    `json:"value"`
	} `json:"constants,omitempty"`
}

type Commit

type Commit map[any]any

type CompletionInfo

type CompletionInfo struct {
	Kind         any             `gd:"kind" type:"CodeCompletionKind"`
	DisplayText  string          `gd:"display_text"`
	InsertText   string          `gd:"insert_text"`
	FontColor    Color.RGBA      `gd:"font_color"`
	Icon         Path.ToResource `gd:"icon"`
	DefaultValue string          `gd:"default_value"`
}

type Configuration

type Configuration struct {
	IceServers []IceServer `gd:"ice_servers"`
}

type Conn

type Conn struct {
	Connection any  `gd:"connection" type:"[1]gdclass.WebRTCPeerConnection"`
	Channels   any  `gd:"channels" type:"[][1]gdclass.WebRTCDataChannel"`
	Connected  bool `gd:"connected"`
}

type Connection

type Connection struct {
	FromNode  string `gd:"from_node"`
	FromPort  int    `gd:"from_port"`
	ToNode    string `gd:"to_node"`
	ToPort    int    `gd:"to_port"`
	KeepAlive bool   `gd:"keep_alive"`
}
type Copyright struct {
	Name  string `gd:"name"`
	Parts []Part `gd:"parts"`
}

type Date

type Date struct {
	Year    int `gd:"year"`
	Month   int `gd:"month"`
	Day     int `gd:"day"`
	Weekday int `gd:"weekday"`
	Hour    int `gd:"hour"`
	Minute  int `gd:"minute"`
	Second  int `gd:"second"`
}

type DateOnly

type DateOnly struct {
	Year    int `gd:"year"`
	Month   int `gd:"month"`
	Day     int `gd:"day"`
	Weekday int `gd:"weekday"`
}

type DiffFile

type DiffFile map[any]any

type DiffHunk

type DiffHunk map[any]any

type DiffLine

type DiffLine map[any]any

type DonorInfo

type DonorInfo struct {
	PlatinumSponsors []string `gd:"platinum_sponsors"`
	GoldSponsors     []string `gd:"gold_sponsors"`
	SilverSponsors   []string `gd:"silver_sponsors"`
	BronzeSponsors   []string `gd:"bronze_sponsors"`
	MiniSponsors     []string `gd:"mini_sponsors"`
	GoldDonors       []string `gd:"gold_donors"`
	SilverDonors     []string `gd:"silver_donors"`
	BronzeDonors     []string `gd:"bronze_donors"`
}

type Entry

type Entry struct {
	Color Color.RGBA `gd:"color"`
}

type Enum

type Enum struct {
	Name   string `json:"name"`
	Values []struct {
		Name        string `json:"name"`
		Value       int    `json:"value"`
		Description string `json:"description"`
	} `json:"values"`
}

type File

type File struct {
	Path         string   `gd:"path"`
	Tags         []string `gd:"tags"`
	TargetFolder string   `gd:"target_folder"`
}

type FileDialogOption

type FileDialogOption struct {
	Name    string   `gd:"name"`
	Values  []string `gd:"values"`
	Default int      `gd:"default"`
}

type FormatParameters

type FormatParameters struct {
	Output string `gd:"output"`
}

type GlobalClass

type GlobalClass struct {
	Base     string `gd:"base"`
	Class    string `gd:"class"`
	Icon     string `gd:"icon"`
	Language string `gd:"language"`
	Path     string `gd:"path"`
}

type IceServer

type IceServer struct {
	URLs       []string `gd:"urls"`
	Username   string   `gd:"username"`
	Credential string   `gd:"credential"`
}

type JoyInfo

type JoyInfo struct {
	XinputIndex       int    `gd:"xinput_index"`
	RawName           string `gd:"raw_name"`
	VendorID          string `gd:"vendor_id"`
	ProductID         string `gd:"product_id"`
	SteamInputPresent int    `gd:"steam_input_present"`
}

type LocalInterface

type LocalInterface struct {
	Index     string       `gd:"index"`
	Name      string       `gd:"name"`
	Friendly  string       `gd:"friendly"`
	Addresses []netip.Addr `gd:"addresses"`
}

type MemoryInfo

type MemoryInfo struct {
	Physical  int `gd:"physical"`
	Free      int `gd:"free"`
	Available int `gd:"available"`
	Stack     int `gd:"stack"`
}

type Method

type Method struct {
	Name        string `json:"name"`
	Description string `json:"description"`
	IsConst     bool   `json:"is_const"`
	IsVararg    bool   `json:"is_vararg"`
	IsStatic    bool   `json:"is_static"`
	IsVirtual   bool   `json:"is_virtual"`
	Hash        int64  `json:"hash"`
	ReturnType  string `json:"return_type"` // builtin class
	ReturnValue struct {
		Type string `json:"type"`
		Meta string `json:"meta"`
	} `json:"return_value,omitempty"`
	Arguments         []Argument `json:"arguments,omitempty"`
	ArgumentsRemapped []Argument
}

type Metrics

type Metrics struct {
	Max             Float.X `gd:"max"`
	Mean            Float.X `gd:"mean"`
	MeanSquared     Float.X `gd:"mean_squared"`
	RootMeanSquared Float.X `gd:"root_mean_squared"`
	PeakSNR         Float.X `gd:"peak_snr"`
}

type Notification

type Notification struct {
	Method string `gd:"method"`
	Params any    `gd:"params"`
}

type OnTheClock

type OnTheClock struct {
	Hour   int `gd:"hour"`
	Minute int `gd:"minute"`
	Second int `gd:"second"`
}

type Options

type Options struct {
	Negotiated        bool   `gd:"negotiated"`
	ID                int    `gd:"id"`
	MaxRetransmits    int    `gd:"max_retransmits"`
	MaxPacketLifeTime int    `gd:"max_packet_life_time"`
	Ordered           bool   `gd:"ordered"`
	Protocol          string `gd:"protocol"`
}

type OwnershipSemantics

type OwnershipSemantics int

OwnershipSemantics attempts to capture a proposal and pragmatic categorization around the ownership semantics for non-RefCounted godot objects.

const (
	// RefCountedManagement is the default ownership semantics for objects that
	// extend the RefCounted class.
	RefCountedManagement OwnershipSemantics = iota

	// OwnershipTransferred means that the receiver of the value is responsible
	// for freeing the memory associated with the value. After transferring the
	// ownership of a value this way, no direct references may be kept by the prior
	// owner, although they may keep copies of the InstanceID and use it to look
	// up the object in the future.
	OwnershipTransferred

	// ReversesTheOwnership applies to function arguments and means if (and only
	// if) the class is known to be the owner of the object, or is known to bind
	// the lifetime of this value, once the function returns, the caller will own
	// the object instead and is no longer under an obligation to keep it alive.
	// In such cases, the caller becomes responsible for freeing the object.
	ReversesTheOwnership

	// IsTemporaryReference only applies to function arguments and means that
	// the function borrows the argument (for the lifetime of the call) and does
	// not take ownership of it. The function may store the InstanceID of an
	// argument, in order to look it up in future.
	IsTemporaryReference

	// MustAssertInstanceID means that the receiver must always assert that
	// the instance ID is valid before using the object. The object may be
	// freed at any time.
	MustAssertInstanceID

	// LifetimeBoundToClass when applied to function arguments, means that the
	// receiver may keep a reference to the object and the caller must keep
	// it alive for as long as the class is alive. For return values, they
	// are only valid as long as the class they are returned from is alive,
	// the caller may not free the object.
	LifetimeBoundToClass
)

type Part

type Part struct {
	Files     []string `gd:"files"`
	Copyright []string `gd:"copyright"`
	License   string   `gd:"license"`
}

type PhysicsDirectSpaceState2D_Intersection

type PhysicsDirectSpaceState2D_Intersection struct {
	Collider   any        `gd:"collider" type:"Object.Instance"`
	ColliderID int64      `gd:"collider_id" type:"Object.ID"`
	Normal     Vector2.XY `gd:"normal"`
	Position   Vector2.XY `gd:"position"`
	RID        RID.Any    `gd:"rid"`
	Shape      int        `gd:"shape"`
}

type PhysicsDirectSpaceState2D_RestInfo

type PhysicsDirectSpaceState2D_RestInfo struct {
	ColliderID     int64      `gd:"collider_id" type:"Object.ID"`
	LinearVelocity Vector2.XY `gd:"linear_velocity"`
	Normal         Vector2.XY `gd:"normal"`
	Point          Vector2.XY `gd:"point"`
	RID            RID.Any    `gd:"rid"`
	Shape          int        `gd:"shape"`
}

type PhysicsDirectSpaceState3D_Intersection

type PhysicsDirectSpaceState3D_Intersection struct {
	Collider   any         `gd:"collider" type:"Object.Instance"`
	ColliderID int64       `gd:"collider_id" type:"Object.ID"`
	Normal     Vector3.XYZ `gd:"normal"`
	Position   Vector3.XYZ `gd:"position"`
	FaceIndex  int         `gd:"face_index"`
	RID        RID.Any     `gd:"rid"`
	Shape      int         `gd:"shape"`
}

type PhysicsDirectSpaceState3D_RestInfo

type PhysicsDirectSpaceState3D_RestInfo struct {
	ColliderID     int64       `gd:"collider_id" type:"Object.ID"`
	LinearVelocity Vector3.XYZ `gd:"linear_velocity"`
	Normal         Vector3.XYZ `gd:"normal"`
	Point          Vector3.XYZ `gd:"point"`
	RID            RID.Any     `gd:"rid"`
	Shape          int         `gd:"shape"`
}

type Pipe

type Pipe struct {
	Stdio  any `gd:"stdio" type:"[1]gdclass.FileAccess"`
	Stderr any `gd:"stderr" type:"[1]gdclass.FileAccess"`
	PID    int `gd:"pid"`
}

type PointData

type PointData struct {
	ID          Vector2i.XY `gd:"id"`
	Position    Vector2.XY  `gd:"position"`
	Solid       bool        `gd:"solid"`
	WeightScale Float.X     `gd:"weight_scale"`
}

type PropertyInfo

type PropertyInfo struct {
	ClassName  string       `gd:"class_name"`
	Name       string       `gd:"name"`
	Hint       int          `gd:"hint"`
	HintString string       `gd:"hint_string"`
	Type       reflect.Type `gd:"type"`
	Usage      int          `gd:"usage"`
}

type RangeConfig

type RangeConfig struct {
	Min  Float.X `gd:"min"`
	Max  Float.X `gd:"max"`
	Step Float.X `gd:"step"`
	Expr string  `gd:"expr"`
}

type Report

type Report struct {
	Error         Error.Code `gd:"result"`
	Files         []File     `gd:"so_files"`
	EmbeddedStart int        `gd:"embedded_start"`
	EmbeddedSize  int        `gd:"embedded_size"`
}

type Request

type Request struct {
	Method string `gd:"method"`
	Params any    `gd:"params"`
	ID     string `gd:"id"`
}

type Response

type Response struct {
	Result any    `gd:"result"`
	ID     string `gd:"id"`
}

type ResponseError

type ResponseError struct {
	Code    int    `gd:"code"`
	Message string `gd:"message"`
	ID      int    `gd:"id"`
}

type Signal

type Signal struct {
	Name      string `json:"name"`
	Arguments []struct {
		Name string `json:"name"`
		Type string `json:"type"`
		Meta string `json:"meta"`
	} `json:"arguments,omitempty"`
}

type SignalConnection

type SignalConnection struct {
	Signal   any               `gd:"signal" type:"SignalType.Any"`
	Callable Callable.Function `gd:"callable"`
	Flags    int               `gd:"Signal.ConnectFlags"`
}

type SignalInfo

type SignalInfo struct {
	Name        string         `gd:"name"`
	Flags       int            `gd:"flags"`
	ID          int            `gd:"id"`
	DefaultArgs []any          `gd:"default_args"`
	Args        []PropertyInfo `gd:"args"`
}

type Specification

type Specification struct {
	Header struct {
		VersionMajor    int    `json:"version_major"`
		VersionMinor    int    `json:"version_minor"`
		VersionPatch    int    `json:"version_patch"`
		VersionStatus   string `json:"version_status"`
		VersionBuild    string `json:"version_build"`
		VersionFullName string `json:"version_full_name"`
	} `json:"header"`
	BuiltinClassSizes []struct {
		BuildConfiguration string `json:"build_configuration"`
		Sizes              []struct {
			Name string `json:"name"`
			Size int    `json:"size"`
		} `json:"sizes"`
	} `json:"builtin_class_sizes"`
	BuiltinClassMemberOffsets []struct {
		BuildConfiguration string `json:"build_configuration"`
		Classes            []struct {
			Name    string `json:"name"`
			Members []struct {
				Member string `json:"member"`
				Offset int    `json:"offset"`
			} `json:"members"`
		} `json:"classes"`
	} `json:"builtin_class_member_offsets"`
	GlobalConstants  []interface{} `json:"global_constants"`
	GlobalEnums      []Enum        `json:"global_enums"`
	UtilityFunctions []struct {
		Name       string `json:"name"`
		ReturnType string `json:"return_type,omitempty"`
		Category   string `json:"category"`
		IsVararg   bool   `json:"is_vararg"`
		Hash       int    `json:"hash"`
		Arguments  []struct {
			Name string `json:"name"`
			Type string `json:"type"`
			Meta string `json:"meta"`
		} `json:"arguments,omitempty"`
	} `json:"utility_functions"`
	BuiltinClasses []Class `json:"builtin_classes"`
	Classes        []Class `json:"classes"`
	Singletons     []struct {
		Name string `json:"name"`
		Type string `json:"type"`
	} `json:"singletons"`
	NativeStructures []struct {
		Name   string `json:"name"`
		Format string `json:"format"`
	} `json:"native_structures"`
}

Specification of the Godot Extension API. Created with https://mholt.github.io/json-to-go/

func LoadSpecification

func LoadSpecification() (*Specification, error)

LoadSpecification, either from a local file or by downloading it from the Godot Github repository.

type StatusFile

type StatusFile map[any]any

type Structure

type Structure map[any]any

type Surface

type Surface map[any]any

type Template

type Template struct {
	Path  string `gd:"path"`
	Error string `gd:"error"`
}

type TextToSpeechVoice

type TextToSpeechVoice struct {
	Name     string `gd:"name"`
	ID       string `gd:"id"`
	Language string `gd:"language"`
}

type VersionInfo

type VersionInfo struct {
	Major     int    `gd:"major"`
	Minor     int    `gd:"minor"`
	Patch     int    `gd:"patch"`
	Hex       int    `gd:"hex"`
	Status    string `gd:"status"`
	Build     string `gd:"build"`
	Hash      string `gd:"hash"`
	Timestamp int    `gd:"timestamp"`
	String    string `gd:"string"`
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL