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:
authorCampbell Barton <ideasman42@gmail.com>2009-08-26 02:51:18 +0400
committerCampbell Barton <ideasman42@gmail.com>2009-08-26 02:51:18 +0400
commit0a23895f95382a8c6d5c36bc8b36802c4474eb2e (patch)
treea9f852821ebe443a9035efb9ffb86059f2f4e7fb /source/gameengine/GameLogic/SCA_PythonController.cpp
parent6a5773d4a8633374a1f54864c077a0cd5fa122ea (diff)
remove all python api functions deprecated in 2.49
Diffstat (limited to 'source/gameengine/GameLogic/SCA_PythonController.cpp')
-rw-r--r--source/gameengine/GameLogic/SCA_PythonController.cpp52
1 files changed, 0 insertions, 52 deletions
diff --git a/source/gameengine/GameLogic/SCA_PythonController.cpp b/source/gameengine/GameLogic/SCA_PythonController.cpp
index 8ece7fb4ae1..ecaa8c508db 100644
--- a/source/gameengine/GameLogic/SCA_PythonController.cpp
+++ b/source/gameengine/GameLogic/SCA_PythonController.cpp
@@ -204,27 +204,7 @@ SCA_IActuator* SCA_PythonController::LinkedActuatorFromPy(PyObject *value)
return false;
}
-/* warning, self is not the SCA_PythonController, its a PyObjectPlus_Proxy */
-PyObject* SCA_PythonController::sPyAddActiveActuator(PyObject* self, PyObject* args)
-{
- ShowDeprecationWarning("GameLogic.addActiveActuator(act, bool)", "controller.activate(act) or controller.deactivate(act)");
-
- PyObject* ob1;
- int activate;
- if (!PyArg_ParseTuple(args, "Oi:addActiveActuator", &ob1,&activate))
- return NULL;
-
- SCA_IActuator* actu = LinkedActuatorFromPy(ob1);
- if(actu==NULL)
- return NULL;
-
- bool boolval = (activate!=0);
- m_sCurrentLogicManager->AddActiveActuator((SCA_IActuator*)actu,boolval);
- Py_RETURN_NONE;
-}
-
const char* SCA_PythonController::sPyGetCurrentController__doc__ = "getCurrentController()";
-const char* SCA_PythonController::sPyAddActiveActuator__doc__= "addActiveActuator(actuator,bool)";
PyTypeObject SCA_PythonController::Type = {
PyVarObject_HEAD_INIT(NULL, 0)
@@ -251,11 +231,6 @@ PyTypeObject SCA_PythonController::Type = {
PyMethodDef SCA_PythonController::Methods[] = {
{"activate", (PyCFunction) SCA_PythonController::sPyActivate, METH_O},
{"deactivate", (PyCFunction) SCA_PythonController::sPyDeActivate, METH_O},
-
- //Deprecated functions ------>
- {"setScript", (PyCFunction) SCA_PythonController::sPySetScript, METH_O},
- {"getScript", (PyCFunction) SCA_PythonController::sPyGetScript, METH_NOARGS},
- //<----- Deprecated
{NULL,NULL} //Sentinel
};
@@ -510,33 +485,6 @@ PyObject* SCA_PythonController::PyDeActivate(PyObject *value)
Py_RETURN_NONE;
}
-/* 1. getScript */
-PyObject* SCA_PythonController::PyGetScript()
-{
- ShowDeprecationWarning("getScript()", "the script property");
- return PyUnicode_FromString(m_scriptText);
-}
-
-/* 2. setScript */
-PyObject* SCA_PythonController::PySetScript(PyObject* value)
-{
- char *scriptArg = _PyUnicode_AsString(value);
-
- ShowDeprecationWarning("setScript()", "the script property");
-
- if (scriptArg==NULL) {
- PyErr_SetString(PyExc_TypeError, "expected a string (script name)");
- return NULL;
- }
-
- /* set scripttext sets m_bModified to true,
- so next time the script is needed, a reparse into byte code is done */
-
- this->SetScriptText(scriptArg);
-
- Py_RETURN_NONE;
-}
-
PyObject* SCA_PythonController::pyattr_get_script(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
//SCA_PythonController* self= static_cast<SCA_PythonController*>(static_cast<SCA_IController*>(static_cast<SCA_ILogicBrick*>(static_cast<CValue*>(static_cast<PyObjectPlus*>(self_v)))));