18.01.2014, 08:55
(
Последний раз редактировалось Drebin; 18.01.2014 в 12:42.
)
Yes. The offsets are related to the object's axes:
If you shoot the easternmost corner of this object, you will get an offset of around X=20, when you rotate the object around 180 on the Z axis,
the same spot will output X=-20.
This will output Y=-20
So you see where the problem is. In your test you are applying the offsets to the world's axes, and not the object's axes. You'll have to do some calculations which also contain the angles of the objects so you can determine where to place these orange balls precisely.
Код:
CreateObject(6959, 17.18580, -58.10570, 2.61260, 0.00000, 0.00000, 0.00000);
Код:
CreateObject(6959, 17.18580, -58.10570, 2.61260, 0.00000, 0.00000, 180.00000);
Код:
CreateObject(6959, 17.18580, -58.10570, 2.61260, 0.00000, 0.00000, 90.00000);
So you see where the problem is. In your test you are applying the offsets to the world's axes, and not the object's axes. You'll have to do some calculations which also contain the angles of the objects so you can determine where to place these orange balls precisely.