360 Secure SkillHub
360 安全技能中心

roblox-building

该 Skill 提供 Roblox 世界搭建与灯光调试流程,包括几何/地图/道具/地形、EditableMesh 预算、碰撞与资产检查,以及光照、氛围和后处理参数排错;依赖 Roblox Studio MCP 执行构建。

分类:创作
TabooHarmony
热度 31.52
最近更新 2026-12-01 11:24:34

安装

发给 Agent
帮我安装这个技能:npx secure-skills-cli add tabooharmony/roblox-brain/roblox-building
兼容性
通用兼容
联网要求
联网要求未确认
数据出网
可选出网
Metadata
name
roblox-building
description
Use when building, fixing or reviewing Roblox worlds: geometry, maps, props, generated assets, lighting, atmosphere and post effects.
when_to_use
Also for map gaps, z-fighting, wrong scale, players escaping the map, store assets with hidden scripts, EditableMesh budget errors, a scene that looks flat, too dark or washed out, wrong shadows, or lighting hurting mobile.
last_reviewed
"2026-11-29T00:00:00.000Z"
sources
["original","https://raw.githubusercontent.com/Roblox/creator-docs/main/content/en-us/parts/meshes.md","https://raw.githubusercontent.com/Roblox/creator-docs/main/content/en-us/parts/solid-modeling.md","https://raw.githubusercontent.com/Roblox/creator-docs/main/content/en-us/parts/procedural-models.md","https://raw.githubusercontent.com/Roblox/creator-docs/main/content/en-us/parts/custom-terrain-materials.md","https://raw.githubusercontent.com/Roblox/creator-docs/main/content/en-us/environment/lighting.md","https://raw.githubusercontent.com/Roblox/creator-docs/main/content/en-us/environment/atmosphere.md","https://raw.githubusercontent.com/Roblox/creator-docs/main/content/en-us/environment/post-processing-effects.md","https://raw.githubusercontent.com/Roblox/creator-docs/main/content/en-us/effects/light-sources.md","https://create.roblox.com/docs/reference/engine/classes/Lighting","https://create.roblox.com/docs/reference/engine/classes/ColorGradingEffect","https://create.roblox.com/docs/reference/engine/classes/EditableMesh","https://create.roblox.com/docs/scripting/security/third-party-vulnerabilities","https://devforum.roblox.com/t/full-release-quad-support-for-editablemesh-apis/4890142/44"]

Roblox Building and Lighting

When to Load

Building, fixing or reviewing world geometry, maps, props, generated or store assets, terrain, lighting, atmosphere or post-processing. Draw calls, triangle and memory budgets: roblox-performance; constraints, assemblies, rig joints in motion: roblox-physics; the full Studio MCP tool list and session rules: roblox-studio-mcp.

"Field case" = measured in one of the owner's projects; verify on your content.

Traps (symptom -> cause -> fix)

  • Flicker where two faces meet -> coplanar overlap; even 0.005 studs apart flickered (field case). Inset one face of each overlapping pair by about 0.01 studs; CSG cutters overshoot the cut surface by about 0.05 per side.
  • Hairline gaps between parts -> arbitrary decimals (0.333, 1.17) compounding. Snap sizes and offsets to 0.125/0.25/0.5 and offset sub-parts from an anchor part's CFrame, never from guessed world coordinates.
  • Players walk through, get stuck in, or escape the map -> visible mesh used as collision. CollisionFidelity is never 1:1 (PreciseConvexDecomposition is closest and costliest; Box is a bounding box, Hull fills cavities). On low-poly mesh maps set meshes CanCollide/CanQuery false and put invisible box/wedge Parts under anything sticking out 0.5 studs or more. Walk every gate on the path before handover.
  • Props slide off shelves or piles collapse seconds after play -> anchored only the base (a quarter of a pile slid, field case). Anchor display props; record what each rests on (an attribute) so breaking the support can release them.
  • "No scripts" store pack ships scripts -> descriptions aren't evidence (packs said "No scripts" and held 6-8 scripts plus audio, field case). Read the whole inserted hierarchy and the script flag before play; third-party models can carry backdoors. Paid or cross-owner assets: show creator, ID, price and rights and get consent before insert_asset. Store ProceduralModels are inserted with their generator module sandboxed.
  • Gameplay mesh build fails ("EditableMesh budget is full") -> static decor ate the per-device editable budget (eleven decor props broke a core action, field case). Upload meshes that never change; see §2.
  • Rotated model "didn't move" -> Model:GetBoundingBox is oriented to the pivot. Measure world extents from part corners. CFrame.Angles(0, t, 0).LookVector = (-sin t, 0, -cos t), so a -Z-front model faces +X at t = -pi/2.
  • Props float or sink on smooth terrain -> raycasts miss terrain written the same frame, and the visible surface sat 1-1.5 studs above the written occupancy (field case). Wait a frame, place on a raycast hit, tilt to its normal.
  • Room burns white -> lamp pools add up: 32 PointLights at Brightness 1.5 blew a room out; 0.25 with Range 16 read right (field case). Ported lamp data often lists several bulbs per fixture: merge bulbs within ~2 studs. Neon at ordinary bright colours blooms to near-white; keep hue with dark values (45,70,120).
  • Roofed interior turns blue or dark -> ClockTime still tints fully roofed rooms (14.5 -> 17.4 turned one blue, field case). Leave it; tune Ambient and one ColorCorrectionEffect.
  • Metal and smooth surfaces look flat -> EnvironmentDiffuseScale and EnvironmentSpecularScale default to 0 in the API. Raise them (specular makes smooth objects reflect the sky) and lower Ambient/OutdoorAmbient to match.
  • ShadowSoftness does nothing -> it applies only with LightingStyle = Realistic and shadow-map-capable devices.
  • Effect missing in Studio or on phones -> some post effects hide at lower quality levels. Preview at the lowest and highest Editor Quality Level (Studio Settings -> Rendering) before tuning; if raising quality shows more scene, check StreamingTargetRadius first.
  • Colour grading change ignored -> only the most recently parented ColorGradingEffect under Lighting applies (ignored elsewhere); post effects under Camera show only to that player.

Limits

Thing Value
Default avatar ~5 studs tall, eye ~4.5; door 4x7, path 6+
Light Range clamped to 120 studs (ExtendLightRangeTo120 is unused)
Draw distance at lowest quality at least 500 studs
EditableMesh (growable) 60,000 vertices, 20,000 triangles; a quad counts as 2
Editable meshes per client ~8 growable at once (field case); 300 fixed-size copies fit
CreateMeshPartAsync ~44 ms per call regardless of size; collision rebuild 15-19 ms vs 0.5 ms visual (field case)
Mesh map groups split any group over 20,000 triangles
Custom terrain slots SetMaterialSlot 2-63 (0 Air, 1 Water)

1. Studio MCP building workflow

Tool map: roblox-studio-mcp.

  • Every execute_luau call is stateless: re-find the build root at the top of each call. Read positions and sizes back from Workspace; never take coordinates from chat history.
  • Name the root, origin and dimensions; build one bounded phase at a time and read the target back (bounds, anchoring, collision) before the next. A timeout or Unknown error may have run: read back before retrying.
  • Prefer search_asset/insert_asset for common props (store-asset trap above). Generators: generate_procedural_model (primitive-part props, buildings, blockouts; pass meaningful partNames; may auto-insert), generate_mesh (one textured mesh; bound size and triangles), generate_material (apply and read back the returned variant name), generate_texture (re-texture a selected mesh), generate_scene (fills a bounding box). If a job ID comes back, call wait_job_finished before dependent edits.
  • Generated or inserted art is a candidate: look at it from top, bottom and the facing side; triangle counts don't show a wrong shape. Blank texture or invisible mesh: asset privacy grant (roblox-studio-mcp).
  • Don't promise a runtime script can repair MeshId (not script-accessible) or SurfaceAppearance ColorMap (plugin-only); fix at import. MaterialVariant.ColorMap is also plugin-only: keep runtime texture ids in your own data.

2. EditableMesh and EditableImage (field-measured, Studio 2026-11)

  • A MeshPart built from an EditableMesh keeps referencing it. After editableMesh:Destroy(), that MeshPart's mesh reads back 0 vertices. Destroy the mesh only after the MeshPart; displayed meshes keep counting against the budget.
  • Build growable, then copy fixed-size: CreateEditableMeshAsync(Content.fromObject(mesh), { FixedSize = true }), then destroy the growable one. Fixed-size allows position/colour edits, not topology; Clear() throws on it. Many MeshParts can share one mesh (CreateMeshPartAsync twice or :Clone()).
  • AddFace(v1, v2, v3[, v4]) takes separate IDs since release 745 (was an array); quads reached live games in 2026-11. Use BatchAdd(Enum.MeshAttribute.X, data) and BatchSetValues(ids, values) for bulk edits; batching cuts call overhead, not limits.
  • IDs are stable but unordered with holes: iterate GetVertices()/GetFaces(), never 1..count. Re-derive collision once at the end of an edit, not per hit.
  • RaycastLocal(origin, direction) uses the direction's length and hits back faces: start outside, keep hits whose face faces the ray.
  • A MeshPart stretches its mesh to Size: after edits set Size = mesh:GetSize() and offset by GetCenter(). Centre fixed-size vertices on the part origin.
  • CreateMeshPartAsync defaults to Plastic (grain over vertex colours): use SmoothPlastic. Runtime EditableMesh MeshParts cast no shadow in Studio even with CastShadow = true; check a live client.
  • AssetService:CreateDecalAsync takes only Content.fromObject(editableImage) maps and returns an unparented Decal. PromptCreatePlatformContentAsync(player, image, Enum.AssetType.Image) (server) replaces the removed PromptCreateAssetAsync.
  • Published games need a 13+ ID-verified creator and "Allow Mesh / Image APIs" on; editables don't replicate.

3. Lighting engine state (creator-docs, 2026-11)

  • Lighting.Technology is deprecated and not scriptable (read and write locked; the Future/ShadowMap/Voxel/Compatibility enum remains). Its successors: LightingStyle (Realistic or Soft, the flat retro look) and PrioritizeLightingQuality (true keeps shadows and shaders up close as quality drops, false keeps view distance). The shadow path depends on both: Soft with PrioritizeLightingQuality uses shadow maps, not voxel lighting. API metadata lists both as script-writable while the light-sources guide says Properties window only: set them in Studio and test before switching at runtime. Check on a phone at low quality.
  • Atmosphere vs sky: a low Offset lets the skybox show through objects and terrain; balance it against Density, which also hides the sky seen through geometry.
  • ColorGradingEffect.TonemapperPreset: Retro mimics pre-2019 lighting and washes out light colours (field case); exposure changes did nothing while grading was on.
  • Decal/Texture emissive mask: EmissiveMaskContent, EmissiveStrength (0 off, high values clamp to white) and EmissiveTint make a decal glow without a light.
  • Sky.SkyboxLf faced +X and SkyboxRt -X in one project (field case): verify generated faces with a direction-grid debug render.
  • Expanded Terrain (per place, off by default) gives up to 62 custom terrain materials through Terrain:SetMaterialSlot; a deleted in-use material paints terrain purple, and terrain thinner than 16 voxels can vanish on clients with a small streaming radius.