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.

Author
Message
simonuk74
23
Years of Service
User Offline
Joined: 3rd Nov 2002
Location:
Posted: 26th Apr 2003 01:44
I have a matrix, with code to let me select a co-ordinate with in the matrix, with a set camera height.

could anyone help me with the formula to add the camera y position into the equation?

so that when I `zoom` ( camy + / - ) I will still be able to correctly select the co-ordinated

the code for x&z that I have written is below...
( 16 is the size of the matrix tiles )
Shadow Robert
23
Years of Service
User Offline
Joined: 22nd Sep 2002
Location: Hertfordshire, England
Posted: 26th Apr 2003 02:02
i have a pretty simple RTS (Black&White) style Camera Code in my forum, didn't work in DBpro 1.00.0 however i've not tried it since - it should work provided they fixxed the bugs in the rotation code.

click my website to get to my forum

Tsu'va Oni Ni Jyuuko Fiori Sei Tau!
One block follows the suit ... the whole suit of blocks is the path ... what have you found?
simonuk74
23
Years of Service
User Offline
Joined: 3rd Nov 2002
Location:
Posted: 26th Apr 2003 02:25
cheers, I had a look, but I get an error in DBP, but I tried the DBC version, it seemed to do something, ( I placed an object - cube in the code, for reference )
Thanks for the help, but I`m not completely sure its what I`m looking for :-s

heres what I have, arrow keys to move ( hold right ctrl to move fast )

with +/-( number pad ) for zoom, but I cant get it to correctly read the position when I change camy value.

Shadow Robert
23
Years of Service
User Offline
Joined: 22nd Sep 2002
Location: Hertfordshire, England
Posted: 26th Apr 2003 04:05 Edited at: 26th Apr 2003 04:08
whats the error you get in dbpro?
for some reason i keep getting told my types are causing errors all over the shop (i'm not sure why though)

if you want to use the DB version, place down a plane and a cube, you'll notice what it's suppose to do - that zoom is based on the mouse scroll wheel

i forgot to put with that my movement code
which should be



now that should not only be able to move the camera around the scene, but also zoom in/out, orbit a point & be able to move up/down

left mouse button = orbit
right mouse button = move
scroll wheel = zoom
+/- = up/down

oh and Extra# is there for if you need to put on say a Matrix height, you can just add those values to the Extra# and it'll automatically be taken into account - also you could zoom by changing the Rotation Value.



add that at the start to see what is going on when you do something

Tsu'va Oni Ni Jyuuko Fiori Sei Tau!
One block follows the suit ... the whole suit of blocks is the path ... what have you found?
simonuk74
23
Years of Service
User Offline
Joined: 3rd Nov 2002
Location:
Posted: 26th Apr 2003 11:39
Raven, the error I get with your DBP code is :
" Failed to `DoDeclaration::SeperateValueFromArrayString "

but it doesnt giva a line indication to where the error is being produced.

The DBP version I have has not been updated to patch 4, I only got it just before 4 was released, but I read a few posts of problems with 4, so for the time being, I have not installed it yet, ( is it safe too ? lol )

I tried your dBC code again, and added the cube & plain, but it only moves very little when I move the mouse, and when I right click, the plain & cube shoot off into the distance.

maybe this is because I`m running it on DBP, as I havent to DBC installed ?

Simon

Shadow Robert
23
Years of Service
User Offline
Joined: 22nd Sep 2002
Location: Hertfordshire, England
Posted: 26th Apr 2003 18:58
well DBP has a different scale system to DB so you'll have to change the mouse multiplications to comfortable levels

Tsu'va Oni Ni Jyuuko Fiori Sei Tau!
One block follows the suit ... the whole suit of blocks is the path ... what have you found?

Login to post a reply

Server time is: 2026-07-11 22:25:27
Your offset time is: 2026-07-11 22:25:27