BinaryBeasts (Pitch & Score) is a C++ desktop app built with raylib. It follows a three-tier architecture: presentation → logic → data.
🏆 Manage the League Standings table (add, edit, sort, search teams)
🔴 Preview Live scores (simulated from team data)
📅 Browse a Match schedule (generated fixtures)
📈 View Season stats (recursive totals)
💾 Persist teams in database.bin between sessions
| Menu item | Screen |
|---|---|
| League table & points | LeagueStandings (presentation.cpp) |
| Live scores (simulated) | LiveScores |
| Match schedule | MatchSchedule |
| Season stats | SeasonStats |
| About this app | About |
| Exit | Quit |
The League Standings screen is drawn in presentation.cpp (run_app). Window title: Pitch & Score (1200×800). Main panel title: LEAGUE STANDINGS.
Each team is shown as a card row with these columns (same labels as in the UI):
| Column | Source field | UI behaviour |
|---|---|---|
| Team | Team.name |
Name + avatar initials + points progress bar vs league leader |
| Points | Team.points |
Display; + / − buttons adjust points (saved via persist_teams_logic) |
| Goals | Team.goalsScored |
Display; editable in the Edit modal |
| Tier | derived from Team.points |
Label from GetScoreTier() (see below) |
| Edit | — | Pencil button opens modal: name, goals, points |
| Points | Tier shown |
|---|---|
| ≥ 18 | Elite |
| ≥ 10 | Strong |
| ≥ 4 | Rising |
| < 4 | Developing |
| Control | Action |
|---|---|
| Main menu | Return to home menu |
| Add Team | Modal: team name → add_team_logic |
| Sort: Points / Goals / Name | Cycles sortMode 0→1→2 → sort_teams_by_mode_logic |
| Delete Last | delete_last_team_logic |
| Clear All | clear_all_teams_logic |
| Search name | ENTER: linear or binary (if sorted by name) + partial match; highlights found row |
| Key | Action |
|---|---|
| F1 | Cycle sort (points → goals → name) |
| F2 | Delete last team |
| F3 | Clear all teams |
| ENTER (search box) | Find team; binary search when sorted by name |
| ESC | Close modals / back from sub-screens |
| Element | Description |
|---|---|
| Total Goals | calculate_total_goals_from_teams_recursive |
| Score insights | Leader name, points, average points, leader tier |
| List hint | Up to 5 teams visible; Showing X–Y of N teams if more exist |
| Search result | Found: #rank Name or No match under search box |
On first run, presentation.cpp seeds: Real Madrid, FC Barcelona, Manchester City (0 points, 0 goals each).
| Field | Type | Max / notes |
|---|---|---|
id |
int |
Auto on add |
name |
char[50] |
49 chars + null |
points |
int |
Table points |
goalsScored |
int |
Season goals |
presentation.cpp — main loop, League Standings UI, modals, search highlight
football_menu.cpp — main menu and sub-screens (live, schedule, stats, about)
Sort: Quick Sort (points), std::sort (goals, name)
Search: linear, binary (name sort), partial name match
Recursion: total goals, total points, demo match goals series
Persistence: load_teams_logic / persist_teams_logic → data layer
Binary read/write of Team records to database.bin
| Ресурс | Преглед в браузър | Изтегляне |
|---|---|---|
| 📊 Презентация | Отвори | .pptx |
| 📝 Документация | Отвори | .docx |
| Component | Layer | Responsibility |
|---|---|---|
main.cpp |
— | Entry point, calls run_app() |
presentation.cpp |
Presentation | GUI, League Standings, user input |
football_menu.cpp |
Presentation | Main menu & sub-screens |
team_ui.cpp |
Presentation | Reusable team card helpers |
logic.cpp |
Logic | Sort, search, recursion, persist wrappers |
data.cpp |
Data | database.bin load/save |
Presentation → Logic → Data
(presentation, (logic.cpp) (data.cpp,
football_menu) database.bin)
![]() Мирослав Илиев 🎯 Scrum Trainer |
![]() Йордан Райнов ⚙️ Front-End Developer |
![]() Димитър Нягалов ⚙️ Back-End Developer |
![]() Иван Трифанов 🎨 Back-End Developer |
Windows
Visual Studio 2022 (MSVC v143)
NuGet package restore enabled
Git
git clone https://github.com/<your-username>/BinaryBeasts.git
cd BinaryBeastsOpen BinaryBeasts.sln in Visual Studio.
Restore NuGet packages (raylib in packages.config).
Select Debug | x64 (or your configuration).
Build the solution.
Run with F5 / Ctrl+F5 from Visual Studio.
Home menu: Pitch & Score → open League table & points.
Changes are saved to database.bin on edit and on exit.




