From 0dd65378e7594e8916474613116d8df485870710 Mon Sep 17 00:00:00 2001 From: Juan Linietsky Date: Fri, 29 Jul 2022 15:30:52 +0200 Subject: Add support for command-line user arguments. Implements the standard Unix double dash (--) commandline argument: * Arguments after a double dash (--) are ignored by Godot and stored for the user. * User can access them via `OS.get_cmdline_user_args()` Example: `godot.exe scene_to_run.tscn --fullscreen -- --start-level 2` --- tests/test_main.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'tests') diff --git a/tests/test_main.cpp b/tests/test_main.cpp index 40fe562be1..16654181c6 100644 --- a/tests/test_main.cpp +++ b/tests/test_main.cpp @@ -105,7 +105,7 @@ int test_main(int argc, char *argv[]) { for (int i = 0; i < argc; i++) { args.push_back(String::utf8(argv[i])); } - OS::get_singleton()->set_cmdline("", args); + OS::get_singleton()->set_cmdline("", args, List()); // Run custom test tools. if (test_commands) { -- cgit v1.2.3