blender/source/gameengine/GameLogic
Kester Maddock 6c4ae1eb54 Patch: [ #2439 ] Makes objects react properly to deformations after a mesh replacement call.
from brian hayward (bthayward)

Detailed description:
 Currently, when an armature deformed object's mesh is replaced by the ReplaceMesh actuator, the new mesh fails to deform to the armature's movement.

 My patch fixes this by properly replacing the deform controller along with the mesh (when appropriete).

 For instance, if one had an animated character using any of the standard deformation techniques (armature, ipo, RVK, or AVK), that character's mesh would currently be prevented from changing mid-game. It could be replaced, but the new mesh would lack the controller which tells it how to deform. If one wanted to dynamiclly add a hat on top of the character's head, it would require storing a secondary prebuilt character (mesh, armature, logic, ect...) on another layer FOR EACH HAT the character could possibly wear, then swapping out the whole character when the hat change was desired. So if you had 4 possible hat/character combos, you would have 4 character meshes, 4 armatures, 4 sets of logic, and so on. I find this lack of flexibility to be unresonable.

 With my patch, one could accomplish the same thing mearly by making one version of the character in the main layer, and adding an invisible object atop the character's head (which is parented to the head bone). Then whenever it becomes desirable, one can replace the invisible object's mesh with the desirable hat's mesh, then make it visible. With my patch, the hat object would then continue to deform to the character's head regardless of which hat was currently being worn.

 *note 1*
 for armature/mesh deformations, the new mesh must have properly assigned vertex groups which match one or more of the bones of the target armature before the replaceMesh call is made. Otherwise the vertices won't react to the armature because they won't know how. (not sure if vertices can be scripted to change groups after the game has started)

 *note 2*
 The added processing time involved with replacing the object's deform controller is negligible.
2005-04-18 11:44:21 +00:00
..
Joystick Big patches: 2005-03-25 10:33:39 +00:00
Makefile Clean up for Makefiles: some of the directories were being printed 2005-04-09 22:40:34 +00:00
SCA_AlwaysEventManager.cpp Switch fixed time system. Logic updates should now happen at 30Hz, physics at 60Hz. (By default, use Python to set.) Some actuators still run at framerate (IPO, Action) for nice smooth animation, and an excuse to buy high end hardware. 2004-10-16 11:41:50 +00:00
SCA_AlwaysEventManager.h Switch fixed time system. Logic updates should now happen at 30Hz, physics at 60Hz. (By default, use Python to set.) Some actuators still run at framerate (IPO, Action) for nice smooth animation, and an excuse to buy high end hardware. 2004-10-16 11:41:50 +00:00
SCA_AlwaysSensor.cpp Changed Python _getattr/_setattr methods to use const STR_String& instead of char* - makes using these methods much nicer. 2004-05-16 13:05:15 +00:00
SCA_AlwaysSensor.h Changed Python _getattr/_setattr methods to use const STR_String& instead of char* - makes using these methods much nicer. 2004-05-16 13:05:15 +00:00
SCA_ANDController.cpp Changed Python _getattr/_setattr methods to use const STR_String& instead of char* - makes using these methods much nicer. 2004-05-16 13:05:15 +00:00
SCA_ANDController.h Changed Python _getattr/_setattr methods to use const STR_String& instead of char* - makes using these methods much nicer. 2004-05-16 13:05:15 +00:00
SCA_EventManager.cpp Added #include <assert.h> so it compiles where assert() was used. 2004-10-16 18:13:00 +00:00
SCA_EventManager.h Added Joystick sensor (from snailrose) 2005-01-23 01:36:29 +00:00
SCA_ExpressionController.cpp Last of the config.h mods... 2002-11-25 15:29:57 +00:00
SCA_ExpressionController.h Changed Python _getattr/_setattr methods to use const STR_String& instead of char* - makes using these methods much nicer. 2004-05-16 13:05:15 +00:00
SCA_IActuator.cpp Switch fixed time system. Logic updates should now happen at 30Hz, physics at 60Hz. (By default, use Python to set.) Some actuators still run at framerate (IPO, Action) for nice smooth animation, and an excuse to buy high end hardware. 2004-10-16 11:41:50 +00:00
SCA_IActuator.h Switch fixed time system. Logic updates should now happen at 30Hz, physics at 60Hz. (By default, use Python to set.) Some actuators still run at framerate (IPO, Action) for nice smooth animation, and an excuse to buy high end hardware. 2004-10-16 11:41:50 +00:00
SCA_IController.cpp Last of the config.h mods... 2002-11-25 15:29:57 +00:00
SCA_IController.h Removed the config.h thing from the .h's in the source dir. 2002-12-27 13:11:01 +00:00
SCA_IInputDevice.cpp The non scons specific stuff for bug tracker bug #2131 2005-01-18 14:17:44 +00:00
SCA_IInputDevice.h Switch fixed time system. Logic updates should now happen at 30Hz, physics at 60Hz. (By default, use Python to set.) Some actuators still run at framerate (IPO, Action) for nice smooth animation, and an excuse to buy high end hardware. 2004-10-16 11:41:50 +00:00
SCA_ILogicBrick.cpp Minor Fixes: 2004-06-26 09:15:41 +00:00
SCA_ILogicBrick.h Miscellaneous Fixes: 2004-06-04 03:00:13 +00:00
SCA_IObject.cpp Port Python updates from Tuhopuu2: 2004-07-17 05:28:23 +00:00
SCA_IObject.h Port Python updates from Tuhopuu2: 2004-07-17 05:28:23 +00:00
SCA_IScene.cpp Last of the config.h mods... 2002-11-25 15:29:57 +00:00
SCA_IScene.h Python updates: 2004-06-07 11:03:12 +00:00
SCA_ISensor.cpp Changed Python _getattr/_setattr methods to use const STR_String& instead of char* - makes using these methods much nicer. 2004-05-16 13:05:15 +00:00
SCA_ISensor.h Changed Python _getattr/_setattr methods to use const STR_String& instead of char* - makes using these methods much nicer. 2004-05-16 13:05:15 +00:00
SCA_JoystickManager.cpp Big patches: 2005-03-25 10:33:39 +00:00
SCA_JoystickManager.h Big patches: 2005-03-25 10:33:39 +00:00
SCA_JoystickSensor.cpp Big patches: 2005-03-25 10:33:39 +00:00
SCA_JoystickSensor.h Added Joystick sensor (from snailrose) 2005-01-23 01:36:29 +00:00
SCA_KeyboardManager.cpp The non scons specific stuff for bug tracker bug #2131 2005-01-18 14:17:44 +00:00
SCA_KeyboardManager.h Switch fixed time system. Logic updates should now happen at 30Hz, physics at 60Hz. (By default, use Python to set.) Some actuators still run at framerate (IPO, Action) for nice smooth animation, and an excuse to buy high end hardware. 2004-10-16 11:41:50 +00:00
SCA_KeyboardSensor.cpp Switch fixed time system. Logic updates should now happen at 30Hz, physics at 60Hz. (By default, use Python to set.) Some actuators still run at framerate (IPO, Action) for nice smooth animation, and an excuse to buy high end hardware. 2004-10-16 11:41:50 +00:00
SCA_KeyboardSensor.h Changed Python _getattr/_setattr methods to use const STR_String& instead of char* - makes using these methods much nicer. 2004-05-16 13:05:15 +00:00
SCA_LogicManager.cpp Patch: [ #2439 ] Makes objects react properly to deformations after a mesh replacement call. 2005-04-18 11:44:21 +00:00
SCA_LogicManager.h Patch: [ #2439 ] Makes objects react properly to deformations after a mesh replacement call. 2005-04-18 11:44:21 +00:00
SCA_MouseManager.cpp Switch fixed time system. Logic updates should now happen at 30Hz, physics at 60Hz. (By default, use Python to set.) Some actuators still run at framerate (IPO, Action) for nice smooth animation, and an excuse to buy high end hardware. 2004-10-16 11:41:50 +00:00
SCA_MouseManager.h Switch fixed time system. Logic updates should now happen at 30Hz, physics at 60Hz. (By default, use Python to set.) Some actuators still run at framerate (IPO, Action) for nice smooth animation, and an excuse to buy high end hardware. 2004-10-16 11:41:50 +00:00
SCA_MouseSensor.cpp Changed Python _getattr/_setattr methods to use const STR_String& instead of char* - makes using these methods much nicer. 2004-05-16 13:05:15 +00:00
SCA_MouseSensor.h Changed Python _getattr/_setattr methods to use const STR_String& instead of char* - makes using these methods much nicer. 2004-05-16 13:05:15 +00:00
SCA_ORController.cpp Changed Python _getattr/_setattr methods to use const STR_String& instead of char* - makes using these methods much nicer. 2004-05-16 13:05:15 +00:00
SCA_ORController.h Changed Python _getattr/_setattr methods to use const STR_String& instead of char* - makes using these methods much nicer. 2004-05-16 13:05:15 +00:00
SCA_PropertyActuator.cpp big warning hunt commit 2005-03-09 19:45:59 +00:00
SCA_PropertyActuator.h Switch fixed time system. Logic updates should now happen at 30Hz, physics at 60Hz. (By default, use Python to set.) Some actuators still run at framerate (IPO, Action) for nice smooth animation, and an excuse to buy high end hardware. 2004-10-16 11:41:50 +00:00
SCA_PropertyEventManager.cpp Switch fixed time system. Logic updates should now happen at 30Hz, physics at 60Hz. (By default, use Python to set.) Some actuators still run at framerate (IPO, Action) for nice smooth animation, and an excuse to buy high end hardware. 2004-10-16 11:41:50 +00:00
SCA_PropertyEventManager.h Switch fixed time system. Logic updates should now happen at 30Hz, physics at 60Hz. (By default, use Python to set.) Some actuators still run at framerate (IPO, Action) for nice smooth animation, and an excuse to buy high end hardware. 2004-10-16 11:41:50 +00:00
SCA_PropertySensor.cpp Changed Python _getattr/_setattr methods to use const STR_String& instead of char* - makes using these methods much nicer. 2004-05-16 13:05:15 +00:00
SCA_PropertySensor.h Changed Python _getattr/_setattr methods to use const STR_String& instead of char* - makes using these methods much nicer. 2004-05-16 13:05:15 +00:00
SCA_PythonController.cpp ome more warnings cleaning 2005-03-14 20:10:22 +00:00
SCA_PythonController.h Changed Python _getattr/_setattr methods to use const STR_String& instead of char* - makes using these methods much nicer. 2004-05-16 13:05:15 +00:00
SCA_RandomActuator.cpp big warning hunt commit 2005-03-09 19:45:59 +00:00
SCA_RandomActuator.h Switch fixed time system. Logic updates should now happen at 30Hz, physics at 60Hz. (By default, use Python to set.) Some actuators still run at framerate (IPO, Action) for nice smooth animation, and an excuse to buy high end hardware. 2004-10-16 11:41:50 +00:00
SCA_RandomEventManager.cpp Switch fixed time system. Logic updates should now happen at 30Hz, physics at 60Hz. (By default, use Python to set.) Some actuators still run at framerate (IPO, Action) for nice smooth animation, and an excuse to buy high end hardware. 2004-10-16 11:41:50 +00:00
SCA_RandomEventManager.h Switch fixed time system. Logic updates should now happen at 30Hz, physics at 60Hz. (By default, use Python to set.) Some actuators still run at framerate (IPO, Action) for nice smooth animation, and an excuse to buy high end hardware. 2004-10-16 11:41:50 +00:00
SCA_RandomNumberGenerator.cpp big warning hunt commit 2005-03-09 19:45:59 +00:00
SCA_RandomNumberGenerator.h Removed the config.h thing from the .h's in the source dir. 2002-12-27 13:11:01 +00:00
SCA_RandomSensor.cpp Changed Python _getattr/_setattr methods to use const STR_String& instead of char* - makes using these methods much nicer. 2004-05-16 13:05:15 +00:00
SCA_RandomSensor.h Changed Python _getattr/_setattr methods to use const STR_String& instead of char* - makes using these methods much nicer. 2004-05-16 13:05:15 +00:00
SCA_TimeEventManager.cpp Switch fixed time system. Logic updates should now happen at 30Hz, physics at 60Hz. (By default, use Python to set.) Some actuators still run at framerate (IPO, Action) for nice smooth animation, and an excuse to buy high end hardware. 2004-10-16 11:41:50 +00:00
SCA_TimeEventManager.h Switch fixed time system. Logic updates should now happen at 30Hz, physics at 60Hz. (By default, use Python to set.) Some actuators still run at framerate (IPO, Action) for nice smooth animation, and an excuse to buy high end hardware. 2004-10-16 11:41:50 +00:00
SConscript Added Joystick sensor (from snailrose) 2005-01-23 01:36:29 +00:00