Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Free Learning
Arrow right icon
Game Time 2024 - Build a Game with Random Ordering using JavaScript
Game Time 2024 - Build a Game with Random Ordering using JavaScript

Game Time 2024 - Build a Game with Random Ordering using JavaScript: Build an Interactive JavaScript Card Game with Shuffle, Flip, and Match

Arrow left icon
Profile Icon SkillZone
Arrow right icon
€78.99
Video Nov 2024 4hrs 4mins 1st Edition
Video
€78.99
Subscription
Free Trial
Renews at €18.99p/m
Arrow left icon
Profile Icon SkillZone
Arrow right icon
€78.99
Video Nov 2024 4hrs 4mins 1st Edition
Video
€78.99
Subscription
Free Trial
Renews at €18.99p/m
Video
€78.99
Subscription
Free Trial
Renews at €18.99p/m

What do you get with a video?

Product feature icon Download this video in MP4 format
Product feature icon Access this title in our online reader with advanced features
Product feature icon DRM FREE - Read whenever, wherever and however you want
OR
Modal Close icon
Payment Processing...
tick Completed

Billing Address

Key benefits

  • Techniques for DOM manipulation and efficient data handling
  • Use of JSON data and CSS grid layouts for a responsive game design
  • Dynamic game mechanics like card shuffling, matching logic, and score counters

Description

This course guides you through building a dynamic card-matching game using JavaScript, HTML, and CSS. Starting with project setup, you’ll structure HTML and CSS for a responsive grid layout to display the cards. You’ll learn essential CSS techniques, including root variables, responsive design elements, and grid-based styling, to enhance the game’s visual appeal and performance. Moving into JavaScript, you’ll load card data from JSON and apply asynchronous programming with fetch and async/await to populate the game grid seamlessly. The course covers array manipulation, DOM management, and efficient card rendering techniques that ensure smooth gameplay. You’ll implement the Fisher-Yates shuffle algorithm to create random card orders and learn advanced event handling to add interactive flip animations using CSS 3D transformations. In the final sections, we’ll add complex game logic for card matching, scoring, and restrictions on player actions for a polished user experience. To elevate your game’s visual appeal, you’ll incorporate animations like falling stars and transition effects. By the end, you’ll have a fully functional, interactive game, plus valuable JavaScript and CSS skills transferable to other projects, making this course ideal for developers eager to expand their frontend capabilities.

Who is this book for?

This course is designed for intermediate JavaScript learners familiar with basic HTML and CSS. A basic understanding of JavaScript fundamentals is recommended, as the course dives into array manipulation, asynchronous functions, and DOM management.

What you will learn

  • Develop a grid-based layout for game cards using HTML and CSS
  • Fetch and manipulate JSON data asynchronously with JavaScript
  • Apply efficient DOM updates and event handling techniques
  • Enhance the game interface with animations and responsive styling
  • Implement card flip animations using CSS 3D transformations
  • Code a random card shuffle function with the Fisher-Yates algorithm

Product Details

Country selected
Publication date, Length, Edition, Language, ISBN-13
Publication date : Nov 19, 2024
Length: 4hrs 4mins
Edition : 1st
Language : English
ISBN-13 : 9781837020492
Concepts :
Tools :

What do you get with a video?

Product feature icon Download this video in MP4 format
Product feature icon Access this title in our online reader with advanced features
Product feature icon DRM FREE - Read whenever, wherever and however you want
OR
Modal Close icon
Payment Processing...
tick Completed

Billing Address

Product Details

Publication date : Nov 19, 2024
Length: 4hrs 4mins
Edition : 1st
Language : English
ISBN-13 : 9781837020492
Concepts :
Tools :

Packt Subscriptions

See our plans and pricing
Modal Close icon
€18.99 billed monthly
Feature tick icon Unlimited access to Packt's library of 7,000+ practical books and videos
Feature tick icon Constantly refreshed with 50+ new titles a month
Feature tick icon Exclusive Early access to books as they're written
Feature tick icon Solve problems while you work with advanced search and reference features
Feature tick icon Offline reading on the mobile app
Feature tick icon Simple pricing, no contract
€189.99 billed annually
Feature tick icon Unlimited access to Packt's library of 7,000+ practical books and videos
Feature tick icon Constantly refreshed with 50+ new titles a month
Feature tick icon Exclusive Early access to books as they're written
Feature tick icon Solve problems while you work with advanced search and reference features
Feature tick icon Offline reading on the mobile app
Feature tick icon Choose a DRM-free eBook or Video every month to keep
Feature tick icon PLUS own as many other DRM-free eBooks or Videos as you like for just €5 each
Feature tick icon Exclusive print discounts
€264.99 billed in 18 months
Feature tick icon Unlimited access to Packt's library of 7,000+ practical books and videos
Feature tick icon Constantly refreshed with 50+ new titles a month
Feature tick icon Exclusive Early access to books as they're written
Feature tick icon Solve problems while you work with advanced search and reference features
Feature tick icon Offline reading on the mobile app
Feature tick icon Choose a DRM-free eBook or Video every month to keep
Feature tick icon PLUS own as many other DRM-free eBooks or Videos as you like for just €5 each
Feature tick icon Exclusive print discounts
Banner background image

Table of Contents

6 Chapters
Setting up the project code Chevron down icon Chevron up icon
Populate our CSS grid with cards Chevron down icon Chevron up icon
Adding flip effect, and using the Fisher-Yates shuffle Chevron down icon Chevron up icon
Adding logic for matched and unmatched cards, and counters Chevron down icon Chevron up icon
Coding falling stars, and adding a losing image overlay Chevron down icon Chevron up icon
Outro Chevron down icon Chevron up icon
Get free access to Packt library with over 7500+ books and video courses for 7 days!
Start Free Trial

FAQs

How can I download a video package for offline viewing? Chevron down icon Chevron up icon
  1. Login to your account at Packtpub.com.
  2. Click on "My Account" and then click on the "My Videos" tab to access your videos.
  3. Click on the "Download Now" link to start your video download.
How can I extract my video file? Chevron down icon Chevron up icon

All modern operating systems ship with ZIP file extraction built in. If you'd prefer to use a dedicated compression application, we've tested WinRAR / 7-Zip for Windows, Zipeg / iZip / UnRarX for Mac and 7-Zip / PeaZip for Linux. These applications support all extension files.

How can I get help and support around my video package? Chevron down icon Chevron up icon

If your video course doesn't give you what you were expecting, either because of functionality problems or because the content isn't up to scratch, please mail [email protected] with details of the problem. In addition, so that we can best provide the support you need, please include the following information for our support team.

  1. Video
  2. Format watched (HTML, MP4, streaming)
  3. Chapter or section that issue relates to (if relevant)
  4. System being played on
  5. Browser used (if relevant)
  6. Details of support
Why can’t I download my video package? Chevron down icon Chevron up icon

In the even that you are having issues downloading your video package then please follow these instructions:

  1. Disable all your browser plugins and extensions: Some security and download manager extensions can cause issues during the download.
  2. Download the video course using a different browser: We've tested downloads operate correctly in current versions of Chrome, Firefox, Internet Explorer, and Safari.