# cocos2d/cocos2d-x-samples SLOC report

> cocos2d/cocos2d-x-samples: 519,022 code lines at commit 9f1472d9083a, counted with tokei-15.0.0 on 2026-11-11. Saved result b5bfd63bedde7cc08ba5e328d694c0eb7ce3d7d51a368c9413414d2698a946e9.

cocos2d/cocos2d-x-samples has 519,022 source lines of code out of 907,001 total lines across 3,464 files, counted with tokei from the v3 ref at commit 9f1472d9083a 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-samples to commit 9f1472d9083a, 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-samples: 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 57.2% of all lines, comments represent 30.1%, and the repository averages 150 code lines per file. C Header accounts for 38.2% of counted code.

| Language | Files | Lines | Code | Comments | Blanks |
| --- | ---: | ---: | ---: | ---: | ---: |
| C Header | 1,670 | 494,135 | 198,013 | 231,218 | 64,904 |
| C++ | 634 | 241,551 | 188,987 | 21,217 | 31,347 |
| C | 39 | 29,476 | 26,436 | 1,344 | 1,696 |
| Lua | 150 | 27,790 | 20,804 | 3,500 | 3,486 |
| XML | 367 | 25,478 | 19,754 | 3,124 | 2,600 |
| Objective-C | 41 | 18,508 | 13,874 | 1,969 | 2,665 |
| Visual Studio Project | 53 | 12,939 | 12,927 | 12 | 0 |
| Java | 92 | 15,886 | 10,371 | 3,353 | 2,162 |
| Objective-C++ | 60 | 12,252 | 8,252 | 1,925 | 2,075 |
| C# | 27 | 4,286 | 2,928 | 819 | 539 |
| JavaScript | 25 | 3,428 | 2,067 | 1,079 | 282 |
| Visual Studio Solution | 17 | 1,941 | 1,931 | 0 | 10 |
| CMake | 32 | 2,387 | 1,829 | 216 | 342 |
| C++ Header | 12 | 2,532 | 1,689 | 330 | 513 |
| Python | 15 | 2,074 | 1,581 | 140 | 353 |
| Swift | 8 | 1,665 | 1,157 | 252 | 256 |
| Makefile | 43 | 1,417 | 1,096 | 45 | 276 |
| MSBuild | 10 | 1,114 | 1,070 | 32 | 12 |
| JSON | 30 | 977 | 973 | 0 | 4 |
| HTML | 3 | 972 | 948 | 1 | 23 |
| Shell | 13 | 761 | 567 | 74 | 120 |
| GLSL | 28 | 1,101 | 489 | 469 | 143 |
| XAML | 21 | 463 | 383 | 30 | 50 |
| .NET Resource | 4 | 516 | 280 | 236 | 0 |
| BASH | 2 | 328 | 248 | 44 | 36 |
| Batch | 3 | 246 | 163 | 0 | 83 |
| YAML | 1 | 139 | 128 | 10 | 1 |
| INI | 2 | 122 | 47 | 40 | 35 |
| Prolog | 2 | 34 | 30 | 0 | 4 |
| Markdown | 9 | 653 | 0 | 446 | 207 |
| Plain Text | 51 | 1,830 | 0 | 1,461 | 369 |

Top language: C Header 38.2%. Generated on November 11, 2026. Canonical report: https://octocounts.com/github/cocos2d/cocos2d-x-samples/commit/9f1472d9083a18853bb1fe97a337292f42abe44a?reportId=b5bfd63bedde7cc08ba5e328d694c0eb7ce3d7d51a368c9413414d2698a946e9&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-samples/commit/9f1472d9083a18853bb1fe97a337292f42abe44a?reportId=b5bfd63bedde7cc08ba5e328d694c0eb7ce3d7d51a368c9413414d2698a946e9&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-samples have?

cocos2d/cocos2d-x-samples has 519,022 lines of code, plus 273,386 comment lines and 114,593 blank lines, for 907,001 total lines at commit 9f1472d9083a on November 11, 2026. Tests, docs and generated files are excluded under OctoCounts' canonical public options.

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

OctoCounts resolved the public GitHub repository to commit 9f1472d9083a, 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-samples?

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

## Similar repository reports

- [cilium/tetragon](https://octocounts.com/github/cilium/tetragon) — C Header, 518,168 code lines
- [eclipse-openbsw/openbsw](https://octocounts.com/github/eclipse-openbsw/openbsw) — C Header, 525,137 code lines
- [raysan5/raylib](https://octocounts.com/github/raysan5/raylib) — C Header, 509,602 code lines
- [xenia-project/xenia](https://octocounts.com/github/xenia-project/xenia) — C Header, 544,336 code lines
- [houmo-ai/postmo-modelzoo](https://octocounts.com/github/houmo-ai/postmo-modelzoo) — C Header, 479,889 code lines
- [effekseer/Effekseer](https://octocounts.com/github/effekseer/Effekseer) — C Header, 479,516 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)
- [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)
