Skip to content

Add dedicated PartyVoteKickDurationSeconds constant for vote-kick timeout #667

@mfranca0009

Description

@mfranca0009

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

  1. 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.
  2. Replace the use of Constants.PartyVoteReadyDurationSeconds in the Task.Factory.StartNew lambda inside VoteKick with Constants.PartyVoteKickDurationSeconds.
  3. Remove the TODO comment once resolved.

Context

Requested by

@mfranca0009

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions