marceldev89 / BattleNET

BattlEye Protocol Library and Client
GNU Lesser General Public License v3.0
76 stars 44 forks source link

BattlEyeConnectEventHandler #39

Closed KingOfGerrit closed 9 years ago

KingOfGerrit commented 9 years ago

How to make BattlEyeConnectEvent return string or bool?

marceldev89 commented 9 years ago

You can change event stuff here.

KingOfGerrit commented 9 years ago

But how b.BattlEyeConnected += BattlEyeConnected; return in variable bool?

DomiStyle commented 9 years ago

BattlEyeConnected can't return a bool, you need to handle all connection related code inside of the event. Take a look at the BattlEyeConnectEventArgs inside the connect event.

You can see it here: https://github.com/mvries/BattleNET/blob/master/BattleNET%20client/Program.cs#L102

args.ConnectionResult is what you want.

marceldev89 commented 9 years ago

Closing for now, ty @DomiStyle.