Jump to content

HL2 Redirect URL


Recommended Posts

I have Sourcersc for all the hl2 redirects and a config file that installs it as a secondary gaming service, which installs like an extra server.

The client uploads his/her extras to the server, then starts the secondary and it will compress and upload to the redirect through FTP.

This works pretty good, but of course the client cannot see the progress and know when it is done.


Luis gave me the following to work with



Dim pageTitle As String = "Update Fast Download"
Dim stopGameServer As Boolean = False
Dim relativePath As String = ""
Dim command As String = "cd %path%\SourceRSC" + vbnewline + "%path%\SourceRSC\SourceRSC.exe"
Dim startMessage As String = "Updating fast download...<br>"
Dim endMessage As String = "Fast download has been updated.<br>You can close this window."


Response.Write("<!DOCTYPE HTML PUBLIC ""-//W3C//DTD HTML 4.0 Transitional//EN"">")
Response.Write("<HTML><TITLE>" & pageTitle & "</TITLE><BODY bgcolor=""#000000""><font face=""Lucida Console"" size=""2"" color=""#FFFFFF"">")

If TCAdminSDK.Web.Session.IsAuthenticated Then
Dim serviceid As String = Request.QueryString("serviceid")
Dim service As New TCAdminSDK.Objects.Service
service.ServiceID = serviceid
If service.Find Then

Dim path As String = System.IO.Path.Combine(service.AutomationFilesPath, relativePath)
command = command.Replace("%path%", path)


If service.UserID = TCAdminSDK.Web.Session.CurrentUser Or TCAdminSDK.Web.Session.CurrentUserType = TCAdminSDK.Objects.UserType.Admin Or TCAdminSDK.Web.Session.CurrentUserType = TCAdminSDK.Objects.UserType.SubAdmin Then

Dim serviceWasRunning As Boolean = False
If stopGameServer And service.CurrentStatus = TCAdminSDK.Objects.ServiceStatus.Running Then
Response.Write("Stopping the game server...")

serviceWasRunning = True
End If

Dim serverplugin As TCAdminBase.Plugins.IGenericPlugIn = TCAdminSDK.Remote.InstanceCreator.GetPluginFromServer(service.ServerID, "TCAdminMonitor.StandardPlugins.RemoteServers.ServerUtilities")
serverplugin.Execute(New Object() {"ExecuteScript", service.WorkingDirectory, command})

If serviceWasRunning Then
Response.Write("Starting the game server...")
End If
End If

End If
End If



I would like to have this as a Custom link button for them to click with a popup window just like HLDSupdatetool so they can see the progress.


Any help would be appreciated.

Thank you

Link to comment
Share on other sites

I got this 'almost' working,



I created a custom link with the following url :

javascript: void OpenConsoleWindow('/sourcersc.aspx?serviceid=%serviceid%')


and placed sourcersc.aspx into Program Files\TCAdmin Control Panel\Web on my master server


I edited the path for the exe, everything works pretty good but the page ends with the following :


Your fast downloads are being synchronized with your game server files, this process can last a few minutes depending of the amount and size of files to synchronize, please wait...



Server Error in '/' Application.

Runtime Error

Description: An application error occurred on the server. The current custom error settings for this application prevent the details of the application error from being viewed remotely (for security reasons). It could, however, be viewed by browsers running on the local server machine.


Details: To enable the details of this specific error message to be viewable on remote machines, please create a <customErrors> tag within a "web.config" configuration file located in the root directory of the current web application. This <customErrors> tag should then have its "mode" attribute set to "Off".


<!-- Web.Config Configuration File -->




<customErrors mode="Off"/>





Notes: The current error page you are seeing can be replaced by a custom error page by modifying the "defaultRedirect" attribute of the application's <customErrors> configuration tag to point to a custom error page URL.


<!-- Web.Config Configuration File -->




<customErrors mode="RemoteOnly" defaultRedirect="mycustompage.htm"/>




I assume I will have to turn on error messages to check whats wrong.



Note that apart from this it seems to be working as I got the files compressed and synchronized on my fast download space.

Link to comment
Share on other sites

Guest louise

Contact http://www.brainless.us/forum Masher via the forums

If you using this in your business you are breaking the licence terms


he can supply you a version that is without the press any key to continue for a cost for a commercial licence and the edit


for your code above it may still time out if it is a long install, you will need to change



+ "


this this

+ "start


if you want the console to auto close add a java script at the bottom of your file

Link to comment
Share on other sites


This topic is now archived and is closed to further replies.

  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. Terms of Use