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 / Need help this dang button isn't working

Author
Message
Computer Nerd
20
Years of Service
User Offline
Joined: 25th Jan 2005
Location: What do you care?
Posted: 17th Jan 2006 20:17


So why ain't it working?

Hey doods, check out Game Developer's official page at http://gamedeveloper1.tripod.com/. Visit my work in progress thread too. Game Developer, make your own 2d games and have fun doing it.
smallg
Valued Member
19
Years of Service
User Offline
Joined: 8th Dec 2005
Location: steam
Posted: 17th Jan 2006 21:11
think we'll need a bit more then that...

life's one big game
Sven B
20
Years of Service
User Offline
Joined: 5th Jan 2005
Location: Belgium
Posted: 17th Jan 2006 21:44
I too think that there are some parts missing. (Unless it's only a part of a program)

First of all, you'll need a loop.

And, as I understand, you want to use 2 sprites. 1 for the mouse, and one for the button.

To create a mouse sprite, just make a small dot, and place it at the mouse position:

sprite 100, mousex(), mousey(), MouseImage
(This comes in the loop!)

in that same loop, you have to use the code you already had.
if sprite collision(Button, 100) > 0 and mouseclick() > 0 then ButtonPressed = 1

That's all I think...

It's the programmer's life:
Have a problem, solve the problem, and have a new problem to solve.
Computer Nerd
20
Years of Service
User Offline
Joined: 25th Jan 2005
Location: What do you care?
Posted: 17th Jan 2006 23:21
yes I have a sprite image and a loop I forgot to say that I'm not a noob. Now, the idiot dumbass button not working!

Hey doods, check out Game Developer's official page at http://gamedeveloper1.tripod.com/. Visit my work in progress thread too. Game Developer, make your own 2d games and have fun doing it.
Zotoaster
20
Years of Service
User Offline
Joined: 20th Dec 2004
Location: Scotland

Login to post a reply

Server time is: 2025-05-22 23:35:28
Your offset time is: 2025-05-22 23:35:28