-
-
Notifications
You must be signed in to change notification settings - Fork 183
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
UPBGE: Add the option to disable component execution on game start #694
Conversation
The new option is at user preferences under system tab. The component execution is disable by default (similar to scripts).
thank you :D
…On Thu, May 24, 2018, 4:38 PM lordloki ***@***.***> wrote:
The new option is at user preferences under system tab. The component
execution is disable by default (similar to scripts).
------------------------------
You can view, comment on, or merge this pull request online at:
#694
Commit Summary
- UPBGE: Add the option to disable component execution on game start
File Changes
- *M* CMakeLists.txt
<https://github.com/UPBGE/blender/pull/694/files#diff-0> (3)
- *M* release/scripts/startup/bl_ui/space_userpref.py
<https://github.com/UPBGE/blender/pull/694/files#diff-1> (1)
- *M* source/blender/blenkernel/BKE_global.h
<https://github.com/UPBGE/blender/pull/694/files#diff-2> (2)
- *M* source/blender/blenkernel/intern/blender.c
<https://github.com/UPBGE/blender/pull/694/files#diff-3> (6)
- *M* source/blender/blenloader/CMakeLists.txt
<https://github.com/UPBGE/blender/pull/694/files#diff-4> (3)
- *M* source/blender/blenloader/intern/versioning_defaults.c
<https://github.com/UPBGE/blender/pull/694/files#diff-5> (6)
- *M* source/blender/makesdna/DNA_userdef_types.h
<https://github.com/UPBGE/blender/pull/694/files#diff-6> (1)
- *M* source/blender/makesrna/intern/rna_userdef.c
<https://github.com/UPBGE/blender/pull/694/files#diff-7> (14)
- *M* source/gameengine/Converter/BL_BlenderDataConversion.cpp
<https://github.com/UPBGE/blender/pull/694/files#diff-8> (20)
Patch Links:
- https://github.com/UPBGE/blender/pull/694.patch
- https://github.com/UPBGE/blender/pull/694.diff
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#694>, or mute the thread
<https://github.com/notifications/unsubscribe-auth/AG25WXRBKy2Pievsjfc-0PINN1yMAekfks5t10RfgaJpZM4UNKDl>
.
|
Nice patch, I accept it. Is there an advantage of using a separate flag for scripts and components ? |
Simply it is for adding more flexibility. |
@@ -4041,6 +4048,13 @@ static void rna_def_userdef_system(BlenderRNA *brna) | |||
"(unsafe with blend files from an untrusted source)"); | |||
RNA_def_property_update(prop, 0, "rna_userdef_script_autoexec_update"); | |||
|
|||
prop = RNA_def_property(srna, "use_components_auto_execute", PROP_BOOLEAN, PROP_NONE); | |||
RNA_def_property_boolean_negative_sdna(prop, NULL, "flag", USER_COMPONENT_AUTOEXEC_DISABLE); | |||
RNA_def_property_ui_text(prop, "Auto Run UPBGE Components", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You could rename "UPBGE Components" to "python components" as in the description.
Now it uses the same DEFINE as the python script auto-exec disable. As blend component executation on loading as component registration or component reloading are disable by default. Warning notifications were added to top-bar and console.
I reworked component auto-exec disable. Now it uses the same DEFINE as the python script auto-exec disable. As blend component execution on loading as component registration or component reloading are disable by default. Warning notifications were added to top-bar and console. |
It uses the same DEFINE as the python script auto-exec disable. Therefore, scripts and components are enable/disable using the same check at user preferences.
As blend component execution on loading as component registration or component reloading are disable by default.
Warning notifications were added to top-bar and console.