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.

Newcomers DBPro Corner / Can any plz make me a button fuction?

Author
Message
Hayer
19
Years of Service
User Offline
Joined: 4th Nov 2005
Location: Norway
Posted: 14th Sep 2006 22:43
Hi!
I like to learn this way:
Some1 makes some code give it to be and then descripe it and how it works...

Right now i want some1 to write a button function thats like
when i pull my mouse over the text it becomes red...

Right now im using this:


But when i click like Main (Server) the text dosent get white again. It just stay red....
HELP!

Mess with the bests, die like the restes!
Alanna
18
Years of Service
User Offline
Joined: 4th Sep 2006
Location: Somewhere
Posted: 15th Sep 2006 01:23
correct me if I'm wrong... But I think you need to insert the command "ink rgb(255,255,255),0" after your cls command under the Main_Server label. Like this:


Otherwise the colour the sceen is going to write with stays red.

F: Style or not, he's as treacherous as a snake. Me:I wish I had something to crush him with. F: He'll give you plenty to crush him with. A: By the time he does, he'll probably be invinceable.
Zotoaster
19
Years of Service
User Offline
Joined: 20th Dec 2004
Location: Scotland
Posted: 15th Sep 2006 21:30
You need to put the function call inside a loop.

Conjured Entertainment
AGK Developer
19
Years of Service
User Offline
Joined: 12th Sep 2005
Location: Nirvana
Posted: 16th Sep 2006 00:28 Edited at: 16th Sep 2006 00:59
I am just learning too, but here's how I would edit your code.





If you want the color to go back to white after they click it then assign it again.
Here I went back to white for the server, and changed to green for the client.

I also noticed your nested if statements in the funtion, and edited them as well.
They seemed redundant in one spot.
The pressed=0 in the else of the if pressed=1 condition seemed unnecessary too.
If its not =1 then its =0 already.

I'm a noob to DBPro too, so this probably is not the best solution.


Don't forget to visit Conjured Entertainment

Login to post a reply

Server time is: 2024-11-27 07:49:28
Your offset time is: 2024-11-27 07:49:28