Matchmake is an ongoing project aimed at implementing a player matchmaking system using an AVL tree for efficient player ranking and matching. This project is currently in development and demonstrates the use of advanced data structures in Zig.
PS: "24" on Magic Johnson is incorrectCursor.mp4
The project consists of three main files:
main.zig
: The entry point of the application.avl.zig
: Implementation of the AVL tree data structure for player ranking.build.zig
: The build configuration file for the Zig compiler.
The current main.zig
file generates a set of 10,000 random players with scores and writes them to a JSON file. This serves as a data generation step for testing the AVL tree implementation.
avl.zig
contains a comprehensive implementation of an AVL tree tailored for a leaderboard system. It includes the following key features:
- Player struct with name and score
- AVL tree node structure
- Insertion, deletion, and search operations
- Tree balancing methods
- Utility functions for traversal and player ranking
The build.zig
file configures the build process for the project. It sets up the main executable and includes the AVL module.
To build and run the project:
- Ensure you have Zig installed (tested with version 0.13.0).
- Navigate to the project directory.
- Run the following command:
zig build run
This will compile the project and run the main application, which currently generates a players.json
file with random player data.
This project is actively being developed. Future plans