You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2025-11-12 13:20:55 +00:00
@@ -1297,6 +1297,21 @@ Error VariantParser::_parse_tag(Token &token, Stream *p_stream, int &line, Strin
|
|||||||
r_tag.name = "";
|
r_tag.name = "";
|
||||||
r_tag.fields.clear();
|
r_tag.fields.clear();
|
||||||
|
|
||||||
|
if (p_stream->is_utf8()) {
|
||||||
|
CharString cs;
|
||||||
|
while (true) {
|
||||||
|
CharType c = p_stream->get_char();
|
||||||
|
if (p_stream->is_eof()) {
|
||||||
|
r_err_str = "Unexpected EOF while parsing simple tag";
|
||||||
|
return ERR_PARSE_ERROR;
|
||||||
|
}
|
||||||
|
if (c == ']') {
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
cs += c;
|
||||||
|
}
|
||||||
|
r_tag.name.parse_utf8(cs.get_data(), cs.length());
|
||||||
|
} else {
|
||||||
while (true) {
|
while (true) {
|
||||||
CharType c = p_stream->get_char();
|
CharType c = p_stream->get_char();
|
||||||
if (p_stream->is_eof()) {
|
if (p_stream->is_eof()) {
|
||||||
@@ -1308,6 +1323,7 @@ Error VariantParser::_parse_tag(Token &token, Stream *p_stream, int &line, Strin
|
|||||||
}
|
}
|
||||||
r_tag.name += String::chr(c);
|
r_tag.name += String::chr(c);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
r_tag.name = r_tag.name.strip_edges();
|
r_tag.name = r_tag.name.strip_edges();
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user