Skip to content
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

Improve conversion of scenes and resource files to binary on export #12452

Closed
NullNeska opened this issue Oct 28, 2017 · 27 comments
Closed

Improve conversion of scenes and resource files to binary on export #12452

NullNeska opened this issue Oct 28, 2017 · 27 comments

Comments

@NullNeska
Copy link

Apologies if this is the wrong place, but is this feature being implemented in 3.0 as well as exporting resources into the exe on export?

@akien-mga
Copy link
Member

This is already done automatically.

@NullNeska
Copy link
Author

NullNeska commented Oct 28, 2017

exporting my projects PCKs when opened in notepad++ show half binary half raw text, the raw text is my scripts and tscns

sorry i should of been more clear, the resources being converted on export.

@reduz
Copy link
Member

reduz commented Oct 28, 2017 via email

@NullNeska
Copy link
Author

Could this be completed before the first beta release??

@reduz reduz modified the milestones: 3.0, 3.1 Nov 26, 2017
@reduz
Copy link
Member

reduz commented Nov 26, 2017 via email

@NullNeska
Copy link
Author

so 3.0 is going to have easily exploitable game release?

@reduz
Copy link
Member

reduz commented Nov 26, 2017

@NullNeska yes, but I doubt any game started with 3.0 (with enough work put on it so this is a concern), will ship before 3.1 anyway.

@NullNeska
Copy link
Author

I suppose you are right, i guess im not taking into account how much sooner a 3.1 release would be compared to 2.1 to 3.0.

@Calinou
Copy link
Member

Calinou commented Nov 26, 2017

so 3.0 is going to have easily exploitable game release?

Binary scene conversion should not be viewed as a "protection" tool, but rather as a way to speed up scene loading (as binary scenes are faster to parse than text-based scenes; the files also are smaller).

@akien-mga akien-mga changed the title Convert to binary on export [3.0] Convert tscn to binary on export Aug 15, 2018
@williamd1k0
Copy link
Contributor

@akien-mga changed the title from Convert to binary on export [3.0] to Convert tscn to binary on export on Aug 15

I think this should be "Convert scenes and resource files to binary on export" to cover #6709 as well.

@reduz
Copy link
Member

reduz commented Oct 30, 2018

Actually this is implemented already but disabled by default because it was buggy, wonder if anyone wants to give it a try (its on the project settings somewhere).

@williamd1k0
Copy link
Contributor

Indeed, there is a project setting in editor section:

[editor]
convert_text_resources_to_binary_on_export=true

In this case, if I enable this option, will it work with bugs or it does nothing?

@reduz
Copy link
Member

reduz commented Oct 30, 2018

It will work with (maybe) bugs

@williamd1k0
Copy link
Contributor

I see, in this case the issue title should be "Improve conversion of scenes and resource files to binary on export" or something like that.

@vnen vnen changed the title Convert tscn to binary on export Improve conversion of scenes and resource files to binary on export Oct 31, 2018
@aarongerber
Copy link

Looking forward to this... still on track for 3.1?

@akien-mga
Copy link
Member

We ran out of time to implement new features for 3.1, so it will have to wait for 3.2. If it's implemented during 3.2 development, it might still be cherry-picked to a 3.1.x release though.

But this issue is pretty vague, and since the feature apparently exists already (albeit opt-in), the most useful would be to have users testing it and report bugs if they experience any.

@akien-mga akien-mga modified the milestones: 3.1, 3.2 Dec 16, 2018
@girng
Copy link

girng commented Jan 2, 2019

@williamd1k0 i tested the convert_text_resources_to_binary_on_export on 9ba6849, doesn't seem like it's working yet. i checked .pck with vscode and could see raw gds in there

@williamd1k0
Copy link
Contributor

@girng I think this is not related to gdscript, only .tres and .tscn

@girng
Copy link

girng commented Jan 6, 2019

@williamd1k0 yep, my bad. edited prev post

@TokisanGames
Copy link
Contributor

It seems that this ancient issue is fixed by these PRs. Hopefully they will continue to be pushed along.
4.0 #33228, #51098
3.x #51096

@fire
Copy link
Member

fire commented Nov 25, 2021

I wasn't able to use automatic export to scn binary feature in godot 4 because it was buggy. Anyone want to look into it?

@Anutrix
Copy link
Contributor

Anutrix commented Oct 7, 2022

Isn't this fixed by #65135?
The property(now editor/export/convert_text_resources_to_binary) seems to be enabled by default too.

@fire
Copy link
Member

fire commented Oct 8, 2022

I am not sure, I still have the patch set in my branch. Can look.

@Calinou
Copy link
Member

Calinou commented Oct 30, 2023

This was implemented by #65135, closing.

@Calinou Calinou closed this as completed Oct 30, 2023
@Calinou Calinou added this to the 4.0 milestone Oct 30, 2023
@alexzheng
Copy link

is it still buggy and can not use in 3.5?

@Calinou
Copy link
Member

Calinou commented Aug 25, 2024

is it still buggy and can not use in 3.5?

4.x has working text-to-binary resource conversion, but I guess it's still broken in 3.x. You could open a dedicated issue to track this, but it may not be fixed soon as most contributors are focusing on 4.x.

However, if all you care about is scripts, they are already compiled to bytecode in 3.x (just like in 4.x now).

@alexzheng
Copy link

in 3.5, there is already an option in project setting -> Editor -> editor/convert_text_resources_to_binary_on_export, the default value is false. I turned this on and export to iOS and run without any problems.
It is said buggy in many year ago and I can not found any progress for 3.x on t this issue, so I just wonder if this option can be safely turned on or it will lead to some problems that I have not noticed yet?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests