This site is currently in read-only mode during migration to a new platform.
You cannot post questions, answers or comments, as they would be lost during the migration otherwise.
0 votes

I am creating a 3d pose bone plugin .
how to chang skelenton bone pose by using plugin
and see it in editor
Do I really need to create a main scene plugin to change the other scene's node's property
here is my work
extends EditorPlugin

var slide=preload("res://addons/bone/Panel.tscn").instance()
func entertree():

func exittree():

this is in a tscn , (root node )
func onHSlidervaluechanged(value):

this is in my game scene
func onPanelXinhaorotate():
I use print here try to print things .but It doesn't print

I tried to use AutoLoad function and global Variable to do this
But the editor says invalid call .
so can any one give a help?
I tried use a similar plugin in assetlib,but it doesn't work .
So I want to create my own plugin .
godot 3.2 stable

in Engine by (14 points)

Just saying, but someone is working on a built-in way to edit bone poses in this pull request. It might be merged in Godot 4.0.

Could you format the question by indenting the code a few spaces? Sorry, but its hard to read. Thank you.

1 Answer

0 votes

Hello. I'm guessing at your question so please bear with me.

First, you can use export var my_var setget my_var_set_func my_var_get_func to make a property that can be set in the property editor and then call items to update your display. I believe you can do this without making it a tool. It seems unclear if the autoload variables will be available to tools.

Second, I constantly run into ordering problems among the nodes when setting up signals with connect. I often do this trick:

 var Skeleton
 # called when this scene is loaded
 def _ready():

 # called when all scenes are loaded
 def _started():
      Skeleton = my_global_vars.Skeleton
      # connect to signals only after everything is initialized
      Skeleton.connect("broken_bone", self, "on_broken_bone")
by (335 points)
Welcome to Godot Engine Q&A, where you can ask questions and receive answers from other members of the community.

Please make sure to read Frequently asked questions and How to use this Q&A? before posting your first questions.
Social login is currently unavailable. If you've previously logged in with a Facebook or GitHub account, use the I forgot my password link in the login box to set a password for your account. If you still can't access your account, send an email to [email protected] with your username.