Bevy Tutorial: Build Your First 3D Editor - Create a 3D Space on an Infinite Grid A new tutorial series guides developers through building a 3D scene editor in Bevy 0.19, inspired by Blender. The first episode covers setting up a basic 3D scene with a camera, light, and cube on an infinite grid, using Bevy's ECS architecture. The series aims to provide a reusable editor for game development, with free posts covering move, rotate, resize, materials, shaders, scene saving, and GLTF import. Episode 1 Bevy Tutorial: Build Your First 3D Editor - Create a 3D Space on an Infinite Grid On AI assistance Discord https://discord.com/invite/cD9qEsSjUH and I'll work on it. I’ve been following the Bevy 0.19 release and kept asking myself: what’s something cool to build with all the new building blocks 0.19 is shipping? I tinkered around and ended up with a small 3D editor inspired by Blender. A 3D editor sounds big, but our focus is a simple scene editor to build environments, place enemies, etc. Any game that has a world needs some way to author it. In this series we’ll build a simple one for exactly that purpose, something you can extend however your game needs. The nice part about building this in Bevy is that your editor and your game share the same ECS, so the scene you save is the scene your game loads. Which brings up the usual question. Should you actually build your own game editor, or wait for the official one, or just hand author your scenes in code? I’m not touching that debate with a ten-foot pole. Whatever you pick, someone in the internet will tell you you’re wrong anyway. Here’s what I plan to cover in this tutorial series: - A mini 3D editor inspired by Blender - Move, rotate, and resize with keyboard shortcuts - Change object materials, create a toon shader - Save and load scenes - Import GLTF models Everything listed above will ship as free blog posts. That part is settled. What I haven’t figured out yet is whether there will be any extra material beyond this list, and if so, whether it would be pay-gated. So treat the free posts as the plan, and anything past them as a maybe. In this tutorial, we will focus on the following: - A small 3D scene you can move around in like Blender - A grey cube in the middle - An infinite ground-plane grid with a red X axis and a green Y axis - A camera to orbit around the 3D space. Before We Begin: I'm constantly working to improve this tutorial. If anything trips you up, or if you want to see what's coming next, drop a note on Reddit https://www.reddit.com/r/bevy/ / LinkedIn https://www.linkedin.com/in/febinjohnjames . Loved it? Let me know what worked. Discord https://discord.com/invite/cD9qEsSjUH /This tutorial assumes you’re comfortable with structs, enums, associated functions and closures, all covered in our Bevy 2D Game Development series, Chapters 1–7 /posts/bevy-rust-game-development-chapter-1/ . If any of those feel shaky, those chapters are free and worth a read first. Project Setup The source code for the series and each episode is available in this repo https://github.com/jamesfebin/Build-Your-First-3D-Editor-in-Bevy/ . cargo new bevy tutorial editorcd bevy tutorial editor Replace Cargo.toml with: package name = "bevy tutorial editor"version = "0.1.0"edition = "2024" dependencies bevy = "=0.19" Bevy's recommended dev build profile.. profile.dev opt-level = 1 profile.dev.package." " opt-level = 3 Scene Setup Every 3D scene needs exactly three things to be visible: A camera , something to look through A light , something to illuminate the scene A mesh , something to look at Let’s start here and see where it leads. use bevy::prelude:: ;Entry pointEvery Bevy program starts the same way: build an App, register what it should do, then call run . The app then loops forever, ticking its systems each frame.fn main { App::new .add plugins DefaultPlugins +Pulls in ~20 built-in plugins at once: the window, the renderer, input handling, and asset loading. .add systems Startup, setup scene +Run setup scene a single time, at startup. .run ;}Systems are just functionsBevy runs this for you, you have to mention when it needs to be triggered. Also note we don't pass arguments when adding it as a system explained later .fn setup scene mut commands: Commands,+Lets you change the world, spawn entities player, enemy, objects and attach components to them. Bevy applies the changes once the system finishes. mut meshes: ResMut