Any way to find the position of the window?

I’d like to be able to poll the window position from within FixedUpdate(). Is there any way to do this?

Since “Window Shake X” and “Window Shake Y” presumably don’t give you information you need (they only provide you with the deltas, not the absolute poosition), you’ll have to go through the OS. This calls for a C/C++ plugin and isn’t the simplest thing in the world to get right (across Mac and PC).

Now if you need this in the browser, the browsers might offer some DOM access to it… check out some DHTML docs.

What’s your use case?

d.

Actually, I’m only looking for deltas, but I need them relative to FixedUpdate() in order to keep things steady.

The project I’m looking to fix is this one: http://torch.cs.dal.ca/~brauer/RomperRoomChairSmash.app.zip
I would like the frame’s movement to be exactly the same as the window movement while still giving the rigidbody a valid velocity for physical interactions.

I have an example project here for working on the problem: http://torch.cs.dal.ca/~brauer/SquareWindow.zip
The objective is to get the square on the right to behave like the one on the left without getting rid of its velocity.