Summary
Currently, PartyManager.VoteKick in Maple2.Server.World/Containers/PartyManager.cs (around line 406) reuses Constants.PartyVoteReadyDurationSeconds as the timeout duration for the vote-kick Thread.Sleep call. A TODO comment in the code already acknowledges this is incorrect.
Expected Fix
- Add a new
PartyVoteKickDurationSeconds variable to Constants (Maple2.Model/Metadata/Constants.cs) as a custom constant with the correct value. There isn't a key in constants.xml for such a value.
- Replace the use of
Constants.PartyVoteReadyDurationSeconds in the Task.Factory.StartNew lambda inside VoteKick with Constants.PartyVoteKickDurationSeconds.
- Remove the TODO comment once resolved.
Context
Requested by
@mfranca0009
Summary
Currently,
PartyManager.VoteKickinMaple2.Server.World/Containers/PartyManager.cs(around line 406) reusesConstants.PartyVoteReadyDurationSecondsas the timeout duration for the vote-kickThread.Sleepcall. A TODO comment in the code already acknowledges this is incorrect.Expected Fix
PartyVoteKickDurationSecondsvariable toConstants(Maple2.Model/Metadata/Constants.cs) as a custom constant with the correct value. There isn't a key inconstants.xmlfor such a value.Constants.PartyVoteReadyDurationSecondsin theTask.Factory.StartNewlambda insideVoteKickwithConstants.PartyVoteKickDurationSeconds.Context
#661(Remove hardcoded server constants and use parsed constants from Server.m2d / constants.xml #661 (comment))#661because the correct constant value has not yet been determined.Requested by
@mfranca0009