Documentation
¶
Index ¶
- func Advanced() class
- func CaptureScriptBacktraces(include_variables bool) []ScriptBacktrace.Instance
- func GetArchitectureName() string
- func GetFramesDrawn() int
- func GetFramesPerSecond() Float.X
- func GetLicenseInfo() map[string]string
- func GetLicenseText() string
- func GetMainLoop() MainLoop.Instance
- func GetPhysicsFrames() int
- func GetPhysicsInterpolationFraction() Float.X
- func GetProcessFrames() int
- func GetScriptLanguage(index int) ScriptLanguage.Instance
- func GetScriptLanguageCount() int
- func GetSingleton(name string) Object.Instance
- func GetSingletonList() []string
- func GetWriteMoviePath() string
- func HasSingleton(name string) bool
- func IsEditorHint() bool
- func IsEmbeddedInEditor() bool
- func IsInPhysicsFrame() bool
- func Log(v ...any)
- func Logv(v ...any)
- func MaxFps() int
- func MaxPhysicsStepsPerFrame() int
- func PhysicsJitterFix() Float.X
- func PhysicsTicksPerSecond() int
- func Print(v ...any)
- func PrintErrorMessages() bool
- func PrintRich(v ...any)
- func PrintToStdout() bool
- func Println(v ...any)
- func Raise(err error)
- func RaiseWarning(v ...any)
- func RegisterScriptLanguage(language ScriptLanguage.Instance) error
- func RegisterSingleton(name string, instance Object.Instance)
- func SetMaxFps(value int)
- func SetMaxPhysicsStepsPerFrame(value int)
- func SetPhysicsJitterFix(value Float.X)
- func SetPhysicsTicksPerSecond(value int)
- func SetPrintErrorMessages(value bool)
- func SetPrintToStdout(value bool)
- func SetTimeScale(value Float.X)
- func TimeScale() Float.X
- func UnregisterScriptLanguage(language ScriptLanguage.Instance) error
- func UnregisterSingleton(name string)
- func Version() string
- type AuthorInfo
- type Copyright
- type DonorInfo
- type Extension
- type ID
- type Instance
- type Part
- type Pointer
- type Singleton
- type VersionInfo
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Advanced ¶
func Advanced() class
Advanced exposes a 1:1 low-level instance of the class, undocumented, for those who know what they are doing.
func CaptureScriptBacktraces ¶
func CaptureScriptBacktraces(include_variables bool) []ScriptBacktrace.Instance
func GetArchitectureName ¶
func GetArchitectureName() string
func GetFramesDrawn ¶
func GetFramesDrawn() int
func GetFramesPerSecond ¶
func GetLicenseInfo ¶
func GetLicenseText ¶
func GetLicenseText() string
func GetMainLoop ¶
func GetPhysicsFrames ¶
func GetPhysicsFrames() int
func GetProcessFrames ¶
func GetProcessFrames() int
func GetScriptLanguage ¶
func GetScriptLanguage(index int) ScriptLanguage.Instance
func GetScriptLanguageCount ¶
func GetScriptLanguageCount() int
func GetSingleton ¶
func GetSingletonList ¶
func GetSingletonList() []string
func GetWriteMoviePath ¶
func GetWriteMoviePath() string
func HasSingleton ¶
func IsEditorHint ¶
func IsEditorHint() bool
func IsEmbeddedInEditor ¶
func IsEmbeddedInEditor() bool
func IsInPhysicsFrame ¶
func IsInPhysicsFrame() bool
func Log ¶
func Log(v ...any)
Log prints one or more arguments to strings in the best way possible to standard error line
func Logv ¶
func Logv(v ...any)
Logv prints if verbose mode is enabled (OS.is_stdout_verbose returning true), converts one or more arguments of any type to string in the best way possible and prints them to the console.
func MaxPhysicsStepsPerFrame ¶
func MaxPhysicsStepsPerFrame() int
func PhysicsJitterFix ¶
func PhysicsTicksPerSecond ¶
func PhysicsTicksPerSecond() int
func Print ¶
func Print(v ...any)
Print prints one or more arguments to strings in the best way possible to the OS terminal. Unlike print, no newline is automatically added at the end.
func PrintErrorMessages ¶
func PrintErrorMessages() bool
func PrintRich ¶
func PrintRich(v ...any)
PrintRich converts one or more arguments of any type to string in the best way possible and prints them to the console.
The following BBCode tags are supported: b, i, u, s, indent, code, url, center, right, color, bgcolor, fgcolor.
Color tags only support the following named colors: black, red, green, yellow, blue, magenta, pink, purple, cyan, white, orange, gray. Hexadecimal color codes are not supported.
URL tags only support URLs wrapped by a URL tag, not URLs with a different title.
When printing to standard output, the supported subset of BBCode is converted to ANSI escape codes for the terminal emulator to display. Support for ANSI escape codes varies across terminal emulators, especially for italic and strikethrough. In standard output, code is represented with faint text but without any font change. Unsupported tags are left as-is in standard output.
func PrintToStdout ¶
func PrintToStdout() bool
func Println ¶
func Println(v ...any)
Println converts one or more arguments of any type to string in the best way possible and prints them to the console.
func Raise ¶
func Raise(err error)
Raise pushes an error message to Godot's built-in debugger and to the OS terminal.
func RaiseWarning ¶
func RaiseWarning(v ...any)
RaiseWarning pushes a warning message to Godot's built-in debugger and to the OS terminal.
func RegisterScriptLanguage ¶
func RegisterScriptLanguage(language ScriptLanguage.Instance) error
func RegisterSingleton ¶
func SetMaxPhysicsStepsPerFrame ¶
func SetMaxPhysicsStepsPerFrame(value int)
SetMaxPhysicsStepsPerFrame sets the property returned by [GetMaxPhysicsStepsPerFrame].
func SetPhysicsJitterFix ¶
SetPhysicsJitterFix sets the property returned by [GetPhysicsJitterFix].
func SetPhysicsTicksPerSecond ¶
func SetPhysicsTicksPerSecond(value int)
SetPhysicsTicksPerSecond sets the property returned by [GetPhysicsTicksPerSecond].
func SetPrintErrorMessages ¶
func SetPrintErrorMessages(value bool)
SetPrintErrorMessages sets the property returned by [IsPrintingErrorMessages].
func SetPrintToStdout ¶
func SetPrintToStdout(value bool)
SetPrintToStdout sets the property returned by [IsPrintingToStdout].
func SetTimeScale ¶
SetTimeScale sets the property returned by [GetTimeScale].
func UnregisterScriptLanguage ¶
func UnregisterScriptLanguage(language ScriptLanguage.Instance) error
func UnregisterSingleton ¶
func UnregisterSingleton(name string)
Types ¶
type AuthorInfo ¶
type AuthorInfo struct {
LeadDevelopers []string `gd:"lead_developers"`
Founders []string `gd:"founders"`
ProjectManagers []string `gd:"project_managers"`
Developers []string `gd:"developers"`
}
func GetAuthorInfo ¶
func GetAuthorInfo() AuthorInfo
type Copyright ¶
func GetCopyrightInfo ¶
func GetCopyrightInfo() []Copyright
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"`
}
func GetDonorInfo ¶
func GetDonorInfo() DonorInfo
type Extension ¶
Extension can be embedded in a new struct to create a Go extension of this class.
T must be a type that is embedding this Extension as the first field. It is unsafe and invalid to use this type directly, or embedded in any other way.
func (*Extension[T]) AsObject ¶
func (o *Extension[T]) AsObject() [1]gdreference.Object
type ID ¶
ID is a typed object ID (reference) to an instance of this class, use it to store references to objects with unknown lifetimes, as an ID will not panic on use if the underlying object has been destroyed.
type Instance ¶
Instance of the class with convieniently typed arguments and results.
func (Instance) AsObject ¶
func (o Instance) AsObject() [1]gdreference.Object
type Pointer ¶
Pointer is a typed pointer to a value of type T in engine memory. The pointer is valid until the next barrier (typically end of frame).
func Allocate ¶
func Allocate[T comparable](val T) Pointer[T]
Allocate a value of type T, must not contain pointers or channels.
Please be aware that the pointer returned from Allocate is not freed automatically. As such, be aware of possible memory leaks and/or cache and reuse Pointer[T] values.
type Singleton ¶
Singleton can be embedded in a new struct to create a Go singleton extension of the class.
It will become available as a global inside scripts and any any other Go Extension types will have any *T typed fields filled in to point at this singleton once they have been instantiated.
T must be a type that is embedding this Singleton as the first field. It is unsafe and invalid to use this type directly, or embedded in any other way.
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"`
}
func GetVersionInfo ¶
func GetVersionInfo() VersionInfo