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 Discussion / I'm a newbie and i need help

Author
Message
EnergeeUK
22
Years of Service
User Offline
Joined: 15th Jan 2003
Location:
Posted: 15th Jan 2003 18:59
I am VERY new to this so please help...

I'm trying to create a menu type sytem. I've got a moving starfield background with 3 static buttons on it, i have done the bit of source that will show me where my mouse is on screen so i now have the top left and bottom right co-ordinates of the button but how do i setup the hotspot so when i click on it, it will load another program.

Please help a newbie

Many Thanks
EnergeeUK
Bogboy2000
22
Years of Service
User Offline
Joined: 8th Nov 2002
Location: United Kingdom
Posted: 15th Jan 2003 19:08
if your a newbie you should realy try the new comers forum in answer to your question

you have a box

box 10,10,50,50
this is the box i which you could also draw it with lines but you will need to replace the values with your own)

then you tell the program that if the mouse is within a certain area and you have clicked the button then do something

if mouseclick() = 1
if mousex() < 50 and mousex() > 10
if mousey() < 50 and mousey() > 10
" your comands go here "
endif
endif
endif

We're all just a figment of somebodys imagination
Daz
22
Years of Service
User Offline
Joined: 26th Dec 2002
Location: United Kingdom
Posted: 15th Jan 2003 19:09
Hmmm....have you done the tutoials? I'm new too, I just look through them and get a basic idea on what to do. Also look through the reference manual, might help. What I'm saying is, don't try anything too soon, so keep that as a later project and try to learn some of the basics first.

PEACE OUT

Login to post a reply

Server time is: 2025-05-09 23:38:03
Your offset time is: 2025-05-09 23:38:03