aboutsummaryrefslogtreecommitdiff
path: root/musw.c
diff options
context:
space:
mode:
authorrodri <rgl@antares-labs.eu>2023-06-05 20:23:26 +0000
committerrodri <rgl@antares-labs.eu>2023-06-05 20:23:26 +0000
commit9c20abc1ab976cab00040a32299896dc8ea71e6c (patch)
tree5037406ea18c55dc0be2001c1d27e2d89edc16f7 /musw.c
parent0625897dd0194986b02988eb5a9c2969e24adf0c (diff)
downloadmusw-9c20abc1ab976cab00040a32299896dc8ea71e6c.tar.gz
musw-9c20abc1ab976cab00040a32299896dc8ea71e6c.tar.bz2
musw-9c20abc1ab976cab00040a32299896dc8ea71e6c.zip
put the player routines in their own unit.
fixed an issue with the threadsim routine that would cause re-stepping of all the previous parties after dissolving one of them due to one of the players quitting.
Diffstat (limited to 'musw.c')
-rw-r--r--musw.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/musw.c b/musw.c
index fd04db3..fd8c8ac 100644
--- a/musw.c
+++ b/musw.c
@@ -657,14 +657,16 @@ State *intro_δ(State *s, void *arg)
State *connecting_δ(State *s, void*)
{
- if(netconn.state != NCSConnecting)
+ if(netconn.state == NCSConnected)
return &gamestates[GSMatching];
return s;
}
State *matching_δ(State *s, void*)
{
- if(netconn.state == NCSConnected && weplaying)
+ if(netconn.state != NCSConnected)
+ return &gamestates[GSConnecting];
+ if(weplaying)
return &gamestates[GSPlaying];
return s;
}