BGE Python API
CListValue fixes - Disable changing CValueLists that the BGE uses internally (scene.objects.append(1) would crash when drawing) - val=clist+list would modify clist in place, now return a new value. - clist.append([....]), was working like extend. - clist.append(val) didnt work for most CValue types like KX_GameObjects. Other changes - "isValid" was always returning True. - Set all errors for invalid proxy access to PyExc_SystemError (was using a mix of error types) - Added PyObjectPlus::InvalidateProxy() to manually invalidate, though if python ever gains access again, it will make a new valid proxy. This is so removing an object from a scene can invalidate the object even if its stored elsewhere in a CValueList for eg.
This commit is contained in:
@@ -451,6 +451,8 @@ public:
|
||||
static PyObject *GetProxy_Ext(PyObjectPlus *self, PyTypeObject *tp);
|
||||
static PyObject *NewProxy_Ext(PyObjectPlus *self, PyTypeObject *tp, bool py_owns);
|
||||
|
||||
void InvalidateProxy();
|
||||
|
||||
/**
|
||||
* Makes sure any internal data owned by this class is deep copied.
|
||||
*/
|
||||
|
Reference in New Issue
Block a user