diff options
author | Campbell Barton <ideasman42@gmail.com> | 2009-06-29 06:25:54 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2009-06-29 06:25:54 +0400 |
commit | c50bbe5ae726edfb265bd54cb7ce0e547e3f4b31 (patch) | |
tree | 2fcb879d619b0794a7632575f64e5825949de4cf /source/gameengine/Ketsji/KX_CDActuator.cpp | |
parent | bb1f24ac443bcc386cf2cc3765609aaf9bf51db1 (diff) |
BGE Py API using python3 c/api calls. include bpy_compat.h to support py2.x
Diffstat (limited to 'source/gameengine/Ketsji/KX_CDActuator.cpp')
-rw-r--r-- | source/gameengine/Ketsji/KX_CDActuator.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/source/gameengine/Ketsji/KX_CDActuator.cpp b/source/gameengine/Ketsji/KX_CDActuator.cpp index 6e01bf0dded..d025dbfa469 100644 --- a/source/gameengine/Ketsji/KX_CDActuator.cpp +++ b/source/gameengine/Ketsji/KX_CDActuator.cpp @@ -249,8 +249,8 @@ KX_PYMETHODDEF_DOC_O(KX_CDActuator, playTrack, "playTrack(trackNumber)\n" "\tPlays the track selected.\n") { - if (PyInt_Check(value)) { - int track = PyInt_AsLong(value); + if (PyLong_Check(value)) { + int track = PyLong_AsSsize_t(value); SND_CDObject::Instance()->SetPlaymode(SND_CD_TRACK); SND_CDObject::Instance()->SetTrack(track); SND_CDObject::Instance()->SetPlaystate(SND_MUST_PLAY); |