mirror of
https://github.com/git-learning-game/oh-my-git.git
synced 2024-11-03 19:04:40 +01:00
f3c311be58
This should make it easier for new people to contribute.
17 lines
334 B
GDScript
17 lines
334 B
GDScript
extends Node2D
|
|
|
|
func _ready():
|
|
pass
|
|
|
|
|
|
|
|
func send_command(new_text):
|
|
var parts = new_text.split(" ")
|
|
var cmd = parts[0]
|
|
var args = parts
|
|
args.remove(0)
|
|
var output = []
|
|
OS.execute(cmd, args, true, output, true)
|
|
$Input.text = ""
|
|
$Output.text = $Output.text + "$ " + new_text + "\n" + output[0]
|
|
$Output.scroll_vertical = 999999
|