{"id":22678443,"url":"https://github.com/web2solutions/skix","last_synced_at":"2025-07-21T21:31:51.012Z","repository":{"id":149299666,"uuid":"360770379","full_name":"web2solutions/skix","owner":"web2solutions","description":"The notorious SkiFree Game","archived":false,"fork":false,"pushed_at":"2021-05-04T17:41:10.000Z","size":6157,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-03-29T13:12:34.136Z","etag":null,"topics":["cypress","es6","game-development","indexeddb","javascript","test-automation","unit-testing","vanilla-javascript","visual-testing","voodux"],"latest_commit_sha":null,"homepage":"https://skix.vercel.app","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/web2solutions.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2021-04-23T05:15:13.000Z","updated_at":"2023-03-08T03:37:30.000Z","dependencies_parsed_at":"2023-05-07T05:35:04.440Z","dependency_job_id":null,"html_url":"https://github.com/web2solutions/skix","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/web2solutions/skix","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/web2solutions%2Fskix","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/web2solutions%2Fskix/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/web2solutions%2Fskix/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/web2solutions%2Fskix/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/web2solutions","download_url":"https://codeload.github.com/web2solutions/skix/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/web2solutions%2Fskix/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":266382267,"owners_count":23920675,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-07-21T11:47:31.412Z","response_time":64,"last_error":null,"robots_txt_status":null,"robots_txt_updated_at":null,"robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["cypress","es6","game-development","indexeddb","javascript","test-automation","unit-testing","vanilla-javascript","visual-testing","voodux"],"created_at":"2024-12-09T18:15:21.037Z","updated_at":"2025-07-21T21:31:50.983Z","avatar_url":"https://github.com/web2solutions.png","language":"JavaScript","readme":"\u003cimg src=\"https://i.imgur.com/E6d4jv7.png\" height=\"200\"  /\u003e\n\n# SkiX, the SkiFree Game\n\n[![CircleCI](https://circleci.com/gh/web2solutions/skix/tree/main.svg?style=svg\u0026circle-token=bc4fd519af3fa134ece1332870cadcb82174130d)](https://circleci.com/gh/web2solutions/skix/tree/main)\n\n\n[Doc](https://web2solutions.github.io/skix/code)\n\n[Play online - Demo](https://skix.vercel.app/)\n\n### Run in dev mode\n\n```bash\nnpm install\nnpm run dev\n```\n\n\n### Run tests on Visual mode\n\n```bash\nnpm run cy:open\n\n```\n\n\n### Run tests on Unit mode\n\n\n```bash\nnpm run test\n```\n## Code challenge\n\nThis project is a answer to the following code challenge:\n\n- [Ceros Ski Code Challenge](https://github.com/tobbie/ceros-ski-master)\n\n### Changes made after the code being forked:\n\n\n1. `PROJECT SETUP`\n\n- The babel and wepack setup was update to use newer versions. Allowing, for example, the usage of private resources inside Classes. \n- Security issues related to modules being used is also now solved.\n- Added source maps to improve debugging.\n- Added Eslint to enforce best pratices and code quality.\n- jsDoc setup to generate documentation based on comments from source files.\n\n2. `BUG FIX`\n\nAfter get crashed when hitting an obstacle, the skier should be able to get and be facing to the left side up after pressing the `left arrow`.\n\n3. `BUG FIX`\n\nThere was a bug when starting the game and imediately calling ObstacleManager.placeNewObstacle() method. There were no conditionals checking the value of the variable `previousGameWindow`.\n\n\u003cimg src=\"https://i.imgur.com/86R358e.png\" width=\"400\"\u003e\n\n\n\n4. `REFACTOR`\n\n`Skier`: The property `Skier.assetName` is moved to `Entity` class to be able to be used by any class extending the Entity class.\n`Game`: \n\n5. `FEATURE`\n\n- The skier is now able to jump when pressing the `shift` key. \n- It original speed is incresed to two times. When jumping the skier does not get crashed if it hit any `rock` obstacle.\n\n\n6. `FEATURE`\n\n- The `Ramp Jump` obstacle  is now implemented.\n- When hitting the `ramp jump` the skier behaves like it's jumping.\n\n6. `TESTING`\n\n- Deprecated Jest in favor of Cypress to get a real browser environment to test the game. Jest setup would need at least one addon to deal with canvas and you still does not have a real browser environment. This change is now allowing `visual testing`.\n- Written unit tests to cover initial reported issue.\n- Written unit tests to cover the `jump` funcionality.\n- The test suite now is now able to be run as `unit test` and `visual testing and unit test` mode.\n\n\n\u003cimg src=\"https://i.imgur.com/ZgboCuV.png\" width=\"400\"\u003e\n\n\u003cimg src=\"https://i.imgur.com/oCZSccG.png\" width=\"400\"\u003e\n\n\u003cimg src=\"https://i.imgur.com/7y4VIaj.png\" width=\"400\"\u003e\n\n7. `REFACTOR`\n\nThe image assets were encoded into base64 strings and stored as js modules and now are they are built and loaded together with the `main` and `unique` `bundle file`.\n\nThis is a change which improves the game loading and make it easiest to update any asset\n\n8. `FEATURE`\n\nThe  rhino is up and hungry!\n\n- Rhino runs from right to left based in skier currently position\n\n\n9. `FEATURE`\n\nGame Stats Panel\n\n- Display time\n- Display distance\n- Display speed\n- Display style\n\n\n10. `FEATURE`\n\nGame console. The game console is the welcome screen allowing the player to select the game mode to start or check the game rank.\n\n11. `PROJECT SETUP`\n\n- Continuous integration setup using Circle CI.\n- Online demo is being deployed at vercel.\n\n12. `FEATURE`\n\nRank Database. It is saving the match data to indexeDB through [voodux](https://web2solutions.github.io/voodux/code/index.html)\n\n## Notes\n\n`NOTE 1`:\n\nExcept for the `pop up widgets` and `data persistence` features, this game is a VanilaJS implementation. For sure we can decrease the development time and improve the `game experience` by using 3 party libraries or framework, but the main idea is to show how to do things with pure JS.\n\n`NOTE 2`:\n\nRather building a back end to persist data, I have added [voodux](https://web2solutions.github.io/voodux/code/index.html) to the project to persist data in a local nosql database.\n\n\n`NOTE 3`:\n\nInside some classes such as Game and GameConsole there is a reference to the browser global window object. It may sounds dumb, but it provides support to visual testing throuhg Cypress. Cypress works by rendering the tested code in a iframe in the right side of the screen when you run it in a non headless mode.\n\n## Improvement suggestions:\n\n1. Implement better UI for asking player name.\n2. Give the player an option after being ate by rhino.\n3. Refactor game console.\n4. Deprecate voodux usage in favor of native IndexedDB API to reduce the bundle size. \n5. Write more unit tests.\n6. Write more e2e tests.\n7. Code coverage.\n8. Code documentation. jsDoc is already set up.\n\n## Known bugs\n\n1. When rhino is running into skier direction AND if iskier direction \n2. There are some cases where you are fast pressing arrows and you are eaten by rhino, the skier reappears in the screen.\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fweb2solutions%2Fskix","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fweb2solutions%2Fskix","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fweb2solutions%2Fskix/lists"}