Jump to content
Search In
  • More options...
Find results that contain...
Find results in...

[Bug Fix] Sending Client Version to Register


Valentine90
 Share

Recommended Posts

**Sorry my english**

I realized that the client version is not sent to the record, enabling a player can register for a customer out of date.

**Open Client**

**1 -** In **modClientTCP**, look for:

```
Public Sub SendNewAccount
```

**2 -** Beneath:

```
Buffer.WriteString Password
```

**3 -** Add:

```
Buffer.WriteLong App.Major

Buffer.WriteLong App.Minor

Buffer.WriteLong App.Revision
```

**Open Server**

**1 -** In **modHandleData**, look for:

```
Private Sub HandleNewAccount
```

**2 -** Beneath:

```
Password = Buffer.ReadString
```

**3 -** Below add:

```
' Check versions

If Buffer.ReadLong < CLIENT_MAJOR Or Buffer.ReadLong < CLIENT_MINOR Or Buffer.ReadLong < CLIENT_REVISION Then

Call AlertMsg(index, "Version outdated, please visit " & Options.Website)

Exit Sub

End If
```

**Credits:**

Valentine
Link to comment
Share on other sites

  • 2 weeks later...
  • 4 weeks later...
No what this does is basically adds a check that checks whether the persons client version = current client version while registration. If this wasn't added i could register in a game with the first released version when the version would be 10+ the current version.
Link to comment
Share on other sites

  • 2 months later...

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...