SkeletonProfile

package
v0.0.0-...-e10d1cd Latest Latest
Warning

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

Go to latest
Published: Sep 17, 2025 License: MIT Imports: 26 Imported by: 0

Documentation

Overview

This resource is used in EditorScenePostImport. Some parameters are referring to bones in Skeleton3D, Skin, Animation, and some other nodes are rewritten based on the parameters of SkeletonProfile.

Note: These parameters need to be set only when creating a custom profile. In SkeletonProfileHumanoid, they are defined internally as read-only values.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Advanced

type Advanced = class

Advanced exposes a 1:1 low-level instance of the class, undocumented, for those who know what they are doing.

type Any

type Any interface {
	gd.IsClass
	AsSkeletonProfile() Instance
}

type Extension

type Extension[T gdclass.Interface] struct{ gdclass.Extension[T, Instance] }

Extension can be embedded in a new struct to create an extension of this class. T should be the type that is embedding this Extension

func (*Extension[T]) AsObject

func (self *Extension[T]) AsObject() [1]gd.Object

func (*Extension[T]) AsRefCounted

func (self *Extension[T]) AsRefCounted() [1]gd.RefCounted

func (*Extension[T]) AsResource

func (self *Extension[T]) AsResource() Resource.Instance

func (*Extension[T]) AsSkeletonProfile

func (self *Extension[T]) AsSkeletonProfile() Instance

type ID

type ID Object.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.

func (ID) Instance

func (id ID) Instance() (Instance, bool)

type Instance

type Instance [1]gdclass.SkeletonProfile

Instance of the class with convieniently typed arguments and results.

var Nil Instance

Nil is a nil/null instance of the class. Equivalent to the zero value.

func New

func New() Instance

func (Instance) AsObject

func (self Instance) AsObject() [1]gd.Object

func (Instance) AsRefCounted

func (self Instance) AsRefCounted() [1]gd.RefCounted

func (Instance) AsResource

func (self Instance) AsResource() Resource.Instance

func (Instance) AsSkeletonProfile

func (self Instance) AsSkeletonProfile() Instance

func (Instance) BoneSize

func (self Instance) BoneSize() int

func (Instance) FindBone

func (self Instance) FindBone(bone_name string) int

Returns the bone index that matches 'bone_name' as its name.

func (Instance) GetBoneName

func (self Instance) GetBoneName(bone_idx int) string

Returns the name of the bone at 'bone_idx' that will be the key name in the BoneMap.

In the retargeting process, the returned bone name is the bone name of the target skeleton.

func (Instance) GetBoneParent

func (self Instance) GetBoneParent(bone_idx int) string

Returns the name of the bone which is the parent to the bone at 'bone_idx'. The result is empty if the bone has no parent.

func (Instance) GetBoneTail

func (self Instance) GetBoneTail(bone_idx int) string

Returns the name of the bone which is the tail of the bone at 'bone_idx'.

func (Instance) GetGroup

func (self Instance) GetGroup(bone_idx int) string

Returns the group of the bone at 'bone_idx'.

func (Instance) GetGroupName

func (self Instance) GetGroupName(group_idx int) string

Returns the name of the group at 'group_idx' that will be the drawing group in the BoneMap editor.

func (Instance) GetHandleOffset

func (self Instance) GetHandleOffset(bone_idx int) Vector2.XY

Returns the offset of the bone at 'bone_idx' that will be the button position in the BoneMap editor.

This is the offset with origin at the top left corner of the square.

func (Instance) GetReferencePose

func (self Instance) GetReferencePose(bone_idx int) Transform3D.BasisOrigin

Returns the reference pose transform for bone 'bone_idx'.

func (Instance) GetTailDirection

func (self Instance) GetTailDirection(bone_idx int) TailDirection

Returns the tail direction of the bone at 'bone_idx'.

func (Instance) GetTexture

func (self Instance) GetTexture(group_idx int) Texture2D.Instance

Returns the texture of the group at 'group_idx' that will be the drawing group background image in the BoneMap editor.

func (Instance) GroupSize

func (self Instance) GroupSize() int

func (Instance) ID

func (self Instance) ID() ID

func (Instance) IsRequired

func (self Instance) IsRequired(bone_idx int) bool

Returns whether the bone at 'bone_idx' is required for retargeting.

This value is used by the bone map editor. If this method returns true, and no bone is assigned, the handle color will be red on the bone map editor.

func (Instance) OnProfileUpdated

func (self Instance) OnProfileUpdated(cb func(), flags ...Signal.Flags)

func (Instance) RootBone

func (self Instance) RootBone() string

func (Instance) ScaleBaseBone

func (self Instance) ScaleBaseBone() string

func (Instance) SetBoneName

func (self Instance) SetBoneName(bone_idx int, bone_name string)

Sets the name of the bone at 'bone_idx' that will be the key name in the BoneMap.

In the retargeting process, the setting bone name is the bone name of the target skeleton.

func (Instance) SetBoneParent

func (self Instance) SetBoneParent(bone_idx int, bone_parent string)

Sets the bone with name 'bone_parent' as the parent of the bone at 'bone_idx'. If an empty string is passed, then the bone has no parent.

func (Instance) SetBoneSize

func (self Instance) SetBoneSize(value int)

func (Instance) SetBoneTail

func (self Instance) SetBoneTail(bone_idx int, bone_tail string)

Sets the bone with name 'bone_tail' as the tail of the bone at 'bone_idx'.

func (Instance) SetGroup

func (self Instance) SetGroup(bone_idx int, group string)

Sets the group of the bone at 'bone_idx'.

func (Instance) SetGroupName

func (self Instance) SetGroupName(group_idx int, group_name string)

Sets the name of the group at 'group_idx' that will be the drawing group in the BoneMap editor.

func (Instance) SetGroupSize

func (self Instance) SetGroupSize(value int)

func (Instance) SetHandleOffset

func (self Instance) SetHandleOffset(bone_idx int, handle_offset Vector2.XY)

Sets the offset of the bone at 'bone_idx' that will be the button position in the BoneMap editor.

This is the offset with origin at the top left corner of the square.

func (*Instance) SetObject

func (self *Instance) SetObject(obj [1]gd.Object) bool

func (Instance) SetReferencePose

func (self Instance) SetReferencePose(bone_idx int, bone_name Transform3D.BasisOrigin)

Sets the reference pose transform for bone 'bone_idx'.

func (Instance) SetRequired

func (self Instance) SetRequired(bone_idx int, required bool)

Sets the required status for bone 'bone_idx' to 'required'.

func (Instance) SetRootBone

func (self Instance) SetRootBone(value string)

func (Instance) SetScaleBaseBone

func (self Instance) SetScaleBaseBone(value string)

func (Instance) SetTailDirection

func (self Instance) SetTailDirection(bone_idx int, tail_direction TailDirection)

Sets the tail direction of the bone at 'bone_idx'.

Note: This only specifies the method of calculation. The actual coordinates required should be stored in an external skeleton, so the calculation itself needs to be done externally.

func (Instance) SetTexture

func (self Instance) SetTexture(group_idx int, texture Texture2D.Instance)

Sets the texture of the group at 'group_idx' that will be the drawing group background image in the BoneMap editor.

func (Instance) Virtual

func (self Instance) Virtual(name string) reflect.Value

type TailDirection

type TailDirection int //gd:SkeletonProfile.TailDirection
const (
	// Direction to the average coordinates of bone children.
	TailDirectionAverageChildren TailDirection = 0
	// Direction to the coordinates of specified bone child.
	TailDirectionSpecificChild TailDirection = 1
	// Direction is not calculated.
	TailDirectionEnd TailDirection = 2
)

Jump to

Keyboard shortcuts

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