← Leaderboard

mshumer/Claude-of-Duty

View on GitHub ↗
Internal84

Unique within the repo — the other 16% repeats across its own files.

Public74

Unique across all public code — a further 10% is its own but appears in other public repos too.

Original and tidy — it rarely repeats itself, and little of it turns up in other public code. About as close to genuinely its own work as this metric can measure.

Worth consolidating — in the code

Real, actionable duplication in this repo's source, most concrete first.

Longest identical blocks

The longest runs of identical consecutive lines copied between two files (indentation ignored) — the most concrete copy-paste. Lift the block into a shared function or module.

LinesFile AFile BCross-repo
27 mshumer/Claude-of-Duty/src/materials/shoot.mjs:71 mshumer/Claude-of-Duty/src/weapons/shoot.mjs:81 same repo
17 mshumer/Claude-of-Duty/src/ai/shoot.mjs:35 mshumer/Claude-of-Duty/src/fx/shoot.mjs:37 same repo
11 mshumer/Claude-of-Duty/src/ai/shoot.mjs:78 mshumer/Claude-of-Duty/src/ui/preview.mjs:95 same repo
11 mshumer/Claude-of-Duty/src/fx/shoot.mjs:71 mshumer/Claude-of-Duty/src/ui/preview.mjs:95 same repo
11 mshumer/Claude-of-Duty/src/materials/shoot.mjs:39 mshumer/Claude-of-Duty/tools/shotset.mjs:44 same repo
11 mshumer/Claude-of-Duty/src/render/pass.js:67 mshumer/Claude-of-Duty/src/sky/fullscreen.js:82 same repo
11 mshumer/Claude-of-Duty/src/weapons/shoot.mjs:45 mshumer/Claude-of-Duty/tools/shotset.mjs:44 same repo
10 mshumer/Claude-of-Duty/tools/capture.mjs:68 mshumer/Claude-of-Duty/tools/demo.mjs:85 same repo
9 mshumer/Claude-of-Duty/src/ai/shoot.mjs:78 mshumer/Claude-of-Duty/tools/capture.mjs:111 same repo
9 mshumer/Claude-of-Duty/src/ai/shoot.mjs:78 mshumer/Claude-of-Duty/tools/shotset.mjs:95 same repo
9 mshumer/Claude-of-Duty/src/fx/shoot.mjs:71 mshumer/Claude-of-Duty/tools/capture.mjs:111 same repo
9 mshumer/Claude-of-Duty/src/fx/shoot.mjs:71 mshumer/Claude-of-Duty/tools/shotset.mjs:95 same repo
9 mshumer/Claude-of-Duty/src/ui/preview.mjs:95 mshumer/Claude-of-Duty/tools/capture.mjs:111 same repo
9 mshumer/Claude-of-Duty/src/ui/preview.mjs:43 mshumer/Claude-of-Duty/src/world/probe.mjs:38 same repo
9 mshumer/Claude-of-Duty/src/ui/preview.mjs:95 mshumer/Claude-of-Duty/tools/shotset.mjs:95 same repo
9 mshumer/Claude-of-Duty/tools/capture.mjs:111 mshumer/Claude-of-Duty/tools/shotset.mjs:95 same repo
8 mshumer/Claude-of-Duty/src/ai/shoot.mjs:44 mshumer/Claude-of-Duty/src/materials/shoot.mjs:42 same repo
8 mshumer/Claude-of-Duty/src/ai/shoot.mjs:44 mshumer/Claude-of-Duty/src/weapons/shoot.mjs:48 same repo
8 mshumer/Claude-of-Duty/src/audio/probe.mjs:51 mshumer/Claude-of-Duty/tools/demo.mjs:63 same repo
8 mshumer/Claude-of-Duty/src/fx/shoot.mjs:46 mshumer/Claude-of-Duty/src/materials/shoot.mjs:42 same repo

Top duplication hotspots

SimilarityOverlapFile AFile BCross-repo
6% 421 mshumer/Claude-of-Duty/src/weapons/materials.js mshumer/Claude-of-Duty/src/weapons/parts.js same repo
5% 377 mshumer/Claude-of-Duty/src/render/index.js mshumer/Claude-of-Duty/src/sky/index.js same repo
5% 376 mshumer/Claude-of-Duty/src/weapons/hands.js mshumer/Claude-of-Duty/src/weapons/materials.js same repo
6% 362 mshumer/Claude-of-Duty/src/weapons/hands.js mshumer/Claude-of-Duty/src/weapons/viewmodel.js same repo
5% 346 mshumer/Claude-of-Duty/src/weapons/hands.js mshumer/Claude-of-Duty/src/weapons/parts.js same repo
4% 328 mshumer/Claude-of-Duty/src/render/index.js mshumer/Claude-of-Duty/src/weapons/materials.js same repo
4% 303 mshumer/Claude-of-Duty/src/fx/index.js mshumer/Claude-of-Duty/src/render/index.js same repo
5% 292 mshumer/Claude-of-Duty/src/weapons/materials.js mshumer/Claude-of-Duty/src/weapons/viewmodel.js same repo
4% 289 mshumer/Claude-of-Duty/src/ai/index.js mshumer/Claude-of-Duty/src/render/index.js same repo
5% 287 mshumer/Claude-of-Duty/src/ai/index.js mshumer/Claude-of-Duty/src/fx/index.js same repo
6% 280 mshumer/Claude-of-Duty/src/world/buildings.js mshumer/Claude-of-Duty/src/world/dressing.js same repo
5% 279 mshumer/Claude-of-Duty/src/world/dressing.js mshumer/Claude-of-Duty/src/world/kit.js same repo
5% 272 mshumer/Claude-of-Duty/src/weapons/models/rifle.js mshumer/Claude-of-Duty/src/weapons/parts.js same repo
5% 267 mshumer/Claude-of-Duty/src/render/index.js mshumer/Claude-of-Duty/src/world/index.js same repo
4% 253 mshumer/Claude-of-Duty/src/ai/textures.js mshumer/Claude-of-Duty/src/weapons/materials.js same repo
6% 252 mshumer/Claude-of-Duty/src/world/dressing.js mshumer/Claude-of-Duty/src/world/interiors.js same repo
5% 243 mshumer/Claude-of-Duty/src/weapons/materials.js mshumer/Claude-of-Duty/src/weapons/models/rifle.js same repo
5% 241 mshumer/Claude-of-Duty/src/ai/agent.js mshumer/Claude-of-Duty/src/ai/index.js same repo
4% 239 mshumer/Claude-of-Duty/src/sky/index.js mshumer/Claude-of-Duty/src/weapons/materials.js same repo
3% 235 mshumer/Claude-of-Duty/src/render/index.js mshumer/Claude-of-Duty/src/weapons/hands.js same repo

Duplicate declarations

The same function, variable, class, or type name declared in more than one file — a fast copy-paste signal. Consider extracting a shared definition.

FilesDeclarationWhere
15 type three mshumer/Claude-of-Duty/src/ai/preview.js
mshumer/Claude-of-Duty/src/fx/haze.js
mshumer/Claude-of-Duty/src/fx/preview.js
+12 more
9 type png mshumer/Claude-of-Duty/src/ai/shoot.mjs
mshumer/Claude-of-Duty/src/fx/shoot.mjs
mshumer/Claude-of-Duty/src/materials/shoot.mjs
+6 more
4 fn clamp mshumer/Claude-of-Duty/src/audio/dsp.js
mshumer/Claude-of-Duty/src/physics/math.js
mshumer/Claude-of-Duty/src/player/springs.js
+1 more
4 fn ensureServer mshumer/Claude-of-Duty/src/audio/probe.mjs
mshumer/Claude-of-Duty/src/player/feeltest.mjs
mshumer/Claude-of-Duty/tools/capture.mjs
+1 more
3 fn clamp01 mshumer/Claude-of-Duty/src/ai/geo.js
mshumer/Claude-of-Duty/src/player/springs.js
mshumer/Claude-of-Duty/src/weapons/mathx.js
3 fn frame mshumer/Claude-of-Duty/src/ai/preview.js
mshumer/Claude-of-Duty/src/fx/preview.js
mshumer/Claude-of-Duty/src/weapons/preview.js
3 fn lerp mshumer/Claude-of-Duty/src/audio/dsp.js
mshumer/Claude-of-Duty/src/player/springs.js
mshumer/Claude-of-Duty/src/weapons/mathx.js
3 fn smoothstep mshumer/Claude-of-Duty/src/fx/noise.js
mshumer/Claude-of-Duty/src/player/springs.js
mshumer/Claude-of-Duty/src/weapons/mathx.js
2 class ambience mshumer/Claude-of-Duty/src/audio/ambience.js
mshumer/Claude-of-Duty/src/fx/ambience.js
2 fn blit mshumer/Claude-of-Duty/src/render/pass.js
mshumer/Claude-of-Duty/src/sky/fullscreen.js
2 fn box mshumer/Claude-of-Duty/src/ai/weapon.js
mshumer/Claude-of-Duty/src/weapons/geometry.js
2 fn damp mshumer/Claude-of-Duty/src/ui/util.js
mshumer/Claude-of-Duty/src/weapons/mathx.js
2 type debug mshumer/Claude-of-Duty/tools/baseline.mjs
mshumer/Claude-of-Duty/tools/shotset.mjs
2 fn drive mshumer/Claude-of-Duty/src/player/feeltest.mjs
mshumer/Claude-of-Duty/tools/demo-driver.js
2 fn easeInOutSine mshumer/Claude-of-Duty/src/player/springs.js
mshumer/Claude-of-Duty/src/weapons/mathx.js
2 fn easeOutCubic mshumer/Claude-of-Duty/src/player/springs.js
mshumer/Claude-of-Duty/src/weapons/mathx.js
2 class emitter mshumer/Claude-of-Duty/src/audio/spatial.js
mshumer/Claude-of-Duty/src/fx/ambience.js
2 type error mshumer/Claude-of-Duty/tools/playtest.mjs
mshumer/Claude-of-Duty/tools/verify-live.mjs
2 fn footstep mshumer/Claude-of-Duty/src/audio/foley.js
mshumer/Claude-of-Duty/tools/demo-audio.mjs
2 fn hdrTarget mshumer/Claude-of-Duty/src/render/pass.js
mshumer/Claude-of-Duty/src/sky/fullscreen.js
2 class noise mshumer/Claude-of-Duty/src/ai/geo.js
mshumer/Claude-of-Duty/src/fx/noise.js
2 var NOISE_GLSL mshumer/Claude-of-Duty/src/materials/glsl/noise.js
mshumer/Claude-of-Duty/src/sky/noise.js
2 fn place mshumer/Claude-of-Duty/src/ai/parts.js
mshumer/Claude-of-Duty/src/ui/util.js
2 fn play mshumer/Claude-of-Duty/src/fx/index.js
mshumer/Claude-of-Duty/src/ui/index.js
2 fn smootherstep mshumer/Claude-of-Duty/src/player/springs.js
mshumer/Claude-of-Duty/src/weapons/mathx.js

Largest files

Largest files

LOCFileStatus
2269mshumer/Claude-of-Duty/src/world/dressing.jsindexed
2072mshumer/Claude-of-Duty/src/weapons/parts.jsindexed
1696mshumer/Claude-of-Duty/src/render/index.jsindexed
1316mshumer/Claude-of-Duty/src/fx/index.jsindexed
1215mshumer/Claude-of-Duty/src/weapons/materials.jsindexed
1163mshumer/Claude-of-Duty/src/weapons/hands.jsindexed
1118mshumer/Claude-of-Duty/src/world/util.jsindexed
1113mshumer/Claude-of-Duty/src/world/kit.jsindexed
1107mshumer/Claude-of-Duty/src/ai/index.jsindexed
1088mshumer/Claude-of-Duty/src/weapons/viewmodel.jsindexed