Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

3 Dimensional Chat / Matrix Help Please Part 2

Author
Message
SoulMan
17
Years of Service
User Offline
Joined: 22nd Nov 2002
Location: In a house somewhere on the planet earth
Posted: 1st Feb 2003 02:56
Ok, I need some help with the good ol matrix stuff.
What is good way to get the points of the tiles.
What I am doing is the creation of a matrix editing program.
I want to be able to do is grab a tile and move it into a shape.
For instance if I want to create a hill, I want to high light a bunch of tiles and mold them into a hill.
How in the world can I do something like that.
That would give me a big boost in help.
Thanks.
SoulMan
I am my own and own my am I
Shadow Robert
17
Years of Service
User Offline
Joined: 22nd Sep 2002
Location: Hertfordshire, England
Posted: 1st Feb 2003 04:23
probably through the matrix height command

Anata aru kowagaru no watashi!
SoulMan
17
Years of Service
User Offline
Joined: 22nd Nov 2002
Location: In a house somewhere on the planet earth
Posted: 1st Feb 2003 04:29
That helps, but I need to know how to find the darn values there.
How do I get the actual coordnates of a tile on a matrix?
Thanks.
SoulMan

I am my own and own my am I
SoulMan
17
Years of Service
User Offline
Joined: 22nd Nov 2002
Location: In a house somewhere on the planet earth
Posted: 1st Feb 2003 05:07
Actually, to kinda guess my answer.
Is the TileX and the Tile Z refering to an actual tile or a point.
I am now confused.
Please help me.
SoulMan

I am my own and own my am I
Shadow Robert
17
Years of Service
User Offline
Joined: 22nd Sep 2002
Location: Hertfordshire, England
Posted: 1st Feb 2003 06:03
yup
i think theres 2...
set matrix height [matrix],[tilex],[tiley],[height]
and
return = get matrix height([matrix],[x],[z])

now i think its simple enough to get the positions even without a command but simple doing

MatrixZ / MatrixTileZ = fUnitPerTileZ#
MatrixX / MatrixTileX = fUnitPerTileX#

then all you do is assuming dwTileCount X Y is the Tile your looking for

fTilePosX# = fUnitPerTileX# * dwTileCountX
fTilePosZ# = fUnitPerTileZ# * dwTileCountY
fTilePosY# = get matrix height(dwMatrix, fTilePosX#, fTilePosY#)

probably best to throw most of the information into an array PRE use - so all you need to do is lookup the array

dim ptrTileArray#(TileX,TileZ,3)

the return is 1 = X# 2 = Y# 3 = Z#
simple no?

Anata aru kowagaru no watashi!
SoulMan
17
Years of Service
User Offline
Joined: 22nd Nov 2002
Location: In a house somewhere on the planet earth
Posted: 1st Feb 2003 07:39
Well,
After playing around with the darn thing.
And figuring out I was missing the Update Matrix Command, I think I finally have it licked.
No, don't think about that.

Heh.
Anyway, Vegeta, you have really helped me figure out what I was doing wrong.
Kinda helps when one is thinking straight and having some experiance with units.
See the problem I have is that I didn't realize there was no set point. You have to measure everything by units which is no set size.
Yeah it's fun I guess.
Anyway, I hope to have an actual editor completed soon here.
Thanks.
SoulMan

I am my own and own my am I

Login to post a reply

Server time is: 2020-08-15 12:07:34
Your offset time is: 2020-08-15 12:07:34