diff options
author | Mitchell Stokes <mogurijin@gmail.com> | 2013-01-30 09:55:17 +0400 |
---|---|---|
committer | Mitchell Stokes <mogurijin@gmail.com> | 2013-01-30 09:55:17 +0400 |
commit | 9191b783bb2bc1a2d4be2b2cd215735e68353a56 (patch) | |
tree | 8440c8b155a69580b358ded134bad49e27bb8eba /source/blender/editors | |
parent | 26ee2a1f79c3513ca9eaeb6a3a8d855c37088468 (diff) |
BGE: Some various changes to make moving the character physics type easier:
* Undoing the previous applyMovement() changes for characters. This was causing bugs for the Motion Actuator.
* Creating a Character Motion type for the Motion Actuator with specific controls for characters. This includes moving, rotating and jumping.
* Adding a KX_CharacterWrapper.walkDirection to set the character's direction and speed.
Note, this also resolves the following bugs:
[#33585] "Setting dLoc of motion actuator [0,0,0] via python won't stop object" reported by Manuel Bellersen (urfoex)
[#33503] "Character physics type won´t accept more than one motion anymore" reported by Mr Larodos
Diffstat (limited to 'source/blender/editors')
-rw-r--r-- | source/blender/editors/space_logic/logic_window.c | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/source/blender/editors/space_logic/logic_window.c b/source/blender/editors/space_logic/logic_window.c index f46151fd33a..fa7e888f8d7 100644 --- a/source/blender/editors/space_logic/logic_window.c +++ b/source/blender/editors/space_logic/logic_window.c @@ -1860,6 +1860,25 @@ static void draw_actuator_motion(uiLayout *layout, PointerRNA *ptr) uiItemR(col, ptr, "integral_coefficient", UI_ITEM_R_SLIDER, NULL, ICON_NONE); uiItemR(col, ptr, "derivate_coefficient", UI_ITEM_R_SLIDER, NULL, ICON_NONE); break; + case ACT_OBJECT_CHARACTER: + split = uiLayoutSplit(layout, 0.9, FALSE); + row = uiLayoutRow(split, FALSE); + uiItemR(row, ptr, "offset_location", 0, NULL, ICON_NONE); + row = uiLayoutRow(split, TRUE); + uiItemR(row, ptr, "use_local_location", UI_ITEM_R_TOGGLE, NULL, ICON_NONE); + uiItemR(row, ptr, "use_add_character_location", UI_ITEM_R_TOGGLE, NULL, ICON_NONE); + + split = uiLayoutSplit(layout, 0.9, FALSE); + row = uiLayoutRow(split, FALSE); + uiItemR(row, ptr, "offset_rotation", 0, NULL, ICON_NONE); + uiItemR(split, ptr, "use_local_rotation", UI_ITEM_R_TOGGLE, NULL, ICON_NONE); + + split = uiLayoutSplit(layout, 0.9, FALSE); + row = uiLayoutRow(split, FALSE); + split = uiLayoutSplit(row, 0.7, FALSE); + uiItemL(split, "", ICON_NONE); /*Just use this for some spacing */ + uiItemR(split, ptr, "use_character_jump", UI_ITEM_R_TOGGLE, NULL, ICON_NONE); + break; } } |