Raised This Month: $95 Target: $400

GameDescription changer

Post New Thread Reply   
Thread Tools Display Modes
Author Message
New Member
Join Date: Mar 2012
Old 03-15-2012 , 14:33   GameDescription changer
Reply With Quote #1

Hi, i found this on the internet, but its not working, so if anyone can help I'd appreciate it. Thx.

 * SourceMod Hosties Project
 * by: databomb & dataviruset
 * This file is part of the SM Hosties project.
 * This program is free software; you can redistribute it and/or modify it under
 * the terms of the GNU General Public License, version 3.0, as published by the
 * Free Software Foundation.
 * This program is distributed in the hope that it will be useful, but WITHOUT
 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
 * FOR A PARTICULAR PURPOSE.  See the GNU General Public License for more
 * details.
 * You should have received a copy of the GNU General Public License along with
 * this program.  If not, see <http://www.gnu.org/licenses/>.

#include <sourcemod>
#include <cstrike>
#include <sdkhooks>
#include <hosties>

// this looks like it's largely from psychonic, so thanks to him!
new bool:g_bIsMapLoaded = false;
new Handle:gH_Cvar_GameDescriptionOn = INVALID_HANDLE;
new bool:gShadow_GameDescriptionOn;
new Handle:gH_Cvar_GameDescriptionTag = INVALID_HANDLE;
new String:gShadow_GameDescriptionTag[64];

    gH_Cvar_GameDescriptionOn = CreateConVar("sm_hosties_override_gamedesc", "1", "Enable or disable an override of the game description (standard Counter-Strike: Source, override to Hosties/jailbreak): 0 - disable, 1 - enable", FCVAR_PLUGIN, true, 0.0, true, 1.0);
    gShadow_GameDescriptionOn = true;
    gH_Cvar_GameDescriptionTag = CreateConVar("sm_hosties_gamedesc_tag", "Hosties/Jailbreak v2", "Sets the game description tag.", FCVAR_PLUGIN);
    Format(gShadow_GameDescriptionTag, sizeof(gShadow_GameDescriptionTag), "Hosties/Jailbreak v2");
    HookConVarChange(gH_Cvar_GameDescriptionOn, GameDescription_CvarChanged);
    HookConVarChange(gH_Cvar_GameDescriptionTag, GameDescription_CvarChanged);

public GameDescription_CvarChanged(Handle:cvar, const String:oldValue[], const String:newValue[])
    if (cvar == gH_Cvar_GameDescriptionOn)
        gShadow_GameDescriptionOn = bool:StringToInt(newValue);
    else if (cvar == gH_Cvar_GameDescriptionTag)
        Format(gShadow_GameDescriptionTag, sizeof(gShadow_GameDescriptionTag), newValue);

    gShadow_GameDescriptionOn = GetConVarBool(gH_Cvar_GameDescriptionOn);
    GetConVarString(gH_Cvar_GameDescriptionTag, gShadow_GameDescriptionTag, sizeof(gShadow_GameDescriptionTag));

    g_bIsMapLoaded = true;

    g_bIsMapLoaded = false;

public Action:OnGetGameDescription(String:gameDesc[64])
    if (gShadow_GameDescriptionOn && g_bIsMapLoaded)
        strcopy(gameDesc, sizeof(gameDesc), gShadow_GameDescriptionTag);
        return Plugin_Changed;

    return Plugin_Continue;

Last edited by Void53; 03-15-2012 at 14:33.
Void53 is offline
Senior Member
Join Date: Jun 2008
Location: Grenoble, France
Old 03-15-2012 , 15:02   Re: GameDescription changer
Reply With Quote #2

Flyflo is offline
Join Date: Mar 2011
Location: Slovakia
Old 03-15-2012 , 15:33   Re: GameDescription changer
Reply With Quote #3

Flyflo it doesn't work for me... ;(
viRR is offline
Send a message via Skype™ to viRR
Join Date: Feb 2012
Old 03-15-2012 , 15:34   Re: GameDescription changer
Reply With Quote #4

Install SteamTools?
mau5 is offline
AlliedModders Donor
Join Date: Jun 2008
Location: Seduce Me!
Old 03-15-2012 , 15:54   Re: GameDescription changer
Reply With Quote #5

Originally Posted by mau5 View Post
Install SteamTools?
And just to be helpful, here's a link to SteamTools.
Am I back? Well, we'll see.

Last edited by Powerlord; 03-15-2012 at 16:05.
Powerlord is offline

Thread Tools
Display Modes

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 11:20.

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