# cocos2d/cocos2d-x SLOC report

> cocos2d/cocos2d-x: 775,357 code lines at commit e4b6a5ef8fcd, counted with tokei-15.0.0 on 2026-11-11. Saved result cc1c7e75f73d75af2505a2bea67fa8047c012803b13bfa1abcd895d71bd300bc.

cocos2d/cocos2d-x has 775,357 source lines of code out of 1,119,123 total lines across 2,982 files, counted with tokei from the v3 ref at commit e4b6a5ef8fcd on November 11, 2026. Tests, docs and generated files are excluded under OctoCounts' canonical public options.

OctoCounts produced this report by resolving cocos2d/cocos2d-x to commit e4b6a5ef8fcd, downloading the repository source archive, and counting files selected by the effective rules with tokei, the open-source line counter written in Rust. The table below breaks the count down by programming language into files, total lines, code lines, comment lines, and blank lines, so the figures can be compared across languages and projects. Results are cached by commit, tokei version, and analysis options; an exact reproduction needs the same commit, engine version, and effective counting rules.

## Counting rules and retention

cocos2d/cocos2d-x: tokei-15.0.0, policy directories-v1; docs excluded, tests excluded, generated excluded. Excluded directory names: .cache, .generated, .git, .next, __tests__, build, dist, doc, docs, documentation, fixtures, gen, generated, node_modules, target, test, tests, vendor. Ignored languages: none. Repository declarations: off. Exclusions are rule-based; they do not prove that every test, document or generated file was removed.

Saved reports remain subject to cache cleanup and replacement. Export the JSON or text for durable citation; live repository URLs can change.

## Repository size insights

This is a large codebase by counted code lines. Code represents 69.3% of all lines, comments represent 17.1%, and the repository averages 260 code lines per file. C++ accounts for 75.6% of counted code.

| Language | Files | Lines | Code | Comments | Blanks |
| --- | ---: | ---: | ---: | ---: | ---: |
| C++ | 816 | 719,204 | 586,275 | 37,043 | 95,886 |
| C Header | 978 | 161,393 | 65,727 | 72,323 | 23,343 |
| JavaScript | 76 | 82,810 | 43,534 | 30,467 | 8,809 |
| Objective-C++ | 57 | 15,939 | 11,015 | 2,227 | 2,697 |
| C | 43 | 13,289 | 10,695 | 1,398 | 1,196 |
| Lua | 532 | 57,669 | 9,625 | 39,463 | 8,581 |
| C++ Header | 54 | 15,631 | 8,764 | 547 | 6,320 |
| JSON | 24 | 6,915 | 6,908 | 0 | 7 |
| Java | 41 | 9,943 | 6,817 | 1,744 | 1,382 |
| Visual Studio Project | 12 | 5,787 | 5,779 | 0 | 8 |
| Objective-C | 23 | 7,819 | 5,456 | 1,174 | 1,189 |
| Python | 44 | 5,156 | 4,079 | 416 | 661 |
| CMake | 52 | 4,886 | 3,843 | 645 | 398 |
| Makefile | 34 | 2,232 | 1,661 | 144 | 427 |
| GLSL | 42 | 2,036 | 1,428 | 567 | 41 |
| INI | 31 | 2,303 | 1,063 | 605 | 635 |
| FlatBuffers Schema | 6 | 747 | 595 | 32 | 120 |
| Shell | 17 | 799 | 564 | 110 | 125 |
| BASH | 3 | 492 | 372 | 66 | 54 |
| Visual Studio Solution | 4 | 236 | 232 | 0 | 4 |
| Batch | 16 | 296 | 224 | 0 | 72 |
| XML | 17 | 468 | 214 | 196 | 58 |
| MSBuild | 5 | 135 | 135 | 0 | 0 |
| PowerShell | 2 | 184 | 134 | 15 | 35 |
| Prolog | 5 | 158 | 134 | 0 | 24 |
| Autoconf | 1 | 51 | 51 | 0 | 0 |
| HTML | 1 | 44 | 30 | 7 | 7 |
| Module-Definition | 1 | 3 | 3 | 0 | 0 |
| Markdown | 8 | 696 | 0 | 478 | 218 |
| Plain Text | 37 | 1,802 | 0 | 1,459 | 343 |

Top language: C++ 75.6%. Generated on November 11, 2026. Canonical report: https://octocounts.com/github/cocos2d/cocos2d-x/commit/e4b6a5ef8fcdc99a7ebea606312b67fe4c534b9f?reportId=cc1c7e75f73d75af2505a2bea67fa8047c012803b13bfa1abcd895d71bd300bc&analysis=%7B%22profile%22%3A%22default%22%2C%22ignoredDirs%22%3A%5B%5D%2C%22includeDocs%22%3Afalse%2C%22includeTests%22%3Afalse%2C%22ignoredLanguages%22%3A%5B%5D%2C%22includeGenerated%22%3Afalse%7D

## Reproduce this report

[Reproduce this exact report and configuration](https://octocounts.com/github/cocos2d/cocos2d-x/commit/e4b6a5ef8fcdc99a7ebea606312b67fe4c534b9f?reportId=cc1c7e75f73d75af2505a2bea67fa8047c012803b13bfa1abcd895d71bd300bc&analysis=%7B%22profile%22%3A%22default%22%2C%22ignoredDirs%22%3A%5B%5D%2C%22includeDocs%22%3Afalse%2C%22includeTests%22%3Afalse%2C%22ignoredLanguages%22%3A%5B%5D%2C%22includeGenerated%22%3Afalse%7D).

## Report FAQ

### How many lines of code does cocos2d/cocos2d-x have?

cocos2d/cocos2d-x has 775,357 lines of code, plus 191,126 comment lines and 152,640 blank lines, for 1,119,123 total lines at commit e4b6a5ef8fcd on November 11, 2026. Tests, docs and generated files are excluded under OctoCounts' canonical public options.

### How was the cocos2d/cocos2d-x line count measured?

OctoCounts resolved the public GitHub repository to commit e4b6a5ef8fcd, downloaded the source archive, counted it with tokei, and cached the report by commit, tokei version, and analysis options.

### What commit was counted for cocos2d/cocos2d-x?

This OctoCounts report was generated from v3 at commit e4b6a5ef8fcd on November 11, 2026.

## Similar repository reports

- [gnu-octave/octave](https://octocounts.com/github/gnu-octave/octave) — C++, 765,656 code lines
- [Z3Prover/z3](https://octocounts.com/github/Z3Prover/z3) — C++, 756,294 code lines
- [CHMOSE023/MiniCAD](https://octocounts.com/github/CHMOSE023/MiniCAD) — C++, 749,791 code lines
- [zortos293/Lichii](https://octocounts.com/github/zortos293/Lichii) — C++, 803,556 code lines
- [zzj123321/MiniCAD](https://octocounts.com/github/zzj123321/MiniCAD) — C++, 744,992 code lines
- [PrismML-Eng/llama.cpp](https://octocounts.com/github/PrismML-Eng/llama.cpp) — C++, 824,986 code lines

## Related OctoCounts pages

- [Recently analyzed repositories](https://octocounts.com/recent)
- [Popular SLOC reports](https://octocounts.com/popular)
- [Trending GitHub repositories](https://octocounts.com/trending)
- [Hall of Monoliths](https://octocounts.com/hall-of-monoliths)
- [TensorFlow vs PyTorch](https://octocounts.com/compare/tensorflow-vs-pytorch)
- [Electron vs Tauri](https://octocounts.com/compare/electron-vs-tauri)
- [Godot vs Bevy](https://octocounts.com/compare/godot-vs-bevy)
- [How to count lines of code in a GitHub repository](https://octocounts.com/docs/count-lines-of-code-github)
- [GitHub SLOC counter guide](https://octocounts.com/docs/github-sloc-counter)
- [Counting methodology](https://octocounts.com/docs/methodology)
- [SLOC and code metrics glossary](https://octocounts.com/docs/glossary)
- [Original research: how filtering changes SLOC counts](https://octocounts.com/research)
- [OctoCounts API docs](https://octocounts.com/docs/api)
- [All OctoCounts guides](https://octocounts.com/docs)
