diff mm7_6.cpp @ 17:fe0d9a98213f

17.01.13 (fix Hint error)
author Ritor1
date Thu, 17 Jan 2013 16:24:25 +0600
parents 66319a734368
children 2bcc7b24c831
line wrap: on
line diff
--- a/mm7_6.cpp	Thu Jan 17 09:24:40 2013 +0600
+++ b/mm7_6.cpp	Thu Jan 17 16:24:25 2013 +0600
@@ -8939,15 +8939,23 @@
             }
             break;
           case INPUT_MoveBackwards:
-            __debugbreak();
+            //__debugbreak();
             if ( pCurrentScreen )
               break;
             if (!pParty->bTurnBasedModeOn)
-              goto _do_move_backwards;
+              //goto _do_move_backwards;
+            {
+              v5 = pActionQueue;
+              if ( pParty->uFlags2 & 2 )
+                partyAction = PARTY_RunBackward;
+              else
+                partyAction = PARTY_WalkBackward;
+              goto _add_action_and_continue;
+            }
             if ( pTurnEngine->field_4 != 1 && pTurnEngine->field_4 != 2 && pTurnEngine->uActionPointsLeft > 0 )
             {
               pTurnEngine->uActionPointsLeft -= 26;
-_do_move_backwards:
+//_do_move_backwards:
               v5 = pActionQueue;
               if ( pParty->uFlags2 & 2 )
                 partyAction = PARTY_RunBackward;
@@ -8957,27 +8965,35 @@
             }
             break;
           case INPUT_StrafeLeft:
-            __debugbreak();
+            //__debugbreak();
             if ( pCurrentScreen )
               break;
             if (!pParty->bTurnBasedModeOn)
-              goto _do_strafe_left;
+              //goto _do_strafe_left;
+            {
+              partyAction = PARTY_StrafeLeft;
+              goto _add_action_and_continue_;
+            }
             if ( pTurnEngine->field_4 == 1 || pTurnEngine->field_4 == 2 || pTurnEngine->uActionPointsLeft <= 0 )
               break;
             pTurnEngine->uActionPointsLeft -= 26;
-_do_strafe_left:
+//_do_strafe_left:
             partyAction = PARTY_StrafeLeft;
             goto _add_action_and_continue_;
           case INPUT_StrafeRight:
-            __debugbreak();
+            //__debugbreak();
             if ( pCurrentScreen )
               break;
             if (!pParty->bTurnBasedModeOn)
-              goto _do_strafe_right;
+              //goto _do_strafe_right;
+            {
+              partyAction = PARTY_StrafeRight;
+              goto _add_action_and_continue_;
+            }
             if ( pTurnEngine->field_4 == 1 || pTurnEngine->field_4 == 2 || pTurnEngine->uActionPointsLeft <= 0 )
               break;
             pTurnEngine->uActionPointsLeft -= 26;
-_do_strafe_right:
+//_do_strafe_right:
             partyAction = PARTY_StrafeRight;
             goto _add_action_and_continue_;
           case INPUT_TurnLeft:
@@ -9036,14 +9052,14 @@
             }
             break;
           case INPUT_Jump:
-            __debugbreak();
+            //__debugbreak();
             if ( pCurrentScreen
               || pParty->bTurnBasedModeOn)
               break;
             partyAction = (PartyAction)12;
             goto _add_action_and_continue_;
           case INPUT_Yell:
-            __debugbreak();
+            //__debugbreak();
             if ( !pCurrentScreen
               && uActiveCharacter )
             {
@@ -9052,11 +9068,15 @@
             }
             break;
           case INPUT_Pass:
-            __debugbreak();
+            //__debugbreak();
             if ( pCurrentScreen )
               break;
             if (pParty->bTurnBasedModeOn && pTurnEngine->field_4 == 3)
-              goto LABEL_118;
+              //goto LABEL_118;
+            {
+              pTurnEngine->field_18 |= 8u;
+              break;
+            }
             if ( uActiveCharacter )
             {
               v6 = pPlayers[uActiveCharacter];
@@ -9072,7 +9092,7 @@
             }
             break;
           case INPUT_Combat:
-            __debugbreak();
+            //__debugbreak();
             if ( !pCurrentScreen )
             {
               if (pParty->bTurnBasedModeOn)
@@ -9091,11 +9111,15 @@
             }
             break;
           case INPUT_CastReady:
-            __debugbreak();
+            //__debugbreak();
             if ( pCurrentScreen )
               break;
             if (pParty->bTurnBasedModeOn && pTurnEngine->field_4 == 3)
-              goto LABEL_118;
+              //goto LABEL_118;
+            {
+              pTurnEngine->field_18 |= 8u;
+              break;
+            }
             if ( !uActiveCharacter )
               break;
             v7 = pPlayers[uActiveCharacter];
@@ -9125,16 +9149,13 @@
               }
             }
             break;
-          default:
-            __debugbreak();
-            break;
           case INPUT_Attack:
-            __debugbreak();
+            //__debugbreak();
             if ( pCurrentScreen )
               break;
             if (!pParty->bTurnBasedModeOn || pTurnEngine->field_4 != 3)
               goto LABEL_120;
-LABEL_118:
+//LABEL_118:
             pTurnEngine->field_18 |= 8u;
             break;
           case INPUT_EventTrigger:
@@ -9170,46 +9191,46 @@
             }
             break;
           case INPUT_CharCycle:
-            __debugbreak();
+            //__debugbreak();
             if ( pCurrentScreen == 8
               || dword_50C9E8 >= 40 )
               break;
             dword_50C9EC[3 * dword_50C9E8] = 176;
             goto LABEL_155;
           case INPUT_LookUp:
-            __debugbreak();
+            //__debugbreak();
             if ( pEventTimer->bPaused )
               break;
             partyAction = (PartyAction)7;
             goto _add_action_and_continue_;
           case INPUT_CenterView:
-            __debugbreak();
+            //__debugbreak();
             if ( pEventTimer->bPaused )
               break;
             partyAction = (PartyAction)9;
             goto _add_action_and_continue_;
           case INPUT_LookDown:
-            __debugbreak();
+            //__debugbreak();
             if ( pEventTimer->bPaused )
               break;
             partyAction = (PartyAction)8;
             goto _add_action_and_continue_;
           case INPUT_FlyUp:
-            __debugbreak();
+            //__debugbreak();
             if ( pCurrentScreen
               || pEventTimer->bPaused )
               break;
             partyAction = (PartyAction)13;
             goto _add_action_and_continue_;
           case INPUT_Land:
-            __debugbreak();
+            //__debugbreak();
             if ( pCurrentScreen
               || pEventTimer->bPaused )
               break;
             partyAction = (PartyAction)15;
             goto _add_action_and_continue_;
           case INPUT_FlyDown:
-            __debugbreak();
+            //__debugbreak();
             if ( !pCurrentScreen
               && !pEventTimer->bPaused )
             {
@@ -9221,13 +9242,13 @@
             }
             break;
           case INPUT_ZoomIn:
-            __debugbreak();
+            //__debugbreak();
             if ( dword_50C9E8 >= 40 )
               break;
             dword_50C9EC[3 * dword_50C9E8] = 367;
             goto LABEL_155;
           case INPUT_ZoomOut:
-            __debugbreak();
+            //__debugbreak();
             if ( dword_50C9E8 < 40 )
             {
               dword_50C9EC[3 * dword_50C9E8] = 368;
@@ -9240,6 +9261,9 @@
           case INPUT_AlwaysRun:
             bAlwaysRun = bAlwaysRun == 0;
             break;
+          default:
+            //__debugbreak();
+            break;
         }
       }
       inputAction = (InputAction)((int)inputAction + 1);
@@ -9263,7 +9287,11 @@
         if ( (signed int)pMessageQueue_50CBD0->uNumMessages >= 40 )
           goto LABEL_175;
         pMessageQueue_50CBD0->pMessages[pMessageQueue_50CBD0->uNumMessages].eType = (UIMessageType)404;
-        goto LABEL_174;
+        //goto LABEL_174;
+        pMessageQueue_50CBD0->pMessages[pMessageQueue_50CBD0->uNumMessages].param = 0;
+        *(&pMessageQueue_50CBD0->uNumMessages + 3 * pMessageQueue_50CBD0->uNumMessages + 3) = 0;
+        ++pMessageQueue_50CBD0->uNumMessages;
+        goto LABEL_175;
       }
       if ( pCurrentScreen == 4
         || pCurrentScreen == 19 )
@@ -9276,15 +9304,20 @@
           {
             v15 = 1;
             pMessageQueue_50CBD0->uNumMessages = 1;
-            goto LABEL_173;
+            //goto LABEL_173;
+            pMessageQueue_50CBD0->pMessages[v15].eType = (UIMessageType)113;
+            pMessageQueue_50CBD0->pMessages[pMessageQueue_50CBD0->uNumMessages].param = 0;
+            *(&pMessageQueue_50CBD0->uNumMessages + 3 * pMessageQueue_50CBD0->uNumMessages + 3) = 0;
+            ++pMessageQueue_50CBD0->uNumMessages;
+            goto LABEL_175;
           }
           pMessageQueue_50CBD0->uNumMessages = 0;
         }
         if ( (signed int)v15 >= 40 )
           goto LABEL_175;
-LABEL_173:
+//LABEL_173:
         pMessageQueue_50CBD0->pMessages[v15].eType = (UIMessageType)113;
-LABEL_174:
+//LABEL_174:
         pMessageQueue_50CBD0->pMessages[pMessageQueue_50CBD0->uNumMessages].param = 0;
         *(&pMessageQueue_50CBD0->uNumMessages + 3 * pMessageQueue_50CBD0->uNumMessages + 3) = 0;
         ++pMessageQueue_50CBD0->uNumMessages;