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.

Dark GDK / mouse wheel

Author
Message
theplake
16
Years of Service
User Offline
Joined: 30th Nov 2007
Location:
Posted: 12th May 2008 17:20
Hi
I search a command for mouse wheel.I want move camera with mouse wheel.
The Kurgan
16
Years of Service
User Offline
Joined: 8th May 2008
Location: At the Beginning
Posted: 12th May 2008 17:24
use "dbMouseMoveZ()"

It returns an amount proporitional to the amount the wheel is scrolled, where positive motion is scrolling away from user, and negative motion is scrolling towards user.
I'm not sure what the number returned actually is, I generally just say to zoom in if dbMouseMoveZ()>0, zoom out if dbMouseMoveZ()<0.

"It's better to burn out, than to fade away!" -- The Kurgan
tobi453
19
Years of Service
User Offline
Joined: 28th Apr 2005
Location:
Posted: 12th May 2008 17:59
Try dbMouseMoveZ()

FINAL VERSION RELEASED!!!!
Core2uu
16
Years of Service
User Offline
Joined: 15th Mar 2008
Location: Saskatoon, SK, Canada
Posted: 13th May 2008 02:24
The code is there for you in the Game Level tutorial included with DGDK...

~~It's not who you are underneath, but what you do that defines you.~~
jason p sage
17
Years of Service
User Offline
Joined: 10th Jun 2007
Location: Ellington, CT USA
Posted: 13th May 2008 18:20
there's a game level tutorial in DarkGDK? Where have I been? Oh... coding that's right LOL...

You need to dbPRint some numbers from the mouse wheel to get it right.... I found it varies dramtically with regards to people "spinning it" versus the normal slow reading a webpage kinda mouse wheel movement. Sounds simple enough.. but takes a while to get a "reasonable" "feel" if you ask me...

Same holds true for all the linear inputs though... mouse x,y,z, joysticks, paddles if we had them still, even that virtual hand glove.. when I saw the price I was like NO THANKX! I do want to get a new force feedback joystick.. but I'm digressing again... sorry...

Login to post a reply

Server time is: 2024-09-29 19:16:23
Your offset time is: 2024-09-29 19:16:23