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.

Code Snippets / Simple Menu with a Highlight on the active option (DBP)

Author
Message
Codelike
18
Years of Service
User Offline
Joined: 13th Dec 2005
Location: DBP - Scouseland
Posted: 18th Jan 2006 18:27
Useful for n00bs to get to grips with the idea. This is just the code to highlight options in a simple menu. The menu's been centered & the input slowed down. n.b. The options don't follow through to any links.

Any (non-mouse/joystick) improvements?



I have an XP3000+, 1.5gb DDR333, a 6600GT and I'm programming 3k text-based exe's?!
Codelike
18
Years of Service
User Offline
Joined: 13th Dec 2005
Location: DBP - Scouseland
Posted: 19th Jan 2006 18:36 Edited at: 19th Jan 2006 18:46
The same code but with an action linked from each option...



I have an XP3000+, 1.5gb DDR333, a 6600GT and I'm programming 3k text-based exe's?!
Big Man
19
Years of Service
User Offline
Joined: 4th Feb 2005
Location: BEHIND YOU!!!! (but I live in England)
Posted: 19th Jan 2006 22:14
you can do just the same like this.


this is it without the action linked with the options.

Our aim is to keep the loo's clean, your aim can help.
Codelike
18
Years of Service
User Offline
Joined: 13th Dec 2005
Location: DBP - Scouseland
Posted: 20th Jan 2006 01:41 Edited at: 31st Jan 2006 00:04
The 'hold' function is definitely an improvement on my code. That's an excellent addition! Is this the code for it?



edit:
Yes it is. I've chosen to specify the variable at the start of my code, as well, though, like so:



I've learned that not doing this kind of thing (in JS, if I recall) could cause a bug to pop out later. i.e It's best to fix the variable at the beginning & 'vary' it later on in the code, otherwise it's not fully defined from the start.

I have an XP3000+, 1.5gb DDR333, a 6600GT and I'm programming 3k text-based exe's?!

Login to post a reply

Server time is: 2024-11-23 07:45:39
Your offset time is: 2024-11-23 07:45:39