tipforeveryone
Bronze Supporter
|
Get created object pointer
After using this to create object dynamically
Code:
Game.ObjMap<MyClass> myClasObjectList;
ObjectPtr obj = UID(2552926861, 1117558837, 264905372, 2361802078);
Game.World.objCreate(*obj, Matrix(obj->scale3(), startPos));
How can I get the pointer of new created object ?
like this
Code:
MyClass *myClassObj = &myClassObjectList[ myClassObjectList.elms() - 1];
//But this does not work sometime because the last element of Map is not always the latest created MyClass object
|
|
06-27-2020 05:32 AM |
|
Houge
Member
|
RE: Get created object pointer
Code:
Obj* Game::World::objCreateNear(Object &object, C Matrix &matrix, C UID *obj_id=null);
(This post was last modified: 06-27-2020 10:47 PM by Houge.)
|
|
06-27-2020 10:46 PM |
|