wm: glendy

Download patch

ref: 9671de025471a5ee4f39d5acb1434161a21ed317
parent: 8d09c9f0792ba1a5537a5fcae547d7c4fe58bef3
author: mkf <mkf@cloud9p.org>
date: Thu May 23 11:40:05 EDT 2024

netclient: fix xy

--- a/netclient.c
+++ b/netclient.c
@@ -143,7 +143,7 @@
 					p.x = atoi(xpos);
 					p.y = atoi(ypos);
 					
-					grid[p.y][p.x] = Wall;
+					grid[p.x][p.y] = Wall;
 					break;
 				case 'g':
 					xpos = strtok(nil, " ");
@@ -154,7 +154,7 @@
 					p.x = atoi(xpos);
 					p.y = atoi(ypos);
 					
-					grid[p.y][p.x] = Glenda;
+					grid[p.x][p.y] = Glenda;
 					break;
 				default:
 					if(!strcmp("SENT", tmp))
@@ -206,7 +206,7 @@
 			if(msg->ntoken < 4)
 				sysfatal("netproc(): not enough tokens to SYNC trapper's move");
 			
-			p = parseput(tokens[3], tokens[2]);
+			p = parseput(tokens[2], tokens[3]);
 			doput(p);
 		}
 		/* TODO: very ugly hack, get rid of this */