Raised This Month: $51 Target: $400
 12% 

[TF2] Arena Scramble without use_queue


Post New Thread Reply   
 
Thread Tools Display Modes
Author
Powerlord
AlliedModders Donor
Join Date: Jun 2008
Location: Seduce Me!
Plugin ID:
4420
Plugin Version:
1.1.0
Plugin Category:
Gameplay
Plugin Game:
Team Fortress 2
Plugin Dependencies:
    Servers with this Plugin:
    4 
    Plugin Description:
    Allows TF2's arena streak scramble and scoring system to work when tf_arena_use_queue is set to 0
    Old 11-19-2014 , 23:30   [TF2] Arena Scramble without use_queue
    Reply With Quote #1

    So, if you've ever run an arena server with tf_arena_use_queue set to 0, you probably noticed that it doesn't scramble the teams. Ever.

    This plugin fixes that. Specifically, if re-implements the arena scoring and scramble system while having the queue disabled.

    How does it work

    When the arena win panel comes up, it checks if the number of rounds the winning team has is greater than the tf_arena_max_streak cvar. If it is, it tells the GameRules to scramble teams on the next round start.

    It also resets the losing team's score to 0.

    Both teams scores are set to 0 prior to the scramble.

    Prerequisities
    This plugin relies on SDKTools, so if that's not working for whatever reason, this plugin doesn't work.


    Installation instructions:
    1. Put tf2scramble.txt into addons/sourcemod/gamedata/
    2. Put tf2-arena-scramble.smx into addons/sourcemod/plugins/

    How to use
    Just install and go. This plugin will only activate when the map is arena and tf_arena_use_queue is set to 0.

    Compatibility
    This plugin should work correctly with the following plugins:
    • PropHunt Redux 3.4 (3.3 using DHooks for team switching... kinda works).
    • Huntsman Hell
    • Arena: Respawn
    • Resurrection
    • Arena: Reloaded
    • Dodgeball (all versions)

    It kinda works for PropHunt Redux without DHooks, but that's more if one kind of team wins 3 rounds in a row as PH doesn't switch team scores on its own.

    This plugin should not be used in conjunction with and/or doesn't really do anything with the following plugins:
    • GScramble
    • GScramble Redux
    • The Scramble Powerlord says he working on but hasn't touched for months.
    • Vs. Saxton Hale
    • Freak Fortress 2
    • Deathrun
    • The Hidden
    • Slender Fortress
    • Zombie Fortress

    Changelog
    • 1.1.0
      • The team names in the arena max streak scramble message are now correctly localized.
      • The plugin now uses SourceMod's score changing commands instead of manually manipulating the scores using the GameRules entity.
      • The timing for changing team scores on scramble now happens before the round start event is sent instead of after.
      • Updated gamedata for Passtime update.
    • 1.0.0
      • Initial release

    Known issues
    • The arena max streak isn't displayed in color like it is for Valve's version of the message. It's not clear why this is as the client is doing the translation itself.
    • tf_arena_use_queue is toggled on for a brief second while the Arena win panel is displayed. This is required in order to show the "playing to X rounds" bit on the win panel.
    Attached Files
    File Type: txt tf2scramble.txt (431 Bytes, 705 views)
    File Type: sp Get Plugin or Get Source (tf2-arena-scramble.sp - 1411 views - 10.3 KB)
    __________________
    Not currently working on SourceMod plugin development.

    Last edited by Powerlord; 02-02-2016 at 22:10.
    Powerlord is offline
    King Cnut
    Senior Member
    Join Date: Sep 2014
    Old 11-20-2014 , 13:30   Re: [TF2] Arena Scramble without use_queue
    Reply With Quote #2

    Nice
    __________________
    *tips fedora, unsheaths katana, teleports behind u, nods respectfully*

    Last edited by King Cnut; 03-22-2015 at 14:25.
    King Cnut is offline
    ClassicGuzzi
    Veteran Member
    Join Date: Oct 2013
    Location: Argentina
    Old 08-05-2015 , 19:28   Re: [TF2] Arena Scramble without use_queue
    Reply With Quote #3

    Did something changed in one of the latest updates? The scramble is not longer working in my dodgeball server (it says that teams were scrambled but nothing changed).
    __________________
    ClassicGuzzi is offline
    Powerlord
    AlliedModders Donor
    Join Date: Jun 2008
    Location: Seduce Me!
    Old 08-06-2015 , 04:28   Re: [TF2] Arena Scramble without use_queue
    Reply With Quote #4

    Quote:
    Originally Posted by ClassicGuzzi View Post
    Did something changed in one of the latest updates? The scramble is not longer working in my dodgeball server (it says that teams were scrambled but nothing changed).
    er... whoops, this needs a new gamedata file.
    Attached Files
    File Type: txt tf2scramble.txt (431 Bytes, 622 views)
    __________________
    Not currently working on SourceMod plugin development.
    Powerlord is offline
    Powerlord
    AlliedModders Donor
    Join Date: Jun 2008
    Location: Seduce Me!
    Old 08-25-2015 , 15:30   Re: [TF2] Arena Scramble without use_queue
    Reply With Quote #5

    Speaking of this plugin, I finally got around to testing a new version of it.

    Things changed in version 1.1:
    • The team names in the arena max streak scramble message are now correctly localized.
    • The plugin now uses SourceMod's score changing commands instead of manually manipulating the scores using the GameRules entity.
    • The timing for changing team scores on scramble now happens before the round start event is set instead of after.

    Note: This still uses the game's internal scramble method, which can be kinda terrible. Then again, if you're using GScramble, you don't need this plugin as it does its own scrambling even in arena.
    Attached Files
    File Type: sp Get Plugin or Get Source (tf2-arena-scramble.sp - 1152 views - 10.3 KB)
    File Type: txt tf2scramble.txt (431 Bytes, 646 views)
    __________________
    Not currently working on SourceMod plugin development.
    Powerlord is offline
    Powerlord
    AlliedModders Donor
    Join Date: Jun 2008
    Location: Seduce Me!
    Old 02-02-2016 , 22:10   Re: [TF2] Arena Scramble without use_queue
    Reply With Quote #6

    Yeeeah, I haven't checked gamedata for this recently, but it changed since August.
    Attached Files
    File Type: txt tf2scramble.txt (431 Bytes, 668 views)
    __________________
    Not currently working on SourceMod plugin development.
    Powerlord is offline
    Dragonisser
    AlliedModders Donor
    Join Date: Jan 2014
    Location: Germany
    Old 12-17-2022 , 07:54   Re: [TF2] Arena Scramble without use_queue
    Reply With Quote #7

    Latest gamedata after patch https://www.teamfortress.com/post.php?id=167251:

    Code:
    "Games"
    {
    	
    	"tf"
    	{
    		"Offsets"
    		
    		{
    			"CBasePlayer::ChangeTeam"
    			{
    				"windows"	"432"
    				"linux"		"431"
    			}
    
    			"CTeamplayRules::SetScrambleTeams"
    			{
    				"windows"	"169"
    				"linux"		"170"
    			}
    
    			"CTeamplayRules::ShouldScrambleTeams"
    			{
    				"windows"	"170"
    				"linux"		"171"
    			}
    
    			"CTeamplayRules::HandleScrambleTeams"
    			{
    				"windows"	"171"
    				"linux"		"172"
    			}
    		}
    	}
    }

    Last edited by Dragonisser; 12-17-2022 at 09:11.
    Dragonisser is offline
    Reply



    Posting Rules
    You may not post new threads
    You may not post replies
    You may not post attachments
    You may not edit your posts

    BB code is On
    Smilies are On
    [IMG] code is On
    HTML code is Off

    Forum Jump


    All times are GMT -4. The time now is 00:15.


    Powered by vBulletin®
    Copyright ©2000 - 2024, vBulletin Solutions, Inc.
    Theme made by Freecode