forked from mirror/OpenTTD
(svn r1067) -Add: [Console] Added comment for scripts (everything behind the # is
ignored) (GeniusDex / sign_de)
This commit is contained in:
@@ -286,8 +286,9 @@ DEF_CONSOLE_CMD(ConExec)
|
|||||||
|
|
||||||
fgets(cmd, sizeof(cmd), _script_file);
|
fgets(cmd, sizeof(cmd), _script_file);
|
||||||
while (!feof(_script_file) && _script_running) {
|
while (!feof(_script_file) && _script_running) {
|
||||||
strtok(cmd, "\r\n");
|
strtok(cmd, "\r\n#");
|
||||||
IConsoleCmdExec(cmd);
|
if (strlen(cmd) > 0 && cmd[0] != '#')
|
||||||
|
IConsoleCmdExec(cmd);
|
||||||
fgets(cmd, sizeof(cmd), _script_file);
|
fgets(cmd, sizeof(cmd), _script_file);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user