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:
authorDaniel Stokes <kupomail@gmail.com>2013-07-20 07:15:57 +0400
committerDaniel Stokes <kupomail@gmail.com>2013-07-20 07:15:57 +0400
commitef4d5991945fb0216d492ff9eda1b9f8f22188fd (patch)
tree4b2bd2027559baafd8fa63d8e74733c6c760b0c0 /source/gameengine
parentff165fa986a922346723b2a775d234db13d22afd (diff)
Changing the python error when accessing SCA_JoystickSensor.axisSingle in the wrong mode to an AttributeError instead of a TypeError as this more accurately reflects the problem.
Diffstat (limited to 'source/gameengine')
-rw-r--r--source/gameengine/GameLogic/SCA_JoystickSensor.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/source/gameengine/GameLogic/SCA_JoystickSensor.cpp b/source/gameengine/GameLogic/SCA_JoystickSensor.cpp
index c7e31f75306..3cae3bcf160 100644
--- a/source/gameengine/GameLogic/SCA_JoystickSensor.cpp
+++ b/source/gameengine/GameLogic/SCA_JoystickSensor.cpp
@@ -367,7 +367,7 @@ PyObject *SCA_JoystickSensor::pyattr_get_axis_single(void *self_v, const KX_PYAT
SCA_Joystick *joy = ((SCA_JoystickManager *)self->m_eventmgr)->GetJoystickDevice(self->m_joyindex);
if (self->m_joymode != KX_JOYSENSORMODE_AXIS_SINGLE) {
- PyErr_SetString(PyExc_TypeError, "val = sensor.axisSingle: Joystick Sensor, not 'Single Axis' type");
+ PyErr_SetString(PyExc_AttributeError, "val = sensor.axisSingle: Joystick Sensor, not 'Single Axis' type");
return NULL;
}