Code2Games: Enabling Coding Agents for Gaming World Generation
cs.CV
Submitted: 2026-10-04
Updated: 2026-10-04
Comments: Code: https://github.com/AIGeeksGroup/Code2Games, Website: https://aigeeksgroup.github.io/Code2Games
Code: https://github.com/AIGeeksGroup/Code2Games
Project page: https://aigeeksgroup.github.io/Code2Games
License: http://creativecommons.org/licenses/by-nc-sa/4.0/
The gist: Generating a high-quality gaming world from a natural-language game intent requires joint reasoning about scene structure, spatial layout, gameplay objectives, interactive entities, and executable
Abstract
Generating a high-quality gaming world from a natural-language game intent requires joint reasoning about scene structure, spatial layout, gameplay objectives, interactive entities, and executable gameplay logic. Existing coding agents can generate individual assets, scenes, or scripts, but often struggle to maintain consistency across these components. We propose Code2Games, an agentic framework that builds a structured gaming world upon a base Blender world generated from the same game intent. Code2Games coordinates scene analysis, gameplay planning, constrained gaming-world generation, and gaming-engine customization through a shared scene-gameplay representation with persistent element correspondence. After world generation, Code2Games adapts the generated world to Unreal Engine 5 and employs an execution-guided reconstruction process that uses compilation diagnostics, runtime feedback, and gameplay test results to resolve inconsistencies arising during engine adaptation. To systematically evaluate gaming-world generation, we introduce the GameCode4D benchmark, which comprises ten fixed game prompts spanning different levels of scene and gameplay complexity. We evaluate the generated results across four dimensions: visual quality, interactive fidelity, multimodal artifact quality, and playable-game quality. Experiments demonstrate that, compared with direct gaming-world generation by coding agents and existing baseline methods, Code2Games consistently improves the visual quality and interactive fidelity of generated gaming worlds, as well as the quality of the resulting games after engine adaptation.
Sources
- Vid2World: Crafting Video Diffusion Models to Interactive World Models
- OpenGame: Open Agentic Coding for Games
- Hunyuan-GameCraft: High-dynamic Interactive Game Video Generation with Hybrid History Condition
- GameCraft-Bench: Can Agents Build Playable Games End-to-End in a Real Game Engine?
- Playable Video Generation
- Hunyuan-GameCraft-2: Instruction-following Interactive Game World Model
- Voyager: An Open-Ended Embodied Agent with Large Language Models
- RoboGen: Towards Unleashing Infinite Data for Automated Robot Learning via Generative Simulation
- ReAct: Synergizing Reasoning and Acting in Language Models
- WBench: A Comprehensive Multi-turn Benchmark for Interactive Video World Model Evaluation
- Code2Worlds: Empowering Coding LLMs for 4D World Generation
- VBench-2.0: Advancing Video Generation Benchmark Suite for Intrinsic Faithfulness
- GALA3D: Towards Text-to-3D Complex Scene Generation via Layout-guided Generative Gaussian Splatting
Related papers
- Loss Knows Best: Detecting Annotation Errors in Videos via Loss Trajectories
- AnchorWeave: World-Consistent Video Generation with Retrieved Local Spatial Memories
- Benchmarking the Robustness of Foundation Models for Mammography under Domain Shift
- MambaX-Net: Dual-Input Mamba-Enhanced Cross-Attention Network for Longitudinal MRI Segmentation
- TeleOCR: Navigating Document Parsing Across Digital and Camera-Captured Documents
- A Survey on Efficient Vision-Language-Action Models