Add String::remove_char(s) methods for performance and convenience

This commit is contained in:
A Thousand Ships
2024-05-28 12:55:07 +02:00
parent cae3d722a3
commit 331a43a9d8
35 changed files with 221 additions and 54 deletions

View File

@ -73,7 +73,7 @@ void ShaderGLES3::_add_stage(const char *p_code, StageType p_stage_type) {
} else if (l.begins_with("#CODE")) {
chunk.type = StageTemplate::Chunk::TYPE_CODE;
push_chunk = true;
chunk.code = l.replace_first("#CODE", String()).replace(":", "").strip_edges().to_upper();
chunk.code = l.replace_first("#CODE", String()).remove_char(':').strip_edges().to_upper();
} else {
text += l + "\n";
}