Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTon Roosendaal <ton@blender.org>2004-04-22 17:08:49 +0400
committerTon Roosendaal <ton@blender.org>2004-04-22 17:08:49 +0400
commitefc389fe4ff16161c42aecf42f7014508250caae (patch)
tree5c1eeb495d2d32122aeabd291027c1ec70fbf840 /source/blender/src/buttons_logic.c
parentb37e9eafeb5dac9ac467940c01c1a9383677ecc7 (diff)
In beginning of buttons for logic editor was weird code checking physics model.
It even has old enji buttons still! Anyhoo, if no World was active it returned.. that could be coded friendlier.
Diffstat (limited to 'source/blender/src/buttons_logic.c')
-rw-r--r--source/blender/src/buttons_logic.c13
1 files changed, 7 insertions, 6 deletions
diff --git a/source/blender/src/buttons_logic.c b/source/blender/src/buttons_logic.c
index fba06a265df..8c1107dc993 100644
--- a/source/blender/src/buttons_logic.c
+++ b/source/blender/src/buttons_logic.c
@@ -2410,7 +2410,6 @@ void logic_buts(void)
int butreturn = 0;
wrld= G.scene->world;
- if(wrld==0) return;
ob= OBACT;
@@ -2422,11 +2421,13 @@ void logic_buts(void)
uiBlockSetCol(block, TH_BUT_SETTING2);
- if (wrld->physicsEngine == 1)
- buttons_enji(block, ob);
- if ( (wrld->physicsEngine == 4) || (wrld->physicsEngine == 2) )
- buttons_ketsji(block, ob);
-
+ if(wrld) {
+ if (wrld->physicsEngine == 1) buttons_enji(block, ob);
+ if ( (wrld->physicsEngine == 4) || (wrld->physicsEngine == 2) )
+ buttons_ketsji(block, ob);
+ }
+ else buttons_ketsji(block, ob);
+
uiBlockSetCol(block, TH_AUTO);
uiDefBut(block, BUT, B_ADD_PROP, "ADD property", 10, 90, 340, 24,
NULL, 0.0, 100.0, 100, 0,