Hack Forums
[Help] How will you approach this task ?? - Printable Version

+- Hack Forums (https://hackforums.net)
+-- Forum: Tech (https://hackforums.net/forumdisplay.php?fid=444)
+--- Forum: Coding (https://hackforums.net/forumdisplay.php?fid=151)
+---- Forum: Coders Lounge (https://hackforums.net/forumdisplay.php?fid=5)
+---- Thread: [Help] How will you approach this task ?? (/showthread.php?tid=5592658)



How will you approach this task ?? - kakarot007 - Apr 5, 2017

You are making a simple game with four buttons (by default) that turn on and off. At the start, they are all in the β€˜on’ state. The goal is to press them in the right order to turn all buttons off; however, each button is associated with one other button (this is a one-way non-changing association). Whenever a button is pressed, it flips the state of itself and of its associated button. Each can be pressed in either state.

Requirements:
Use CSS to make the interface look decent
Make the button associations random each time
Add a congratulations screen when the user finishes
Make it able to expand to more buttons and/or more associations


thanks !!


* - g4143 - Apr 5, 2017

You'll have to post the association between the buttons or and example of a correct association.


* - foobar123 - Apr 5, 2017

Hi!
i did a quick & dirty jsfiddle for you to show a possible way:
jsfiddle net/h2j9L95p/
As i said its dirty. Things can be done way better and even without jQuery. But this is your job now.

have fun

edit: cmon... can't post links until i spam more posts..


* - Owl - Apr 5, 2017

My suggestion: https://jsfiddle.net/orkatek/qs83dpsk/

This shows the logic but styling and expansion (almost done) is up to yourself.


* - Dialog - Apr 5, 2017

I'd approach this task by getting my ass of Hackforums and starting doing my homework.
If you want some actual help either pay someone to get it done, or post what you've tried and what specific problems you're running into.


* - kakarot007 - Apr 5, 2017

(Apr 5, 2017 07:44 AM)foobar123 Wrote:  Hi!
i did a quick & dirty jsfiddle for you to show a possible way:
jsfiddle net/h2j9L95p/
As i said its dirty. Things can be done way better and even without jQuery. But this is your job now.

have fun

edit: cmon... can't post links until i spam more posts..

Thanks man !! It's nice 🀝


(Apr 5, 2017 04:55 PM)Dialog Wrote:  I'd approach this task by getting my ass of Hackforums and starting doing my homework.
If you want some actual help either pay someone to get it done, or post what you've tried and what specific problems you're running into.

You are right , i got some pointers now . I will post my solution soon and next time i will try myself first !!πŸ˜‰


* - foobar123 - Apr 6, 2017

(Apr 5, 2017 10:09 PM)kakarot007 Wrote:  Thanks man !! It's nice 🀝
You are welcome. Glad i could help