We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent bb3c90d commit f9d42ffCopy full SHA for f9d42ff
RLBotCSharpExample/RLBotCSharpExample/Program.cs
@@ -1,15 +1,21 @@
1
using RLBotDotNet;
2
+using System.IO;
3
4
namespace RLBotCSharpExample
5
{
6
class Program
7
8
static void Main()
9
10
+ // Read the port from port.cfg.
11
+ const string file = "port.cfg";
12
+ string text = File.ReadAllLines(file)[0];
13
+ int port = int.Parse(text);
14
+
15
// BotManager is a generic which takes in your bot as its T type.
16
BotManager<ExampleBot> botManager = new BotManager<ExampleBot>();
- // Start the server on port 45031.
- botManager.Start(45031);
17
+ // Start the server on the port given in the port.cfg file.
18
+ botManager.Start(port);
19
}
20
21
RLBotCSharpExample/RLBotCSharpExample/bin/x64/Release/RLBotCSharpExample.exe
0 Bytes
RLBotCSharpExample/RLBotCSharpExample/bin/x64/Release/port.cfg
@@ -0,0 +1 @@
+45031
0 commit comments