Skip to content

๐ŸŽฎ Platformer game built with Phaser.js ๐ŸŒŸ Collect coins ๐Ÿช™ avoid bombs ๐Ÿ’ฃ jump through fun levels!

License

Notifications You must be signed in to change notification settings

TorresjDev/TS-Phaser-Game-Jumper

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

๐ŸŽฎ Jumper - A Professional TypeScript Phaser 3 Platformer

GitHub Pages Deploy License Phaser TypeScript Webpack Node

๐ŸŽฎ PLAY GAME NOW! ๐Ÿš€

Game Logo

โœจ Project Highlights

This is a fully modern, TypeScript-powered platformer game that showcases professional game development practices:

  • ๐Ÿ”ฅ Full TypeScript conversion from JavaScript for better developer experience
  • ๐Ÿš€ Automated CI/CD pipeline with GitHub Actions
  • ๐ŸŽฏ Advanced game mechanics with Pac-Man style wrapping and dynamic physics
  • ๐Ÿ› ๏ธ Professional development workflow with feature branches and proper deployment
  • ๐Ÿ’Ž Production-ready build system with Webpack optimization

๐ŸŽฎ Game Features

Core Gameplay

  • Smooth platformer mechanics with precise jump controls
  • Coin collection system with animated score feedback
  • Dynamic bomb spawning with intelligent bounce physics
  • Advanced wrapping mechanics - player wraps on all edges like Pac-Man
  • Smart bomb physics - bombs wrap horizontally but bounce off vertical boundaries
  • Bomb lifecycle management - bombs self-destruct after 30 bounces

Technical Excellence

  • TypeScript architecture with proper type safety and interfaces
  • Custom game objects with extended Phaser sprite interfaces
  • Modular scene management with clean separation of concerns
  • Professional asset pipeline with organized sprite management
  • Responsive design that scales to any screen size

๐Ÿ—๏ธ Technology Stack

Technology Purpose Version
TypeScript Type-safe game logic Latest
Phaser 3 Game engine 3.80.1
Webpack Module bundling & optimization 5.90.3
GitHub Actions CI/CD automation Latest
GitHub Pages Static hosting Latest
ts-loader TypeScript compilation Latest

๐ŸŒ Live Demo & Deployment

๐ŸŽฎ Play Online: https://torresjdev.github.io/TS-Phaser-Game-Jumper/

Deployment Pipeline

  • โœ… Automated Deployment: Every push to main triggers deployment
  • โœ… Production Optimization: Webpack minification and asset optimization
  • โœ… GitHub Pages: Fast CDN delivery
  • โœ… Build Validation: TypeScript compilation checks
  • ๐Ÿ”„ Continuous Integration: Automated testing and deployment

๏ฟฝ Project Architecture

TS-Phaser-Game-Jumper/
โ”œโ”€โ”€ ๐Ÿ“‚ src/                     # TypeScript source code
โ”‚   โ”œโ”€โ”€ ๐Ÿ“‚ scenes/              # Game scenes (TypeScript)
โ”‚   โ”‚   โ”œโ”€โ”€ Boot.ts             # Initial boot sequence
โ”‚   โ”‚   โ”œโ”€โ”€ Preloader.ts        # Asset loading with progress
โ”‚   โ”‚   โ”œโ”€โ”€ MainMenu.ts         # Main menu with animations
โ”‚   โ”‚   โ”œโ”€โ”€ Game.ts             # Core gameplay logic
โ”‚   โ”‚   โ””โ”€โ”€ GameOver.ts         # Game over screen
โ”‚   โ””โ”€โ”€ main.ts                 # Application entry point
โ”œโ”€โ”€ ๐Ÿ“‚ public/                  # Static assets
โ”‚   โ”œโ”€โ”€ ๐Ÿ“‚ assets/              # Game assets
โ”‚   โ”‚   โ”œโ”€โ”€ ๐Ÿ“‚ images/          # Sprites and backgrounds
โ”‚   โ”‚   โ”‚   โ”œโ”€โ”€ ๐Ÿ“‚ characters/  # Player sprites
โ”‚   โ”‚   โ”‚   โ”œโ”€โ”€ ๐Ÿ“‚ items/       # Coins and bombs
โ”‚   โ”‚   โ”‚   โ”œโ”€โ”€ ๐Ÿ“‚ platforms/   # Platform sprites
โ”‚   โ”‚   โ”‚   โ””โ”€โ”€ ๐Ÿ“‚ ui/          # UI elements
โ”‚   โ”‚   โ””โ”€โ”€ ๐Ÿ“‚ audio/           # Sound effects
โ”‚   โ””โ”€โ”€ style.css               # Game styling
โ”œโ”€โ”€ ๐Ÿ“‚ webpack/                 # Build configuration
โ”‚   โ”œโ”€โ”€ config.js               # Development config
โ”‚   โ””โ”€โ”€ config.prod.js          # Production config
โ”œโ”€โ”€ ๐Ÿ“‚ .github/                 # CI/CD workflows
โ”‚   โ””โ”€โ”€ ๐Ÿ“‚ workflows/
โ”‚       โ””โ”€โ”€ deploy.yml          # Deployment automation
โ”œโ”€โ”€ tsconfig.json               # TypeScript configuration
โ”œโ”€โ”€ package.json                # Dependencies and scripts
โ””โ”€โ”€ index.html                  # HTML entry point

๐Ÿš€ Quick Start

Prerequisites

  • Node.js 18+
  • npm or yarn
  • Modern web browser

Development Setup

  1. Clone the repository:

    git clone https://github.com/TorresjDev/TS-Phaser-Game-Jumper.git
    cd TS-Phaser-Game-Jumper
  2. Install dependencies:

    npm install
  3. Start development server:

    npm start

    Opens automatically at http://localhost:8082

  4. Build for production:

    npm run build

๐ŸŽฏ Game Controls

Key Action
โ† Move left
โ†’ Move right
โ†‘ Jump
Click Start game / Navigate menus

๐ŸŽฎ Game Scenes Deep Dive

๐Ÿš€ Boot Scene

  • Initializes Phaser engine
  • Loads initial background
  • Sets up scene transitions

๏ฟฝ Preloader Scene

  • Loads all game assets with progress indication
  • Preloads sprites, audio, and animations
  • Smooth transition to main menu

๐Ÿ  MainMenu Scene

  • Animated logo display
  • Interactive start button
  • Clean, professional UI design

๐ŸŽฏ Game Scene (Core Gameplay)

Advanced Features:

  • Player Wrapping: Complete Pac-Man style screen wrapping
  • Smart Bomb Physics: Horizontal wrapping with vertical bouncing
  • Bounce Management: Bombs self-destruct after 30 bounces
  • Dynamic Spawning: Intelligent bomb placement based on player position
  • Score Animation: Smooth tween-based score feedback
  • Sound Integration: Immersive audio feedback

๏ฟฝ GameOver Scene

  • Dramatic red overlay effect
  • Score display and restart option
  • Smooth scene transitions

๐Ÿ”ง Development Features

TypeScript Benefits

  • Full IntelliSense support in VS Code
  • Compile-time type checking catches errors early
  • Custom interfaces for game objects (BombSprite)
  • Better refactoring and code navigation
  • Professional development experience

Build System

  • Webpack 5 with optimized production builds
  • ts-loader for seamless TypeScript compilation
  • Asset optimization and minification
  • Source maps for debugging
  • Hot reload during development

CI/CD Pipeline

  • Automated testing on every commit
  • Production builds triggered by main branch pushes
  • GitHub Pages deployment with zero downtime
  • Build artifact caching for faster deployments

๐Ÿค Contributing

We welcome contributions! Please follow our development workflow:

Development Workflow

  1. Fork the repository
  2. Create feature branch: git checkout -b feature/your-feature
  3. Develop with TypeScript - full IntelliSense support
  4. Test thoroughly - both dev and production builds
  5. Commit with clear messages: git commit -m "feat: add amazing feature"
  6. Push and create PR: Professional review process

Code Standards

  • TypeScript: All new code must be TypeScript
  • Type Safety: Proper type annotations required
  • Clean Code: Follow existing patterns and structure
  • Comments: Document complex game logic
  • Testing: Ensure both builds work correctly

๐Ÿ“Š Project Stats

  • Language Distribution: 68.3% TypeScript, 27.2% JavaScript, 4.5% Other
  • Total Lines: ~300+ lines of well-structured code
  • Scenes: 5 professionally crafted game scenes
  • Assets: Organized sprite sheets and audio files
  • Build Size: Optimized production bundle
  • Performance: 60 FPS smooth gameplay

๐Ÿ† Achievements

โœ… Full TypeScript Conversion - Complete migration from JavaScript
โœ… Professional CI/CD - Automated deployment pipeline
โœ… Advanced Game Mechanics - Pac-Man wrapping + dynamic physics
โœ… Production Deployment - Live on GitHub Pages
โœ… Modern Tooling - Webpack 5 + TypeScript + GitHub Actions
โœ… Clean Architecture - Modular, maintainable codebase


๐Ÿ“„ License

This project is licensed under the MIT License - see the LICENSE file for details.


๐Ÿ™ Acknowledgments

  • Phaser.js - Amazing HTML5 game framework
  • TypeScript - For making JavaScript development professional
  • GitHub - For excellent CI/CD and hosting platform
  • Community - For inspiration and feedback

๐ŸŽฎ Ready to Play?

LAUNCH GAME โ†’

Built with โค๏ธ using TypeScript and Phaser 3

Releases

No releases published

Packages

No packages published

Contributors 10