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.

DarkBASIC Professional Discussion / Tile texture finding

Author
Message
ReD_eYe
23
Years of Service
User Offline
Joined: 9th Mar 2003
Location: United Kingdom
Posted: 19th Jul 2003 14:57
Does any one know a way of finding the texture tile number of a specified grid square on a matrix???

For instance after using prepare matrix texture each section of the image that it cuts up is given a mumber, so if you cut up an image into 2x2 the tiles would be numbered 1-4. What i would like to know is, after texturing my matrix, can i find out which tile texture number is on each grid square???
Any help is appreciated.
Thanks
You know whats weird???
Donald duck never wore pants, yet everything time he got out of the shower he put a towel around his waist...
Whats with that???
Eoin
23
Years of Service
User Offline
Joined: 3rd Sep 2002
Location: France
Posted: 19th Jul 2003 15:25
I am looking 4 it too and gave up, the only way i can see is an array
Fallout
23
Years of Service
User Offline
Joined: 1st Sep 2002
Location: Basingstoke, England
Posted: 19th Jul 2003 15:28
Yep, you have to store it yourself. Not exactly convenient, but not exactly hard.

Machine: P4 2200, 1GB RAM, GeForce4 64MB, Audigy Platinum
http://www.breakbeat-terrorism.co.uk
(It's not all about the coding)
ReD_eYe
23
Years of Service
User Offline
Joined: 9th Mar 2003
Location: United Kingdom
Posted: 19th Jul 2003 15:41
hmmmm i thought i might have to do that, i'm assuming i could use a 3-dimensional array like
texture(x,y,tilenum)
right??

You know whats weird???
Donald duck never wore pants, yet everything time he got out of the shower he put a towel around his waist...
Whats with that???
Fallout
23
Years of Service
User Offline
Joined: 1st Sep 2002
Location: Basingstoke, England
Posted: 19th Jul 2003 15:55
Only need a 2D one. TileTexture(x,z) = tilenum. So x,z is the tile position on the array, and the value stored is the tile number.

Machine: P4 2200, 1GB RAM, GeForce4 64MB, Audigy Platinum
http://www.breakbeat-terrorism.co.uk
(It's not all about the coding)
ReD_eYe
23
Years of Service
User Offline
Joined: 9th Mar 2003
Location: United Kingdom
Posted: 19th Jul 2003 16:09
ok cool thanks!

You know whats weird???
Donald duck never wore pants, yet everything time he got out of the shower he put a towel around his waist...
Whats with that???
kevinthekangaroo
23
Years of Service
User Offline
Joined: 4th Jun 2003
Location:
Posted: 19th Jul 2003 17:42
Yeh, I made a matrix editor using that.

ReD_eYe
23
Years of Service
User Offline
Joined: 9th Mar 2003
Location: United Kingdom
Posted: 19th Jul 2003 17:45
yay! got it working nice!
one more thing does anyone know how magic world blends 2 textures together to get a seamless transition between the two ie from grass to sand?

You know whats weird???
Donald duck never wore pants, yet everything time he got out of the shower he put a towel around his waist...
Whats with that???
ReD_eYe
23
Years of Service
User Offline
Joined: 9th Mar 2003
Location: United Kingdom
Posted: 20th Jul 2003 10:59
*bump*

You know whats weird???
Donald duck never wore pants, yet everything time he got out of the shower he put a towel around his waist...
Whats with that???
Fallout
23
Years of Service
User Offline
Joined: 1st Sep 2002
Location: Basingstoke, England
Posted: 20th Jul 2003 13:48
No idea. I get seemless textures by editting them in photopaint before I use them. You need a lot of textures to cover all possible angles of merging between titles, but it has to be done.

Machine: P4 2200, 1GB RAM, GeForce4 64MB, Audigy Platinum
http://www.breakbeat-terrorism.co.uk
(It's not all about the coding)
Eric T
23
Years of Service
User Offline
Joined: 7th Apr 2003
Location: My location is where I am at this time.
Posted: 20th Jul 2003 14:11
all possible angles... 360x360=129600 thats how many textures you'd need to cover just full angles. i'm not even going half angles. so i don't think its been done

Opinions are like a$$holes, Everybody has one.
ReD_eYe
23
Years of Service
User Offline
Joined: 9th Mar 2003
Location: United Kingdom
Posted: 20th Jul 2003 14:26
apparently magic world does it automatically with textures on its matrices?

You know whats weird???
Donald duck never wore pants, yet everything time he got out of the shower he put a towel around his waist...
Whats with that???
Dreamora
23
Years of Service
User Offline
Joined: 20th Sep 2002
Location: Switzerland
Posted: 20th Jul 2003 18:29
for me it seems like MW is just oversampling the choosen one with the texture next to it and replace it with this new one.

Login to post a reply

Server time is: 2026-07-21 20:53:28
Your offset time is: 2026-07-21 20:53:28