Skip to content

[TF2] Add names to the vote controllers and add a dummy issue as the first issue in each vote controller#1157

Open
FlaminSarge wants to merge 1 commit intoValveSoftware:masterfrom
FlaminSarge:vote
Open

[TF2] Add names to the vote controllers and add a dummy issue as the first issue in each vote controller#1157
FlaminSarge wants to merge 1 commit intoValveSoftware:masterfrom
FlaminSarge:vote

Conversation

@FlaminSarge
Copy link
Copy Markdown
Contributor

Description

Some community mods relied on vote index 0 effectively being a no-op for custom vote handling.
Prior to the team-based vote_controller rework, issue index 0 would be KickIssue, which when triggered by a community mod, would no-op since the kick vote had no target set. However, after the rework, index 0 became RestartGame and these mods would accidentally trigger a game restart if they attempted to use index 0. Workarounds for the mods such as using an out-of-bound index also resulted in problems.

This PR adds a dummy issue as index 0 on all 3 vote controllers so that those mods may function again.
Other Source games with voting should add the same type of Dummy issue so that these community mods can function on those games as well.

It also adds names to each vote controller, and in a followup PR I plan to add VScript support to CVoteController.

…issue in each vote controller

Some community mods relied on vote index 0 for custom handling, but ever since KickIssue was removed from the global controller those mods would run into issues due to RestartGame being applied at the end of a custom vote
Generalisk added a commit to Generalisk/SourceSDK-Generalisk that referenced this pull request Dec 27, 2025
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.

1 participant