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:
authorMitchell Stokes <mogurijin@gmail.com>2012-11-19 00:56:50 +0400
committerMitchell Stokes <mogurijin@gmail.com>2012-11-19 00:56:50 +0400
commiteb1fccd8a54c33a057fa3692eb3dfa1012f4fdfc (patch)
tree3920a51ec9590fb87c0612c6cae9fe88b773da51 /source/blender/blenloader
parent2bed09e7a6a6b32dd485a91a444dcff917115767 (diff)
BGE: The Step Height for a character physics controller is now set to 0.01, which means that Step Height can no longer be 0, which causes issues such as those noted in issue #33221, "KX_CharacterWrapper inconsistencies and error," reported by Angus Hollands (agoose77). I've also added a do_versions() fix that will give objects with 0 Step Height sane defaults. This means old files will now work better with character physics.
Diffstat (limited to 'source/blender/blenloader')
-rw-r--r--source/blender/blenloader/intern/readfile.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/source/blender/blenloader/intern/readfile.c b/source/blender/blenloader/intern/readfile.c
index 03e5a1d2525..89f723cb945 100644
--- a/source/blender/blenloader/intern/readfile.c
+++ b/source/blender/blenloader/intern/readfile.c
@@ -8364,6 +8364,17 @@ static void do_versions(FileData *fd, Library *lib, Main *main)
}
}
+ {
+ Object *ob;
+ for (ob = main->object.first; ob; ob = ob->id.next) {
+ if (ob->step_height == 0.0) {
+ ob->step_height = 0.150;
+ ob->jump_speed = 10.0;
+ ob->fall_speed = 55.0;
+ }
+ }
+ }
+
/* WATCH IT!!!: pointers from libdata have not been converted yet here! */
/* WATCH IT 2!: Userdef struct init has to be in editors/interface/resources.c! */