Results 1 to 3 of 3

Thread: Javascript help with 15 piece puzzle please

  1. #1
    Join Date
    Feb 2013

    Javascript help with 15 piece puzzle please


    hi so i am working on a group project for my CS class to build a 15 piece puzzle in javascript. The other group member wrote up some code which i dont understand he is unwilling to comment, so now i have to try and find moveable pieces but i have no idea how to go about it. His shuffling algorithm works perfectly well but seems uncomprehensible to me. Please help. I have posted the JS code on pastebin. Thanks

  2. #2
    Join Date
    Mar 2007
    This is a common training exercise and there are zillions of examples out there, but I suggest you don't look at them.

    You should ignore what someone else did and start from scratch.

    HINT: It can and should be done using just one image. Think CSS background-position.
    Where used, return should be executed unconditionally and always as the last statement in the function.

    That's my signature, it's not part of the damn post!

  3. #3
    Join Date
    Oct 2010
    Versailles, France
    Here is a model of an old puzzle (with 22 selected pieces) !
    Click on the miniature to display the pieces (or double-clic on the background)...
    Good Luck !
    Last edited by 007Julien; 02-19-2013 at 06:48 AM.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
HTML5 Development Center