July 1, 2021
Play Chess with Captivate !…
Comments
(8)
July 1, 2021
Play Chess with Captivate !…
I'm a former teacher (and headmaster) in french primary schools. Now I work as a freelance on the net as a webmaster. I used to work with Flash for many years, but now I'm starting to discover Captivate and find it amazing !...
Master 64 posts
Followers: 21 people
(8)

Hello Captivaters !…

A few months ago, a friend and I had the idea to play chess… But we didn’t have any board on hand…

Always inspired by Greg’s Game and Idea series, I thought it would have been easy to “build” and “animate” a chess-board with our friend Captivate !…

Preview Project

It’s the first time I try to make a “special” Captivate English version for this eLearning site !… Therefore, please be indulgent in your eventual comments.

 

Greg’s Resources :
https://elearning.adobe.com/2021/05/javascript-idea-series/

https://elearning.adobe.com/2021/05/game-and-puzzle-series/

Even if I’m a little confused… I tried to apply Greg’s code about “the Timer” to use it as the chess-countdown and it was all but easy…
Finally, I used Captivate (delay/decrement action) to achieve the clocks easily !…

Happy Captivating !… And play Chess !…

😉

8 Comments
2021-07-02 22:10:30
2021-07-02 22:10:30

I have finished the chess clock and posted it. Hopefully it shall appear quickly. I think you will like it.

Pic attached.

Attachment

Like
(1)
(3)
>
Greg Stager
's comment
2021-07-03 05:47:05
2021-07-03 05:47:05
>
Greg Stager
's comment

Looks like a real Chess Clock !…

WHAAOUUUUHHHH !…

Can’t wait to see it in action !

Great Job Greg !

Like
()
>
Ludovic Mercier
's comment
2021-07-07 08:29:03
2021-07-07 08:29:03
>
Ludovic Mercier
's comment

Hi Ludovic, here’s the link to Greg’s post on the Chess Clock:

https://elearning.adobe.com/2021/07/chess-clock-playing-with-timers-part-1/

Like
()
>
Ishan Mukherjee
's comment
2021-07-07 12:09:09
2021-07-07 12:09:09
>
Ishan Mukherjee
's comment

Thank you Ishan !

Like
()
2021-07-02 12:52:26
2021-07-02 12:52:26

Nice job!

My timer was a very simple one – no interactions. In your case – you also need a way to stop and restart each player’s clock so that adds a bit more complexity. Perhaps I may make a chess clock of sorts as a project and build in some of that extra functionality.

I can appreciate the amount of work that goes into something like this with so many objects to manage. Kudos!

 

Like
(1)
(3)
>
Greg Stager
's comment
2021-07-02 15:57:08
2021-07-02 15:57:08
>
Greg Stager
's comment

Thanks Greg !…

It’s just a simple Drag and Drop with 32 drag objects and 64 drop targets !…

I tried to use your timer code… My problem was in fact to stop the time and restart it. Everytime I restarted the time, the speed of the countdown increased… But the 2/3 hours I spent to try to implement it were fun and instructive !…

So… I was about to claim for some (your ?) help on the forum when our friend Lilybiri came to me… whispering in my ear “Why do you want to use Javascript ?“… 10 minutes later, the chess clocks were done !…

But… I would be much interested to see how you will manage to resolve the “Chess Clocks Javascript Challenge” !???…

Take care !…

Like
()
>
Ludovic Mercier
's comment
2021-07-02 16:14:26
2021-07-02 16:14:26
>
Ludovic Mercier
's comment

The tricky part about the timer is that when you execute the setTimeout command, it will run to completion in the background. Executing it a second time will essentially fire another instance of it over the top of the first one causing the inside function to fire twice and present as a jerky display.

The key would be to use a clearTimeout to cancel the setTimeout properly.

I find that I learn the most when struggling through finding solutions to the logic and function of a project.

A recent project at work had me researching data trees and using objects within arrays. I found it most helpful and fascinating. I feel I reached a new plateau with that adventure. It is on these new plateaus that one discovers new doors to open that were otherwise unreachable.

That is one reason why I, personally, want to use JavaScript.

Like
(1)
>
Greg Stager
's comment
2021-07-02 16:32:02
2021-07-02 16:32:02
>
Greg Stager
's comment

I’m 100% with you !… Struggling to solve a problem is the best part of the job !… After… it’s no more than some copy/paste actions !…

Even if I didn’t use Javascript for the Clocks, I used Js for the “White or Black” choice (Thanks to you !) and for centering the entry in the TEB (Thanks to TLC Media).

No doubt Javascript is a big ++ within Captivate !…

I’m waiting to see the fruits of your adventure !

Like
()
Add Comment