Cancel
Showing results for 
Search instead for 
Did you mean: 

Different Z-positions of objects in same plane

Solution Partner Genius Solution Partner Genius
Solution Partner Genius

Hi,

 

In my model the Z-position of objects is important for a certain statistic that I need. I found out (the hard way) that sometimes the workers in my model do not have the same Z-position (_3D.Position[3]) as other objects. 

 

One example is in the attached image. My model has two floors, one on Z=0 (floor 1) and one on Z=20 (floor 2). The worker can go between the different floors.

 

The marked left object is a frame which is floor 1 and Z=0, which is correct. The worker is on the same floor but is apparently on Z=-20. I assume the worker have been on floor 2 and gone back to floor 1, but I believed it would be on Z=0 and not Z=-20?

 

Do I not understand how this position attribute works, or is this a bug? And does it exist any other way to know on which floor the worker is?

3 REPLIES

Re: Different Z-positions of objects in same plane

Solution Partner Genius Solution Partner Genius
Solution Partner Genius

Forgot to add the image...

Re: Different Z-positions of objects in same plane

Siemens Phenom Siemens Phenom
Siemens Phenom

 

I think I've met that situation before...

I guess the problem is that human location is displayed relatively to Workplace and not absolute CS.

For example:

  • If target Workplace is on the second floor, and Worker starts to walk from the first floor, it's z-coordinate will be "-5m" while he is walking on the first floor. 
  • If target Workplace is on the same level, z-coordinate will be "0".

 

You can try to use the following:

print root._3D.getPositionOfObject(.Resources.Worker:1)

That will print worker position in relation to root origin.

Note that it's available starting from version 13.2.

 

 

 

 

 

Regards, Vladimir.

Re: Different Z-positions of objects in same plane

Solution Partner Genius Solution Partner Genius
Solution Partner Genius

Yes, after some further investigation it is exactly as you said. There is also the attribute Coordinate3D which I don't completely understand how it works, since it differs from _3D.Position (sometimes) on the worker. 

 

Anyways, _3D.getPositionOfObject was exactly what I needed! This is what I believed _3D.Position would return, so this works perfectly with the code I already have. Thanks for the help!