-
Notifications
You must be signed in to change notification settings - Fork 287
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Compiling a second time on overwrite ( bedrock ) #2485
Labels
Comments
Suggested changes export_codec.write(export_codec.compile({raw: true}), Project.export_path) ( line 708 of io.js ) write(content, path) {
if (fs.existsSync(path) && this.overwrite) {
this.overwrite(content, path, path => this.afterSave(path))
} else {
Blockbench.writeFile(path, { content: autoStringify(content) }, path => this.afterSave(path));
}
} ( line 128 of codec.js, codec::write() ) var model = content['minecraft:geometry'][0] ( line 1193 of bedrock.js within function overwrite) obj[model_name] = content; ( line 400 of bedrock_old.js ) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Detailed description of your suggestion
This is more a question but either way I want to know why.
(line 708 of io.js)
Calls the compile function and sends it to write when saving below is Codec.write()
Witch if the file already exists sends to this.overwrite and if it's bedrock
( line 1193 of bedrock.js in function .overwrite)
It calls this.compile AGAIN which I should have to say why this shouldn't be the case because this can really slow down performance on super large or complex bedrock models personally I'm trying to make models that already take 10min to compile I don't want another 10 minutes. On the alterative I think we you should call export_codec as raw from the beginning then stringifying it on write
The text was updated successfully, but these errors were encountered: