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 / Matrix size function/s?

Author
Message
Mr Underhill
23
Years of Service
User Offline
Joined: 23rd Apr 2003
Location: The Forgotten Worlds...
Posted: 29th Aug 2003 09:55
Is it possible for someone to make a function to return the x and z sizes (and tile counts) of an unknown matrix? Just wondering...
Underhill

"You're drawing too much attention to yourself, 'Mr.Underhill'!" - Aragorn (Strider)
spooky
23
Years of Service
User Offline
Joined: 30th Aug 2002
Location: United Kingdom
Posted: 29th Aug 2003 10:30
Hmmmm. Puts thinking hat on.

5 minutes later. Takes thinking hat off. Gives up. Can't be done.

Sorry!

The programmer formerly known as sonic
ReD_eYe
23
Years of Service
User Offline
Joined: 9th Mar 2003
Location: United Kingdom
Posted: 29th Aug 2003 11:59
yup its not possible, inless you make a new makematrix function which stores info like that in an array for use later in the program


diseased
22
Years of Service
User Offline
Joined: 16th Aug 2003
Location:
Posted: 30th Aug 2003 07:41 Edited at: 30th Aug 2003 07:42
..if u the matrix is unknown how did u make it? did it just mysteriously appear? *is confused*

if an unknown matrix causes a glitch in a program which nobody sees, does it piss anyone off?
zzabb
23
Years of Service
User Offline
Joined: 25th Apr 2003
Location: Seattle, USA
Posted: 30th Aug 2003 09:27
(-: (-: (-:
lol
(-: (-: (-:

My advice is free -
unfortunately you get what you pay for (-:
indi
23
Years of Service
User Offline
Joined: 26th Aug 2002
Location: Earth, Brisbane, Australia
Posted: 30th Aug 2003 17:32
place a cube over 0,0,0 move it forwards until the get ground height reaches zero or doesnt return an matrix height.

record this distance taken in both directions, as well as positive and negative space.

http://www.lunarpixel.com
It's already tomorrow in Australia
Codger
23
Years of Service
User Offline
Joined: 23rd Nov 2002
Location:
Posted: 30th Aug 2003 20:26
What is an unknown matrix?

You had to create it store the values?

System
PIII 650 MZ H.P. Pavillion
394 Mem GeForce 4 400MX
IanM
Retired Moderator
23
Years of Service
User Offline
Joined: 11th Sep 2002
Location: In my moon base
Posted: 30th Aug 2003 20:48
That's usually true, but if you are using someone else's code it could be more difficult - especially if the library has been encoded using Hubdules preprocessor.

I'm currently putting together a TPC DLL with a few extra commands that will include the matrix size stuff.

I'll post it later tonight
ReD_eYe
23
Years of Service
User Offline
Joined: 9th Mar 2003
Location: United Kingdom
Posted: 30th Aug 2003 21:20
woohoo! we love you IanM!(in a strictly professional way of course )


IanM
Retired Moderator
23
Years of Service
User Offline
Joined: 11th Sep 2002
Location: In my moon base
Posted: 30th Aug 2003 21:35
And let's keep it that way please
Mr Underhill
23
Years of Service
User Offline
Joined: 23rd Apr 2003
Location: The Forgotten Worlds...
Posted: 31st Aug 2003 01:30
When I said "unknown matrix" I was refering to a matrix loaded from a file (Magic World, MatEdit, etc.).
@IanM: That DLL sounds cool! I'll bet this will help a lot of people out.
Thanks for the help everyone! This is why I love the forums !

"You're drawing too much attention to yourself, 'Mr.Underhill'!" - Aragorn (Strider)
IanM
Retired Moderator
23
Years of Service
User Offline
Joined: 11th Sep 2002
Location: In my moon base
Posted: 31st Aug 2003 05:21
All done. Check it out in the Program Anouncements forum
TDK_Man
22
Years of Service
User Offline
Joined: 24th Aug 2003
Location: Tenerife, Spain
Posted: 31st Aug 2003 16:49
In the case of MatEdit, you have the matrix system variables MatWidth#() and MatHeight#().

For example, the width in pixels of matrix 1 is stored in MatWidth#(1).

I don't know about Magic World, but I would imagine you have something similar.

TDK

MatEdit Pro Info & Progress Reports: http://www.matedit.com

Login to post a reply

Server time is: 2026-07-25 08:12:28
Your offset time is: 2026-07-25 08:12:28