MannyGT Posted March 16 Posted March 16 Hello to all. I have a question about world space terrain and xEdit script: By giving X and Y values position, it is possible to know the Z value of terrain at that position? Please see the attachment for more details. Thank you!
z929669 Posted March 16 Posted March 16 On 3/16/2025 at 3:23 PM, MannyGT said: Hello to all. I have a question about world space terrain and xEdit script: By giving X and Y values position, it is possible to know the Z value of terrain at that position? Please see the attachment for more details. Thank you! Expand x, y, and z are independent, so you cannot know any of them given the other two. You should be able to find their values in xEdit, given you have the cell coordinates.
DoubleYou Posted March 18 Posted March 18 I suppose it should be possible to determine the landscape height z at position x and y via an advanced xEdit script. I would expect you would use the position to determine the cell, and find the landscape record attached to the cell. There typically is a default land height found in the worldspace record, and the landscape record has in the Vertex Height Map an offset value for the cell. Using the default land height and the offset may get you close enough to the value you want. If you want a closer value, from there it seems to divide into 32 rows and 32 columns, so it would seem there are 1024 vertices in each 4096 unit cell. You would need to do some math to locate the correct row and column to read to get the offset at that position.
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now