0 votes

When I create an internal class in a script, the gdscript intellisense doesn't seem to know about the variables of that class, and typing out the variable leaves that variable written in red text. For example, say I had something like this

 class Something:
    var trialArray = Vector2Array()

func SomeFunction():
    var trialSomething = Something.new()
    trialSomething.trial_array =....

the "trialArray" text attached to trialSomething would be in red, and wouldn't have come up as an intellisense option for trial_something.

Is this functioning correctly (just a result of gdscript not being a statically typed language?), or is my version of Godot not working correctly? If it is functioning correctly, do you have any tips for getting around this/getting used to it? Do you just keep going back to the classes you are using and making sure you get the variable names spelled right?

in Engine by (30 points)

I don't know if this is the expected behavior, but I've noticed the same thing, as well as with e.g. supertype members and functions, so it isn't just you.

Please log in or register to answer this question.

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 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 webmaster@godotengine.org with your username.

Categories