Skip to content

AlirezaAbedizadeh/PVZ

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

119 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

🌱 Plants vs Zombies Clone (C++ / SFML)

A dynamic Plants vs Zombies–style game developed collaboratively as a personal project using C++ and SFML. The game closely replicates the core mechanics of the original PVZ, featuring a fully dynamic environment, real-time gameplay, and integrated sound effects.

The main focus of this project was on gameplay logic, performance-aware design, and real-time audio handling.


🎮 Key Features

  • Lane-based tower defense gameplay inspired by the original PVZ
  • Fully dynamic game environment with real-time updates
  • Multiple plant types with distinct attack and support behaviors
  • Zombie enemies with different movement, health, and damage models
  • Wave-based enemy spawning and difficulty progression
  • Resource (sun) generation and management system
  • Integrated sound effects for shooting, planting, collisions, zombie attacks, and game events

🔊 Audio System (SFML)

  • Sound effects implemented using SFML Audio
  • Event-driven sound triggering (e.g., attacks, hits, spawning)
  • Non-blocking audio playback integrated into the main game loop
  • Support for overlapping sound effects without interrupting gameplay

🧠 Game Architecture

  • Implemented in C++ using object-oriented design principles
  • Core real-time game loop handling:
    • Input processing
    • Game state updates
    • Rendering via SFML Graphics
    • Audio playback via SFML Audio
  • Modular class hierarchy for plants, zombies, projectiles, and tiles
  • Clear separation between game logic, rendering, and sound management
  • Designed for extensibility (easy addition of new entities)

🛠️ Technologies Used

  • Language: C++
  • Framework: SFML (Graphics, Window, Audio)
  • Build: g++ / CMake
  • Version Control: Git, GitHub

▶️ How to Build & Run

Prerequisites

  • C++17 compatible compiler
  • SFML installed
  • Make

Build

make

Run

./pvz.out

The project includes a Makefile that handles compilation and linking with SFML.


👥 Team Contributions

  • Alireza Abedizadeh
  • Parsa Saeednia

📸 Gameplay Demo

Demo.mp4

🚀 Future Improvements

  • Background music with adaptive intensity
  • Additional plant and zombie types
  • Improved animations and visual effects
  • Advanced difficulty scaling
  • Save/load game system

📄 License

This project was developed for educational and personal use.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 2

  •  
  •