I am having trouble finding an example of how to use python scripts to drive shape keys, as opposed to using python scripts to move bones which animate the characters mesh through Bone Driven Shape Key animations. In other words - is there a way of changing the shape key values in the BGE during game play that is simper than accessing the bones which are tied (using Drivers) to the shape keys values? Here is an example of Bone Driven Shape Key animations http://vimeo.com/21357304 if it is not clear what I am referring to (go to 15:20 on-wards). Thanks guys!
I don't see a way of accessing the shape key value from within the game engine. A mesh object is copied to a KX_MeshProxy for use in the game engine, which only gives access to the mesh and materials. This would mean that we need to use either drivers or actions to animate shape keys within the game engine.
If you have a driver setup that uses the bone position to control the shape key then you need to move the bone to control the shape key. You can create an action that moves the bone and can easily be played in the game engine.
Without using a driver you can create an action that keyframes the shape key value and then play that action in the game engine. Use the Shape Key Editor instead of the Action Editor (both are subtypes of the Dope Sheet). Shape Key actions show up in the same list as normal actions.
If you don't want to play an action from start to finish then you will want to have a driver that simply sets the shape key value to an object's X location. You can add an empty just for this purpose and move it in small increments to set the shape key value to the value you want at the time you want it there.