Get AI summaries of any video or article — Sign up free
Real Game Dev Reviews Game By Devin.ai thumbnail

Real Game Dev Reviews Game By Devin.ai

The PrimeTime·
5 min read

Based on The PrimeTime's video on YouTube. If you like this content, support the original creators by watching, liking and subscribing to their content.

TL;DR

Devin AI’s PRs were automatically merged into master via a CI actor check, enabling rapid chat-driven iteration despite Devin being unable to push to master directly.

Briefing

An autonomous coding agent (Devin AI) was pushed—via Twitch chat prompts—into generating and iterating a playable Doom-style browser game in roughly eight hours, producing about 126 commits/PRs and thousands of lines of JavaScript/HTML. The result is functional and surprisingly aligned with the requested premise, but the code quality is widely criticized as brittle, inefficient, and hard to maintain—turning the project into a live stress test of what “English-to-code” can do today.

The workflow hinges on a workaround for Devin’s inability to push directly to the GitHub master branch. Instead, when Devin’s CI actor is detected as Devin, the changes are automatically merged into master. Every few minutes, Twitch chat sends a new instruction, indirectly steering the agent’s next implementation steps. Over the session, chat requests lead to visible gameplay features: a first-person shooter loop with walls, enemies, bullets, a minimap, health/HUD elements, and even “fire and cheese” effects—though the cheese portion becomes a recurring debugging saga.

The game’s core loop is reviewed line-by-line through a code walkthrough. The browser animation timing uses requestAnimationFrame with a timestamp, and the loop clears the canvas, draws walls and enemies, updates bullets, handles collisions, and renders overlays like semi-transparent bullet effects. Collision logic relies on distance checks (with discussion of why squared distances usually avoid square roots), and bullets have a limited lifetime. When enemies die, the code removes them from arrays immediately, which the reviewer flags as a common source of state bugs in real games—especially when other systems might hold references to entities.

Player movement and physics receive heavy critique. Movement and friction appear frame-rate dependent because there’s little or no delta-time scaling, meaning acceleration and velocity changes assume a stable update rate. Wall collision is treated like tile collision with limited neighborhood checks, raising the risk of tunneling at higher speeds. Strafing and rotation also show “laggy” behavior, attributed to an input timeline mismatch when chat nudged controls from turning to strafing.

Enemy behavior includes pathfinding logic that resembles A* using a priority queue and a heuristic based on distance. The reviewer notes rate limiting around path updates and discusses how sorting by distance is used for draw order in engines without a z-buffer—yet the code sorts enemies and then later updates them, potentially undoing the intended ordering. Rendering choices are repeatedly called out as cargo-culted: expensive angle math (atan2) appears in projection, and repeated sign/cosine computations and long-hand distance calculations reduce maintainability.

The “cheese” feature becomes the project’s punchline. Devin eventually adds a cheese sprite asset and gets cheese bobbing onto the screen, but earlier attempts fail due to missing rendering hooks, asset mismatches, and coordinate/spawn bugs (including a moment where negative radius values appear). Even when cheese finally appears, it’s not consistently integrated with the rest of the world rendering and ordering.

Overall, the session lands on a split verdict: English understanding and feature completion are impressive, but the resulting codebase is “rewrite-level” poor—inefficient, duplicated, and fragile. The reviewer suggests these tools may be more useful as code search or scaffolding than as production-ready game engines, and proposes future iterations (like an idle RPG) as a more forgiving target for automated development.

Cornell Notes

Devin AI was used as a fully autonomous coding agent to build a Doom-like first-person browser shooter by repeatedly merging PRs into a GitHub project. Twitch chat provided English prompts every few minutes, steering the agent toward features like walls, enemies, bullets, HUD/minimap, and a requested “fire and cheese” mechanic. A detailed code review found the game is playable and the agent’s English-to-code mapping is strong, but the implementation quality is weak: frame-rate-dependent physics, brittle collision handling, inefficient math (including heavy angle/projection work), and entity-management patterns that can cause subtle bugs. The cheese feature illustrates both the agent’s persistence and its tendency to miss integration details (assets, rendering paths, and spawn logic) even after adding partial solutions.

How did the project get around Devin AI’s inability to push to master, and why does that matter for the build process?

Devin AI couldn’t directly push to the master branch, so the workflow used GitHub CI as a gate: when the CI actor was Devin, the system automatically merged Devin’s PR into master. That meant chat-driven prompts could trigger new autonomous code changes that landed quickly without manual intervention, enabling ~126 merged PRs over about eight hours.

What did the code review say about the game loop and timing in JavaScript?

The game loop uses requestAnimationFrame and leverages the callback timestamp to drive updates. The reviewer also distinguishes between calling requestAnimationFrame continuously (to keep animating) versus pausing when waiting for input. They note that requestAnimationFrame doesn’t guarantee a fixed 60Hz cadence, so using delta-time is important for consistent physics—an issue later criticized in movement.

Why is removing enemies/bullets immediately during collision potentially dangerous in real game code?

Immediate removal can break indirect references held by other systems (targeting, chasing, animation state). The reviewer describes a classic failure mode: if an entity is removed from an array, indices shift, and other entities may now point to the wrong target. Common mitigations include marking entities as dead (sparse arrays) or using stable handles/IDs so references remain valid even after an entity is “killed.”

What were the biggest concerns about player movement and physics?

Movement and friction appear frame-rate dependent because there’s little/no delta-time scaling. The reviewer argues that acceleration and velocity updates should be proportional to elapsed time; otherwise, a slow frame causes too little movement and a fast frame causes too much. They also flag wall collision as tile-based with limited neighborhood checks, which can cause tunneling if movement crosses more than one tile per frame.

How did enemy pathfinding work, and what did the reviewer infer about its approach?

Enemy movement uses a priority queue and an A*-like structure: it enqueues a start node, dequeues the most promising node, checks neighbors (likely the 8 surrounding tiles), and uses a heuristic based on distance (the reviewer explicitly connects this to A*’s f = g + h idea). Path updates are rate-limited using real-time checks rather than a uniform simulation timestep.

What went wrong with the “cheese” mechanic, and what ultimately made it appear?

Cheese repeatedly failed to render due to missing or incorrect integration: collectibles weren’t rendered initially, assets were mismatched (sprite atlas lookups), and spawn/render coordinates were buggy (including a later mention of negative radius). Eventually, Devin added a cheese sprite asset and the rendering pipeline began showing bobbing cheese on-screen, but ordering/sorting with walls/enemies remained inconsistent.

Review Questions

  1. Which parts of the code review suggest the game’s physics are frame-rate dependent, and what delta-time mechanism would typically fix that?
  2. What entity-management strategy (dead flags, sparse arrays, or stable handles) would prevent the “wrong enemy index” bug described in the review?
  3. Why does a z-buffer absence push engines toward sorting by distance/draw order, and how could sorting become incorrect if the array is later mutated?

Key Points

  1. 1

    Devin AI’s PRs were automatically merged into master via a CI actor check, enabling rapid chat-driven iteration despite Devin being unable to push to master directly.

  2. 2

    Twitch chat prompts every few minutes steered the agent toward gameplay features, resulting in a functional Doom-like browser shooter with HUD and minimap.

  3. 3

    The game loop uses requestAnimationFrame with timestamps, but movement/physics criticized as frame-rate dependent due to missing delta-time scaling.

  4. 4

    Collision and entity handling were flagged as brittle: immediate removal from arrays can break indirect references and cause subtle targeting/behavior bugs.

  5. 5

    Enemy pathfinding resembles A* with a priority queue and a distance-based heuristic, while path updates are rate-limited using real-time checks.

  6. 6

    Rendering math and architecture choices were repeatedly criticized as inefficient and hard to maintain, including heavy angle/projection computations and duplicated distance calculations.

  7. 7

    The “cheese” feature demonstrates partial success: assets and bobbing were eventually added, but earlier failures show how easy it is to miss rendering hooks, asset wiring, and spawn logic.

Highlights

Chat-driven prompts produced ~126 merged PRs in about eight hours, turning English instructions into a working first-person shooter prototype.
The review repeatedly contrasts impressive English-to-code capability with “rewrite-level” maintainability problems: duplicated math, brittle collision, and frame-dependent physics.
Cheese became a long-running integration bug: it required correct collectible rendering, sprite asset wiring, and spawn/render coordinates before it finally appeared.
Enemy behavior blends raycaster-style draw-order concerns with A*-like pathfinding, but sorting and update ordering can undermine the intended z-index effect.

Topics

  • Autonomous Coding Agents
  • Game Development
  • JavaScript Game Loop
  • Pathfinding
  • Rendering and Collision
  • Debugging Collectibles

Mentioned