feat: game/engine split refactor + skybox
This commit is contained in:
parent
581e5892b0
commit
eeedcb8e48
34 changed files with 610 additions and 218 deletions
|
|
@ -2,10 +2,11 @@ import { Framebuffer } from "../engine/render/Framebuffer"
|
|||
import type { RenderConfig } from "../engine/render/RenderConfig"
|
||||
import type { Mat4 } from "../engine/math/Mat4"
|
||||
import type { Camera } from "../engine/scene/Camera"
|
||||
import { MOB_KINDS } from "../engine/scene/Mob"
|
||||
import { renderBand, MOB_FLOATS, type MobDraw, type Scene } from "./renderScene"
|
||||
import { MOB_KINDS } from "../game/actors/Mob"
|
||||
import { renderBand, MOB_FLOATS, type MobDraw, type Scene } from "../game/renderScene"
|
||||
|
||||
/** Sky is drawn at 1/SKY_STEP resolution; band splits align to it. */
|
||||
/** Clouds are drawn at 1/SKY_STEP resolution (the sky base + sun stay per-pixel);
|
||||
* band splits align to it so the cloud block grid stays seamless across workers. */
|
||||
const SKY_STEP = 2
|
||||
/** Use worker threads when the page can share memory (else single-thread). */
|
||||
const ENABLE_WORKERS = true
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue