Repository navigation
en getting started first project
中文 | English | Docs | Repository
This page takes the shortest path to a running result: create a project, build a scene, add a light, attach a first script, and enter Play. You never have to leave the editor.
Editor and Launcher are already built, as described in Environment and Build.
Start the Launcher, choose to create a project, and provide a name, a disk location, and a template. The creation wizard:
- Creates the project directory plus
Assets/,ProjectSettings/, andUserSettings/. - Copies the selected template's
content/into the project. The built-in Empty Project template lives inApp/Assets/Templates/EmptyProjectand shipsAssets/Scripts/ExampleBehaviour.csandExampleBehaviour.lua. - Writes the
<Project>.nullusproject file.
Library/ is generated the first time the editor opens the project.
<Project>.nullus records startup-time options such as resolution, graphics backend, start scene, and whether threaded rendering is enabled. These are read while the editor and game start and cannot change at runtime. The full key list is in the Project Layout and Command Line reference.
Open the new project from the Launcher. The editor opens the last used scene, which is empty on first launch.
Check the status bar and title bar to confirm the active project before making changes, so edits do not land in a different project.
- Create a GameObject from the Hierarchy.
- Confirm in the Inspector that it already carries a
TransformComponent. - Add a
CameraComponentthrough the component selector and place the camera near the object. - Add a
LightComponent. When using a non-directional light, setRangeandOuterCutoff. - Adjust the Transform with the Scene View gizmo until the view makes sense.
If you need geometry, import a model or use GameObject.CreatePrimitive from a script. Import is covered in Models, Meshes, and Textures.
Save the scene. Scenes and Prefabs are stored as reflection-driven object graphs that include hierarchy and component fields; see Reflection and Serialization for the format.
Create a .cs file under the project's Assets directory deriving from Nullus.Behaviour:
using Nullus;
public sealed class Rotator : Behaviour
{
private void Awake()
{
Debug.Log("Rotator awake");
}
private void Update()
{
transform.Rotate(Vector3.up * (30.0f * Time.deltaTime));
}
}Saving triggers an incremental build through the asset watcher. On success the editor hot reloads at a frame boundary and preserves fields; on failure the previous working assembly keeps running and the error appears in the Console.
Attach the script to the GameObject and press Play. Stopping returns to edit mode.
Lua shares the same native object model and API manifest. A script returns a module table and the lifecycle functions are members of that table:
local Module = {}
function Module:Update()
local position = self.transform.localPosition
position.x = position.x + Nullus.Time.deltaTime
self.transform.localPosition = position
end
return ModuleNullus is the global API table exposed by the engine, for example Nullus.Time. Saving a .lua file needs no build step; it takes effect on the next run or reload. See C# versus Lua for the differences.
- Press Play. The Game View shows the runtime output while the Scene View keeps the editing camera.
- The Console collects script logs and errors.
- The Profiler panel shows Timeline or Tracy data when the matching build switches are on; see Profiling and Graphics Debugging.
| Path | Contents |
|---|---|
Assets/ |
Source assets and scripts |
ProjectSettings/ |
Project-level settings |
UserSettings/ |
Machine-local settings such as editor-settings.json
|
Library/ |
Import results, artifacts, thumbnail cache, and IDE workspace |
Library/ScriptApi/ScriptApi.json |
Merged scripting API manifest |
Library/ is rebuildable intermediate data and should not be committed.
- Editor Workspace makes the interface familiar.
- Scenes, GameObjects, and Components explains the object model.
- Scripting API Reference lists the available types and members.
Nullus Engine
中文
- 认识 Nullus
- 安装与快速入门
- 使用编辑器
- 场景与对象
- Prefab 工作流
- 资产与内容管线
- 渲染、材质与光照
- 大场景与资源管理
- 游戏逻辑与脚本
- 用户界面
- 动画与角色
- 物理与交互
- 音频、特效与媒体
- AI 与联网
- 平台、构建与发布
- 扩展与引擎架构
- 调试、性能与质量
- 参考手册
- 示例与发展路线
English
- Getting to Know Nullus
- Install and Quick Start
- Using the Editor
- Scenes and Objects
- Prefab Workflow
- Assets and Content Pipeline
- Rendering, Materials, and Lighting
- Large Scenes and Resource Management
- Gameplay and Scripting
- User Interface
- Animation and Characters
- Physics and Interaction
- Audio, Visual Effects, and Media
- AI and Networking
- Platforms, Builds, and Releases
- Extending the Engine
- Debugging, Performance, and Quality
- Reference
- Examples and Roadmap