Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Blocking Event Manager #660

Merged
merged 6 commits into from
Jan 26, 2025
Merged

Blocking Event Manager #660

merged 6 commits into from
Jan 26, 2025

Conversation

g-mason0
Copy link
Contributor

@g-mason0 g-mason0 commented Jan 24, 2025

I have created this tool that can be used to simply for the logic that is abstracted inside of the run() method of the Script.java class.

Inside of the Microbot class we initialize the BlockingEventManager, which inside of the constructor of the BlockingEventManager will add the events into the list.

From there, I have removed the majority of the logic inside of the run() method to be contained inside of these events that will be looped over.

It is required to synchronize the BlockingEventManager.class in-order to ensure that multiple threads to do not attempt to execute these events at the same time.

I figured it would be easier to just show you all the code instead of just sending the snippets you've already seen via Discord

@FireStarter-Instigator
Copy link
Contributor

"It is required to synchronize the BlockingEventManager.class in-order to ensure that multiple threads to do attempt to execute these events at the same time."

Typo? What mean

@g-mason0 g-mason0 requested a review from chsami January 25, 2025 21:47
@chsami chsami merged commit 4dafb6c into chsami:development Jan 26, 2025
1 check passed
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.

3 participants