How to work with parallel luau when using single script architecture

Im a beginner in using this architecture so I wouldn’t know much yet but I was wondering how you might use parallel luau with this architecture since modules can only run in parallel if the script that required the module is parented under an actor.

Single Script Architecture (SSA): using one server script and one local script with lots of modules

Make an exception when it comes to Actors and just place a regular script in them

1 Like

have the main thread clone itself at runtime and place those into individual actors.

I don’t get what you mean. Whats main thread?

main script, the single script in question

guessing this is what you mean

local actor = Instance.new("Actor")
local cloned = script:Clone()

cloned.Parent = actor
actor.Parent = script.Parent

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.