Expected Behavior:
When a client connects to a server the client will automatically load the map that the server is running. (Multiplayer Shootout Game youtube video at 17:27).
Actual Behavior:
The client reloads the map that it was running when it connected to the server (usually a level titled something like ‘MainMenu’). .
Steps to Reproduce:
- Create new MultiplayerShootout project (version 4.10.2)
- Load map ‘MainMenu’
- Change Play->Number of Players to ‘2’
- Select Play->New Editor Window (PIE)
- Select Play->Advanced Settings
- Change ‘Standalone Windows Size’ to 640x360
- Uncheck ‘Always center window to screen’
- Change Standalone Window Position to 1100x0
- Uncheck ‘Auto Connect To Server’
- Close ‘Editor Preferences’ window
- Click ‘Play’. Two windows appear, both displaying the main menu
- Click the ‘Play’ button on the left window. Level_01 will load. Orange cowboy will be ready to draw.
- Click the ‘Find Games’ button on the right window (there is often a problem with the cursor disappearing at this point. I am not concerned about this at the moment, I use tab and arrow keys). One server will display in the list.
- Click the server in the list. Orange cowboy will appear in the window on the left (server). Right window is black with MyHUD displayed. If the game is played on the server window projectiles will replicate on the client, score will also replicate. In my personal project I can control my client’s actor (the server version) by focusing the client window and using the keyboard and mouse. Of course the client window is just black (as the level that I used to connect to the server has nothing in it)
General Thoughts:
I believe MultiplayerShootout was working correctly earlier (within the last day or two). Maybe I’m wrong about this, maybe I’m just too drunk to remember correctly. I started to implement logic similar to MultiplayerShootout in a personal project. I noticed that whenever a client connected to a server the BeginPlay event of the MainMenu map (which is the map that was loaded when the client tried connecting to the server) would get called and the client would display a black screen (which is correct for the MainMenu map). I went back to MultiplayerShootout and experienced the same behavior. I opened projects that I haven’t worked on in weeks which connect using OpenLevel?listen and ExecuteConsoleCommand (no session nodes) and they now behave the same (client reloads level that was open when connection to server was requested). Before this I had never used the session nodes or had Steam entries in any DefaultEngine.ini file. I’m not sure if I messed something up at the computer level or if there is just a bug in my projects. When I package MultiplayerShootout, start two instances and create a server and client the client connects as expected. Any help with this issue is greatly appreciated.
Verbose log is at http://pastebin.com/ATTxSnDz
TLDR; my sh*t be wack