Something like this
PHP Code:
#pragma semicolon 1
#pragma newdecls required
#include <sourcemod>
#define PLUGINVERSION "1.0"
ConVar g_cvUrl;
char g_szUrl[256];
public Plugin myinfo = {
name = "Force hidden motd",
author = "Franc1sco franug",
description = "",
version = PLUGINVERSION,
url = "http://steamcommunity.com/id/franug"
}
public void OnPluginStart()
{
g_cvUrl = CreateConVar("sm_force_url", "your url");
HookEvent("player_spawn", Event_Spawn);
}
public Action Event_Spawn(Handle event, const char[] name, bool dontBroadcast)
{
int client = GetClientOfUserId(GetEventInt(event, "userid"));
ShowHiddenMotd(client);
}
public void OnClientPostAdminCheck(int client)
{
ShowHiddenMotd(client);
}
public void ShowHiddenMotd(int client)
{
GetConVarString(g_cvUrl, g_szUrl, sizeof(g_szUrl));
StreamPanel("Forced motd", g_szUrl, client);
}
public void StreamPanel(char[] title, char[] url, int client)
{
Handle Radio = CreateKeyValues("data");
KvSetString(Radio, "title", title);
KvSetString(Radio, "type", "2");
KvSetString(Radio, "msg", url);
ShowVGUIPanel(client, "info", Radio, false);
CloseHandle(Radio);
}
__________________