this post was submitted on 07 Aug 2024
1 points (100.0% liked)

Godot

5675 readers
1 users here now

Welcome to the programming.dev Godot community!

This is a place where you can discuss about anything relating to the Godot game engine. Feel free to ask questions, post tutorials, show off your godot game, etc.

Make sure to follow the Godot CoC while chatting

We have a matrix room that can be used for chatting with other members of the community here

Links

Other Communities

Rules

We have a four strike system in this community where you get warned the first time you break a rule, then given a week ban, then given a year ban, then a permanent ban. Certain actions may bypass this and go straight to permanent ban if severe enough and done with malicious intent

Wormhole

[email protected]

Credits

founded 1 year ago
MODERATORS
 

I want to instatiate the inspector of a specific type like int and String into my own inspector plugin. It would be incredibly useful to use the premade inspector types as they are just really well made.

The image is not related, I just wanted to put some visual here.

top 4 comments
sorted by: hot top controversial new old
[–] [email protected] 0 points 1 month ago* (last edited 1 month ago)

I dont think I fully understand the question but things should just show as the default type handling in the inspector if you dont override the handling for that type

If you need the individual controls for some reason theres some available like EditorSpinSlider EditorResourcePicker etc

[–] [email protected] 0 points 1 month ago (1 children)

@Smorty Is the @export parameter useful for you?

[–] [email protected] 0 points 1 month ago (1 children)

I use @export extensively in my projects but I have never heard it being refered to as a parameter. What do you mean by this exactly?

[–] [email protected] 0 points 1 month ago

I think what they're trying to say is that you can add a type hint to your exported properties. These type hints affect how the property presents in the inspector. https://docs.godotengine.org/en/stable/tutorials/scripting/gdscript/gdscript_exports.html. For example, @export var my_int: int shows up as an int in the inspector.