#I'm using a TextEdit node to create a commandline in C#. I need help opening different menus though.
1 messages · Page 1 of 1 (latest)
Example C# Code in Console:
``cs
``
uhm
what just happened
I'm using ``
cs while (command != "!") { }
what is this, it's not working in this server

Console.WriteLine("<<<<<<----!!!!!This is an example!!!!!---->>>>>>");
var command = Console.ReadLine();
while (command != "!") {
if (command.ToLower().Contains("help")) {
Console.WriteLine("Available commands: FILE, HELP, RETURN, CLEAR");
command = Console.ReadLine(); // Returns commands ReadLine()
}
else if (command.ToLower().Contains("")) {
var fileMenu = Console.ReadLine();
while (fileMenu != "<") {
Console.WriteLine("Files: PC, PASSWORDS, GOOF");
if (fileMenu.ToLower().Contains("PC")) {
Console.WriteLine("PC/ > ");
fileMenu = Console.ReadLine(); // Returns fileMenus ReadLine()
}
else if (fileMenu = "<") {
fileMenu = "!"; // Exits fileMenus ReadLine()
command = Console.ReadLine(); // Returns ReadLine to command Menu
}
}
}
}
How would I replicate this in Godot TextEdit C#
(notes: i am aware of how to read only last line, i am aware how to make only last line editable, i am aware how to replace and add text on the TextEdit using Text = "";)
using while in godot freezes the engine
i can't redefine command
CAN I redefine command somehow?
hypothetical >>>
string fileMenu;
command = fileMenu;
```???