MCPcopy Create free account
hub / github.com/codemistic/Web-Development / checkLose

Function checkLose

JS - Chrome Dino Game Clone/script.js:39–42  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

37}
38
39function checkLose() {
40 const dinoRect = getDinoRect()
41 return getCactusRects().some(rect => isCollision(rect, dinoRect))
42}
43
44function isCollision(rect1, rect2) {
45 return (

Callers 1

updateFunction · 0.85

Calls 3

getDinoRectFunction · 0.90
getCactusRectsFunction · 0.90
isCollisionFunction · 0.85

Tested by

no test coverage detected