Skip to content
This repository has been archived by the owner on Oct 20, 2021. It is now read-only.

Worker connector updates & refactoring #271

Merged
merged 7 commits into from
May 21, 2020

Conversation

jamiebrynes7
Copy link
Contributor

@jamiebrynes7 jamiebrynes7 commented May 19, 2020

Description

Updated the WorkerConnector implementations with these spatialos/gdk-for-unity#1365 changes. Additionally made all the map building use Task rather than coroutines and did some refactoring.

Tests

  • Ran it locally
  • Release QA pipeline
  • Test built out client

Documentation

  • Changelog

@improbable-prow-robot improbable-prow-robot added jira/no-ticket Indicates a PR has no corresponding JIRA ticket size/XL Denotes a PR that changes 300-599 lines, ignoring generated files. labels May 19, 2020
@jamiebrynes7 jamiebrynes7 force-pushed the chore/worker-connector-updates branch from dc312a3 to 15dd524 Compare May 19, 2020 15:34
}

protected int GetWorldSize()
protected async Task WaitForWorkerFlags(CancellationToken token, params string[] flagKeys)
Copy link
Contributor

Choose a reason for hiding this comment

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

This looks like it is worth integrating into the core later?

Copy link
Contributor Author

@jamiebrynes7 jamiebrynes7 May 19, 2020

Choose a reason for hiding this comment

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

Its worth a shout, or even a:

public Task<string> GetWorkerFlagAsync(string key, CancellationToken token);

Then you can compose them:

var flags = await Task.WhenAll(Worker.GetWorkerFlagAsync("first", token), Worker.GetWorkerFlagAsync("second", token)); // Returns ["first_value", "second_value"]

@zeroZshadow
Copy link
Contributor

Random through, does the map generator still work in the editor with this? Not when playing.

@jamiebrynes7
Copy link
Contributor Author

Random through, does the map generator still work in the editor with this? Not when playing.

Yup - just tested with a map w/ 200 tile layers, Editor pauses for a few seconds and then completes fine

@jamiebrynes7 jamiebrynes7 force-pushed the chore/worker-connector-updates branch from 3e8f37c to fc09b7b Compare May 21, 2020 10:47
@jamiebrynes7
Copy link
Contributor Author

Everything looked good on the quick playtest! 📈

@jamiebrynes7 jamiebrynes7 merged commit bbe216f into develop May 21, 2020
@improbable-prow-robot improbable-prow-robot deleted the chore/worker-connector-updates branch May 21, 2020 12:28
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
jira/no-ticket Indicates a PR has no corresponding JIRA ticket size/XL Denotes a PR that changes 300-599 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants