Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions __init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -219,6 +219,11 @@ class Fast64Settings_Properties(bpy.types.PropertyGroup):

internal_game_update_ver: bpy.props.IntProperty(default=0)

internal_background_mode: bpy.props.BoolProperty(
default=False,
description="Used to disable certain parts of the codebase when Fast64 is ran with Blender in CLI mode",
)

def to_repo_settings(self):
data = {}
data["autoLoad"] = self.auto_repo_load_settings
Expand Down
5 changes: 4 additions & 1 deletion fast64_internal/utility.py
Original file line number Diff line number Diff line change
Expand Up @@ -155,7 +155,10 @@ def unhideAllAndGetHiddenState(scene):

if bpy.context.mode != "OBJECT":
bpy.ops.object.mode_set(mode="OBJECT")
bpy.ops.object.hide_view_clear()

if not scene.fast64.settings.internal_background_mode:
# the viewport is disabled when blender is ran in background mode, so we need to disable this to avoid errors
bpy.ops.object.hide_view_clear()

hiddenLayerCols = []

Expand Down