Bannerlord-Coop-Team / BannerlordCoop

MIT License
268 stars 51 forks source link

799 sync militia party component #998

Open georgyrudnev opened 1 month ago

georgyrudnev commented 1 month ago

PR Checklist

Please check if your PR fulfills the following requirements:

PR Type

What kind of change does this PR introduce?

What is the current behavior?

Settlement property inside MilitiaPartyComponent is not synced

What is the new behavior?

Resolves #799

Sync´s Settlement property inside militiaPartyComponent which seems to only be set during ctor

Other information

georgyrudnev commented 1 month ago

MilitiaPartyComponent constructor on the server is not triggering the Settlement property setter patch as expected. Client-side instance creation skipping the constructor is working as designed. Issue lies in serveside behavior, where the settlemt property setter should be called during construction triggering our prefix patch for syncing the property. This is not happening preventing proper synchronization of the Settlement property to clients. Need to investigate why server-side setter is not triggering our patch during the component's construction.

garrettluskey commented 2 weeks ago

Anyway to use autosync instead?