]> 4ch.mooo.com Git - 16.git/commitdiff
testing input oops ^^; i mean this output ok so i am abojut to ineject it soon
authorsparky4 <sparky4@cock.li>
Wed, 10 Aug 2016 17:16:26 +0000 (12:16 -0500)
committersparky4 <sparky4@cock.li>
Wed, 10 Aug 2016 17:16:26 +0000 (12:16 -0500)
src/lib/16_in.c

index 8b07fb54b9ae0468a06f365ecc0a90f4a649e722..5d60d6d60e78e1af13b275638429132da72c4a07 100755 (executable)
@@ -863,25 +863,25 @@ register  KeyboardDef     *def;
                        }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
+                               if((inpu.Keyboard[def->right] && !inpu.Keyboard[def->left]))\r
                                        mx = motion_Right;\r
                        }else{  //2 keys pressed\r
                                        switch (player[pn].pdir)\r
                                        {\r
                                                case 0:\r
                                                case 4:\r
-                                                       if((inpu.Keyboard[def->left] && !inpu.Keyboard[def->right])){ dir = DirTable[1]; mx = motion_Left; }\r
-                                                       else if((inpu.Keyboard[def->right] && !inpu.Keyboard[def->left])){ dir = DirTable[3]; mx = motion_Right; }\r
+                                                       if((inpu.Keyboard[def->left] && !inpu.Keyboard[def->right])){ dir = DirTable[1]; }//mx = motion_Left; }\r
+                                                       else if((inpu.Keyboard[def->right] && !inpu.Keyboard[def->left])){ dir = DirTable[3]; }//mx = motion_Right; }\r
                                                break;\r
                                                case 1:\r
                                                case 3:\r
-                                                       if((inpu.Keyboard[def->up] && !inpu.Keyboard[def->down])){ dir = DirTable[0]; my = motion_Up; }\r
-                                                       else if((inpu.Keyboard[def->down] && !inpu.Keyboard[def->up])){ dir = DirTable[4]; my = motion_Down; }\r
+                                                       if((inpu.Keyboard[def->up] && !inpu.Keyboard[def->down])){ dir = DirTable[0]; }//my = motion_Up; }\r
+                                                       else if((inpu.Keyboard[def->down] && !inpu.Keyboard[def->up])){ dir = DirTable[4]; }//my = motion_Down; }\r
                                                break;\r
                                                default:\r
                                                break;\r
                                        }\r
-                                       if(testcontrolnoisy > 0){ printf("dir=%c ", dirchar(dir)); printf("pdir=%c      ", dirchar(player[pn].pdir)); }\r
+                                       //if(testcontrolnoisy > 0){ printf("dir=%c ", dirchar(dir)); printf("pdir=%c    ", dirchar(player[pn].pdir)); }\r
                                }\r
                        }\r
                        //input from player\r
@@ -963,7 +963,7 @@ register    KeyboardDef     *def;
        }\r
 #endif\r
 if(testcontrolnoisy > 0)\r
-if(player[pn]./*(inpu.Keyboard[def->up] || inpu.Keyboard[def->down] || inpu.Keyboard[def->left] || inpu.Keyboard[def->right])*/ || player[pn].q>1)\r
+if(player[pn].info.dir!=2/*(inpu.Keyboard[def->up] || inpu.Keyboard[def->down] || inpu.Keyboard[def->left] || inpu.Keyboard[def->right])*/ || player[pn].q>1)\r
 {\r
        //printf("b1=%u b2=%u b3=%u b4=%u       ", player[pn].info.button0, player[pn].info.button1, player[pn].info.button2, player[pn].info.button3);\r
        //printf("q=%d ", player[pn].q);\r