Skip to content

Stack/02 vob loading#369

Merged
JucanAndreiDaniel merged 3 commits into
mainfrom
stack/02-vob-loading
Jun 14, 2026
Merged

Stack/02 vob loading#369
JucanAndreiDaniel merged 3 commits into
mainfrom
stack/02-vob-loading

Conversation

@JucanAndreiDaniel

Copy link
Copy Markdown
Contributor

Summary

Reduces VOB lazy-init overhead and fixes bed VOBs spawning the wrong prefab.

Changes

  • Queue dedup — replaces the O(n) Queue.Contains() guard with a per-loader IsQueued flag; the init queue is batch-drained (10/frame), skips entries destroyed in the meantime, and is cleared on world change so stale entries from the previous world are dropped.
  • Bed prefab routingoCMobDoor VOBs whose visual name starts with BED_ now resolve the VobBed prefab instead of VobDoor.

How to test

  • Load a populated world and confirm VOBs stream in without the previous Contains() hitch; Should load the vobs faster.
  • go near a bed and check that you don't get spammed with errors regarding door locks

@JucanAndreiDaniel JucanAndreiDaniel self-assigned this Jun 13, 2026
Base automatically changed from stack/01-fixes-standalone to main June 14, 2026 08:44

@JaXt0r JaXt0r left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

    private const int VobInitBatchSize = 10;

--> Does it mean we load max 10 vobs per frame?

@JucanAndreiDaniel

Copy link
Copy Markdown
Contributor Author
    private const int VobInitBatchSize = 10;

--> Does it mean we load max 10 vobs per frame?

yes, but it's fast on quest as well
the reason for this thing is to load faster (before was sequential)

Replaces the O(n) Queue.Contains() guard with a per-loader IsQueued flag, batch-drains the queue (10/frame) skipping destroyed entries, and clears pending entries on world change.
oCMobDoor VOBs whose visual name starts with BED_ now resolve the VobBed prefab instead of VobDoor.
Foveated rendering at max level, symmetric projection and SustainedHigh hints for Quest-class headsets.
@JucanAndreiDaniel JucanAndreiDaniel marked this pull request as ready for review June 14, 2026 08:50
@JucanAndreiDaniel JucanAndreiDaniel merged commit c3f453b into main Jun 14, 2026
@JucanAndreiDaniel JucanAndreiDaniel deleted the stack/02-vob-loading branch June 14, 2026 08:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants