The when you scale an object, the vectorDir and vectorUp commands don't return a unit vector anymore, and instead return a vector scaled by the getObjectScale value.
modelToWorld, vectorModelToWorld, and other commands are affected too
Description
Description
Details
Details
- Severity
- Minor
- Resolution
- Not A Bug
- Reproducibility
- Always
- Operating System
- Windows 7
- Category
- Scripting
Steps To Reproduce
You can test the command on some terrain objects. For example, on Stratis:
- Use this code to teleport the player to the desired location:
player setPosASL [2253.21,5686.22,6.02753]
Or alternatively, move to grid 022056.
- Look at the "tunnel" object shown below:
- Execute this command:
vectorUp cursorObject
- You'll see that the result is:
[0,0,2.31199]
which is not a unit vector.
It should be:
[0,0,1]
Event Timeline
Comment Actions
repro with example return value and expected return value please.
if you mean a terrain object then please provide coordinates, or optimally a setPos script