CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 2 of 2
  1. #1
    Join Date
    Jan 2018
    Posts
    2

    Any Developer Familiar with Source RCon??

    Hi im trying to make a RCon Tool to could remotely manage my Rust Experimental Dedicated Server and Counter Strike: Global Offenssive, they both uses the Source RCon Protocol https://developer.valvesoftware.com/..._RCON_Protocol

    so till now i manage myself to make a function that works great with Rust Experimental Dedicated Server but when i tried the same function with Counter Strike: Global Offenssive it doesn't so, maybe any of u guys could point me if im missing something in my code??

    here is what i have so far

    Code:
    Private Function sendCommand(ByVal command As String, ByVal ServerData As Integer) As Byte
        Dim i As Integer
        Dim packet() As Byte
        Dim strCommand() As Byte
       
        id = id + 1
        
        strCommand = StrConv(command, vbFromUnicode)
        
        ReDim packet(Len(command) + 13) As Byte
        
        packet(0) = Len(command)
        packet(4) = id
        packet(8) = ServerData
        
        For i = 0 To Len(command) - 1
            packet(12 + i) = strCommand(i)
        Next
            
        Winsock1.SendData packet
    End Function
    and the way to use it:

    'Auth against the Dedicated Server
    sendCommand("password", 3)

    'Send Command after we authenticated
    sendCommand("status", 3)

    Thanks in advance

  2. #2
    Join Date
    Jan 2018
    Posts
    2

    Re: Any Developer Familiar with Source RCon??

    Quote Originally Posted by jcarlosc88 View Post
    Hi im trying to make a RCon Tool to could remotely manage my Rust Experimental Dedicated Server and Counter Strike: Global Offenssive, they both uses the Source RCon Protocol https://developer.valvesoftware.com/..._RCON_Protocol

    so till now i manage myself to make a function that works great with Rust Experimental Dedicated Server but when i tried the same function with Counter Strike: Global Offenssive it doesn't so, maybe any of u guys could point me if im missing something in my code??

    here is what i have so far

    Code:
    Private Function sendCommand(ByVal command As String, ByVal ServerData As Integer) As Byte
        Dim i As Integer
        Dim packet() As Byte
        Dim strCommand() As Byte
       
        id = id + 1
        
        strCommand = StrConv(command, vbFromUnicode)
        
        ReDim packet(Len(command) + 13) As Byte
        
        packet(0) = Len(command)
        packet(4) = id
        packet(8) = ServerData
        
        For i = 0 To Len(command) - 1
            packet(12 + i) = strCommand(i)
        Next
            
        Winsock1.SendData packet
    End Function
    and the way to use it:

    'Auth against the Dedicated Server
    sendCommand("password", 3)

    'Send Command after we authenticated
    sendCommand("status", 3)

    Thanks in advance
    sorry the way to use its like this:

    'Auth against the Dedicated Server
    sendCommand("password", 3)

    'Send Command after we authenticated
    sendCommand("status", 2)


    Thanks and all the help will be appreciated

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured