v.0.5
This commit is contained in:
parent
651feb9ee0
commit
480b3d44ca
8 changed files with 7 additions and 4 deletions
Binary file not shown.
Binary file not shown.
Binary file not shown.
|
@ -114,20 +114,23 @@ namespace Bowling
|
|||
Connect connect = new Connect();
|
||||
if (connect.ShowDialog() == DialogResult.OK)
|
||||
{
|
||||
gameState = GameState.Menu;
|
||||
gameState = GameState.Menu;
|
||||
gameState = GameState.Game;
|
||||
player1 = new Player() { Name = connect.Name, Score = new List<int>() };
|
||||
NetLib.NetLib.IP = connect.IP;
|
||||
NetLib.NetLib.port = connect.Port;
|
||||
NetLib.NetLib.Connect();
|
||||
SendPlayerData(player1);
|
||||
player2.Deserialize(NetLib.NetLib.Receive());
|
||||
Thread thread = new Thread(() =>
|
||||
{
|
||||
player2.Deserialize(NetLib.NetLib.Receive());
|
||||
while (true)
|
||||
{
|
||||
player2.Deserialize(NetLib.NetLib.Receive());
|
||||
}
|
||||
});
|
||||
thread.Start();
|
||||
}
|
||||
else { gameState = GameState.Exit; }
|
||||
else { gameState = GameState.Menu; }
|
||||
break;
|
||||
}
|
||||
base.Update(gameTime);
|
||||
|
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Loading…
Add table
Reference in a new issue