]> 4ch.mooo.com Git - 16.git/commitdiff
updated copyright www
authorsparky4 <sparky4@cock.li>
Tue, 22 Mar 2016 20:09:56 +0000 (15:09 -0500)
committersparky4 <sparky4@cock.li>
Tue, 22 Mar 2016 20:09:56 +0000 (15:09 -0500)
src/lib/16_in.c

index 1337f5ed593bd1a036e36b83e9eb043c6b81080a..1ae5552e117b3d4dd5d17771d8e46e2b7af689ae 100755 (executable)
@@ -857,17 +857,20 @@ register  KeyboardDef     *def;
                                mx = motion_Right,my = motion_Down;*/\r
                        if(DIRECTIONIFELSE)\r
                        {\r
-                       if(!inpu.Keyboard[def->left] && !inpu.Keyboard[def->right]){\r
+                       //if(!inpu.Keyboard[def->left] && !inpu.Keyboard[def->right]){\r
                                if((inpu.Keyboard[def->up] && !inpu.Keyboard[def->down]))\r
                                        my = motion_Up;\r
                                if((inpu.Keyboard[def->down] && !inpu.Keyboard[def->up]))\r
                                        my = motion_Down;\r
-                       }else if(!inpu.Keyboard[def->up] && !inpu.Keyboard[def->down]){\r
+                       //}else if(!inpu.Keyboard[def->up] && !inpu.Keyboard[def->down]){\r
                                if((inpu.Keyboard[def->left] && !inpu.Keyboard[def->right]))\r
                                        mx = motion_Left;\r
                                if((inpu.Keyboard[def->right] && !inpu.Keyboard[def->left]))// || player[pn].pdir != 1)\r
                                        mx = motion_Right;\r
-                       }else{  //2 keys pressed\r
+\r
+                       //}else\r
+                               if(mx+my>1<mx+my)\r
+                               {       //2 keys pressed\r
                                        switch (player[pn].pdir)\r
                                        {\r
                                                case 0:\r
@@ -884,7 +887,7 @@ register    KeyboardDef     *def;
                                                break;\r
                                        }\r
                                        if(testcontrolnoisy > 0){ printf("dir=%c ", dirchar(dir)); printf("pdir=%c      ", dirchar(player[pn].pdir)); }\r
-                               }\r
+                               //}\r
                        }\r
                        //input from player\r
                        if (inpu.Keyboard[def->button0])\r