About Store Forum Documentation Contact



Post Reply 
ELM_WORLD relational data.
Author Message
mizukami Offline
Member

Post: #1
ELM_WORLD relational data.
I think, ELM_WORLD has some (sub) elements.
For example. "Object", "Waypoint" and so on.

i want to know how to get these UIDs.
What method can i use?
04-22-2016 07:53 AM
Find all posts by this user Quote this message in a reply
Esenthel Offline
Administrator

Post: #2
RE: ELM_WORLD relational data.
Hi,

To get a list of all objects, you can use EditorInterface methods:
Code:
Bool worldObjGetDesc(C UID &world_id,   Memp<WorldObjDesc  >  objs, C Memp<UID> &world_obj_ids=null, C RectI *areas=null, Bool only_selected=false, Bool include_removed=false                                   ); // get    objects in world, 'world_id'=id of ELM_WORLD element in the project, 'objs'=array of objects to fill with those from the world, 'world_obj_ids'=if get data only from the objects specified in this container (use null for all objects), 'areas'=get objects only from the specified world areas (use null for all areas), 'only_selected'=if get only objects that are currently selected, 'include_removed'=if include objects that were removed,                                                                          this method is much faster than the one below as it returns only basic data, false on fail
         Bool worldObjGetData(C UID &world_id,   Memp<WorldObjData  >  objs, C Memp<UID> &world_obj_ids=null, C RectI *areas=null, Bool only_selected=false, Bool include_removed=false, Bool include_removed_params=false); // get    objects in world, 'world_id'=id of ELM_WORLD element in the project, 'objs'=array of objects to fill with those from the world, 'world_obj_ids'=if get data only from the objects specified in this container (use null for all objects), 'areas'=get objects only from the specified world areas (use null for all areas), 'only_selected'=if get only objects that are currently selected, 'include_removed'=if include objects that were removed, 'include_removed_params'=if include object parameters that were removed, this method is slower      than the one above as it returns full       data, false on fail

For waypoints, I will add a method for the next release.
04-24-2016 03:45 AM
Find all posts by this user Quote this message in a reply
mizukami Offline
Member

Post: #3
RE: ELM_WORLD relational data.
Thank you.

"worldObjGetDesc();" and "worldObjGetData();" returned false.
What reason can be considered?
UID (that i given) had something error?
04-25-2016 03:49 AM
Find all posts by this user Quote this message in a reply
Esenthel Offline
Administrator

Post: #4
RE: ELM_WORLD relational data.
I've just tested this, and it works fine.

Please check attacked project as a sample.


Attached File(s)
.rar  Test.rar (Size: 591.53 KB / Downloads: 5)
04-25-2016 04:13 AM
Find all posts by this user Quote this message in a reply
Post Reply