View Single Post
Author Message
llamasking
Junior Member
Join Date: Jul 2020
Old 09-15-2020 , 16:08   [TF2] Workshop Vote (v1.2.0-1 2022-12-04)
Reply With Quote #1

Description
Allows players to call votes to change to workshop maps.

Commands
  • [various commands below] <workshop id> - Call a vote to change to a workshop map.
    • sm_workshop
    • sm_workshopmap
    • sm_wsmap
    • sm_wsvote
    • sm_wsm
    • sm_ws
  • sm_cmap / sm_currentmap - Shows information about the current map. Identical to the join notification on workshop maps, but also works on builtin maps.

ConVars
  • sm_workshop_min_subs - The minimum number of current subscribers for a workshop map. (Default: 50)
  • sm_workshop_delay - The delay between the vote passing and the map changing. (Default: 10)
  • sm_workshop_notify - Whether or not to notify joining players about the map's Workshop name and ID. Only notifies players if the map is not stock. (Default: True)
  • sm_workshop_notify_delay - How many seconds to wait after a client joins before notifying them. (Default: 60)
  • sm_workshop_version - Plugin version.

Dependencies
  • NativeVotes - I use and recommend Steph's NativeVotes fork here.
  • SteamWorks - Used to access the SteamAPI.
  • [Optional] Updater - Automatic updates.
  • [Compile] Multi Colors - Only worry about this if you want to compile your own version of the plugin.

Changelog
Spoiler


Credits
  • Sikari and Impact on the AM Discord - Feedback on the first revision of my code.
  • dustinandband - I referenced his code when figuring out how to use NativeVotes.

Note: Due to the NativeVotes and Updater requirements, "Get Plugin" doesn't work. Please use the attached .smx file.
Attached Files
File Type: smx wsvote.smx (17.0 KB, 40 views)
File Type: sp Get Plugin or Get Source (wsvote.sp - 26 views - 17.0 KB)
__________________

Last edited by llamasking; 04-06-2024 at 22:54. Reason: v1.2.0-1
llamasking is offline