summaryrefslogtreecommitdiff
path: root/core/io/pck_packer.cpp
diff options
context:
space:
mode:
authorHugo Locurcio <hugo.locurcio@hugo.pro>2022-02-25 02:32:20 +0100
committerHugo Locurcio <hugo.locurcio@hugo.pro>2022-02-25 02:42:58 +0100
commit8e57e5dc6a22d3e114816be3806c7499824003df (patch)
tree52225ef253ad58f80da2cc3b52ce9bc7375a53d0 /core/io/pck_packer.cpp
parent80baa1386a5a19ed8ea50082617d2ae9112678fc (diff)
Print every file exported with `PCKPacker.flush()`s verbose parameter
Previously, only one line per 100 files was printed. This also refactors the print statement to use Godot methods and make it more informative overall.
Diffstat (limited to 'core/io/pck_packer.cpp')
-rw-r--r--core/io/pck_packer.cpp5
1 files changed, 1 insertions, 4 deletions
diff --git a/core/io/pck_packer.cpp b/core/io/pck_packer.cpp
index 272ace3438..b3bf0cff2d 100644
--- a/core/io/pck_packer.cpp
+++ b/core/io/pck_packer.cpp
@@ -257,10 +257,7 @@ Error PCKPacker::flush(bool p_verbose) {
count += 1;
const int file_num = files.size();
if (p_verbose && (file_num > 0)) {
- if (count % 100 == 0) {
- printf("%i/%i (%.2f)\r", count, file_num, float(count) / file_num * 100);
- fflush(stdout);
- }
+ print_line(vformat("[%d/%d - %d%%] PCKPacker flush: %s -> %s", count, file_num, float(count) / file_num * 100, files[i].src_path, files[i].path));
}
}