0 votes

I am at the moment trying to build an in-game console for my user to enter commands and interact with different objects in the game. The console I am developing will be able to compute commands that the user inputs into the command box, and from that will manipulate the character in my scene to collect different items.

I want to make the gameplay as easy as possible for the user to interact with, in terms of using the in-game console, each according to their ability. Whilst some will be familiar with certain commands, others will be less so, and will therefore need some kind of hint or reference as to what they are imputing.

Would be very much appreciated if someone could give me some code, or a method to implement this functionality as a feature, or a snippet of code.

Thank you.

Godot version 3.4
in Engine by (72 points)

1 Answer

0 votes

You could use a RegEx or something like if string.startsWith to try and detect what the user is trying to type something and then have a Label Node that goes to whatever position that is kind of gray or something and then if the user pressed like tab or whatever you want the keybind to be it appends that to the console.

by (234 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.