Hey, I have a question, that you also may have while working on larger projects specifically multi-threaded projects, my question is, how do we make data exchange between multiple or two or more threads, more specifically, if one thread is alloted for custom event triggering, and others for some other purposes, such as custom gui scaling handling, server-client IO handling, then suppose, the thread that handles gui want to send some info like gui settings to server-client IO thread, then how would I achieve it? using BindableEvent/Function doesn’t work.
And Using values like IntValue, NumberValue, StringValue Has latency issues, Any better way in your mind? Please specify.
Are you using Actors? If you are, you should be able to pass data through a RemoteEvent BindableEvent when you desynchronize. Regarding Value objects, it depends on what type of data you’re storing in there, but the time it takes to read and write them is usually non-negligible. There might still be some replication time from client to server depending on the users ping, so make sure to add buffer times so that higher ping users can have a good experience
That Client-Server IO was just for an example, I mean how can i transfer data from two threads on the same machine
You can use bindable events to achieve your use case
No, bindable Events Throw An Error
Bindable events are used to send data across 2 of the same scripts e.g server to server
Remote events are used to send data across 2 different types of scripts e.g server to client
I am saying that bindable Event throws error when used in parrelel
Unfortunately I’m not the best at Parallel Luau to give you any code, but there’s already documentation for your issue.
Give it a read.