comparison mm7_6.cpp @ 20:980c34defdab

Слияние
author Ritor1
date Thu, 17 Jan 2013 22:59:03 +0600
parents fe0d9a98213f
children 2bcc7b24c831
comparison
equal deleted inserted replaced
19:2127707df23f 20:980c34defdab
8937 partyAction = PARTY_WalkForward; 8937 partyAction = PARTY_WalkForward;
8938 goto _add_action_and_continue; 8938 goto _add_action_and_continue;
8939 } 8939 }
8940 break; 8940 break;
8941 case INPUT_MoveBackwards: 8941 case INPUT_MoveBackwards:
8942 __debugbreak(); 8942 //__debugbreak();
8943 if ( pCurrentScreen ) 8943 if ( pCurrentScreen )
8944 break; 8944 break;
8945 if (!pParty->bTurnBasedModeOn) 8945 if (!pParty->bTurnBasedModeOn)
8946 goto _do_move_backwards; 8946 //goto _do_move_backwards;
8947 {
8948 v5 = pActionQueue;
8949 if ( pParty->uFlags2 & 2 )
8950 partyAction = PARTY_RunBackward;
8951 else
8952 partyAction = PARTY_WalkBackward;
8953 goto _add_action_and_continue;
8954 }
8947 if ( pTurnEngine->field_4 != 1 && pTurnEngine->field_4 != 2 && pTurnEngine->uActionPointsLeft > 0 ) 8955 if ( pTurnEngine->field_4 != 1 && pTurnEngine->field_4 != 2 && pTurnEngine->uActionPointsLeft > 0 )
8948 { 8956 {
8949 pTurnEngine->uActionPointsLeft -= 26; 8957 pTurnEngine->uActionPointsLeft -= 26;
8950 _do_move_backwards: 8958 //_do_move_backwards:
8951 v5 = pActionQueue; 8959 v5 = pActionQueue;
8952 if ( pParty->uFlags2 & 2 ) 8960 if ( pParty->uFlags2 & 2 )
8953 partyAction = PARTY_RunBackward; 8961 partyAction = PARTY_RunBackward;
8954 else 8962 else
8955 partyAction = PARTY_WalkBackward; 8963 partyAction = PARTY_WalkBackward;
8956 goto _add_action_and_continue; 8964 goto _add_action_and_continue;
8957 } 8965 }
8958 break; 8966 break;
8959 case INPUT_StrafeLeft: 8967 case INPUT_StrafeLeft:
8960 __debugbreak(); 8968 //__debugbreak();
8961 if ( pCurrentScreen ) 8969 if ( pCurrentScreen )
8962 break; 8970 break;
8963 if (!pParty->bTurnBasedModeOn) 8971 if (!pParty->bTurnBasedModeOn)
8964 goto _do_strafe_left; 8972 //goto _do_strafe_left;
8973 {
8974 partyAction = PARTY_StrafeLeft;
8975 goto _add_action_and_continue_;
8976 }
8965 if ( pTurnEngine->field_4 == 1 || pTurnEngine->field_4 == 2 || pTurnEngine->uActionPointsLeft <= 0 ) 8977 if ( pTurnEngine->field_4 == 1 || pTurnEngine->field_4 == 2 || pTurnEngine->uActionPointsLeft <= 0 )
8966 break; 8978 break;
8967 pTurnEngine->uActionPointsLeft -= 26; 8979 pTurnEngine->uActionPointsLeft -= 26;
8968 _do_strafe_left: 8980 //_do_strafe_left:
8969 partyAction = PARTY_StrafeLeft; 8981 partyAction = PARTY_StrafeLeft;
8970 goto _add_action_and_continue_; 8982 goto _add_action_and_continue_;
8971 case INPUT_StrafeRight: 8983 case INPUT_StrafeRight:
8972 __debugbreak(); 8984 //__debugbreak();
8973 if ( pCurrentScreen ) 8985 if ( pCurrentScreen )
8974 break; 8986 break;
8975 if (!pParty->bTurnBasedModeOn) 8987 if (!pParty->bTurnBasedModeOn)
8976 goto _do_strafe_right; 8988 //goto _do_strafe_right;
8989 {
8990 partyAction = PARTY_StrafeRight;
8991 goto _add_action_and_continue_;
8992 }
8977 if ( pTurnEngine->field_4 == 1 || pTurnEngine->field_4 == 2 || pTurnEngine->uActionPointsLeft <= 0 ) 8993 if ( pTurnEngine->field_4 == 1 || pTurnEngine->field_4 == 2 || pTurnEngine->uActionPointsLeft <= 0 )
8978 break; 8994 break;
8979 pTurnEngine->uActionPointsLeft -= 26; 8995 pTurnEngine->uActionPointsLeft -= 26;
8980 _do_strafe_right: 8996 //_do_strafe_right:
8981 partyAction = PARTY_StrafeRight; 8997 partyAction = PARTY_StrafeRight;
8982 goto _add_action_and_continue_; 8998 goto _add_action_and_continue_;
8983 case INPUT_TurnLeft: 8999 case INPUT_TurnLeft:
8984 if ( pCurrentScreen ) 9000 if ( pCurrentScreen )
8985 break; 9001 break;
9034 LABEL_75: 9050 LABEL_75:
9035 pWeather->_4C2F0B(v20); 9051 pWeather->_4C2F0B(v20);
9036 } 9052 }
9037 break; 9053 break;
9038 case INPUT_Jump: 9054 case INPUT_Jump:
9039 __debugbreak(); 9055 //__debugbreak();
9040 if ( pCurrentScreen 9056 if ( pCurrentScreen
9041 || pParty->bTurnBasedModeOn) 9057 || pParty->bTurnBasedModeOn)
9042 break; 9058 break;
9043 partyAction = (PartyAction)12; 9059 partyAction = (PartyAction)12;
9044 goto _add_action_and_continue_; 9060 goto _add_action_and_continue_;
9045 case INPUT_Yell: 9061 case INPUT_Yell:
9046 __debugbreak(); 9062 //__debugbreak();
9047 if ( !pCurrentScreen 9063 if ( !pCurrentScreen
9048 && uActiveCharacter ) 9064 && uActiveCharacter )
9049 { 9065 {
9050 pParty->Yell(); 9066 pParty->Yell();
9051 pPlayers[uActiveCharacter]->PlaySound(65, 0); 9067 pPlayers[uActiveCharacter]->PlaySound(65, 0);
9052 } 9068 }
9053 break; 9069 break;
9054 case INPUT_Pass: 9070 case INPUT_Pass:
9055 __debugbreak(); 9071 //__debugbreak();
9056 if ( pCurrentScreen ) 9072 if ( pCurrentScreen )
9057 break; 9073 break;
9058 if (pParty->bTurnBasedModeOn && pTurnEngine->field_4 == 3) 9074 if (pParty->bTurnBasedModeOn && pTurnEngine->field_4 == 3)
9059 goto LABEL_118; 9075 //goto LABEL_118;
9076 {
9077 pTurnEngine->field_18 |= 8u;
9078 break;
9079 }
9060 if ( uActiveCharacter ) 9080 if ( uActiveCharacter )
9061 { 9081 {
9062 v6 = pPlayers[uActiveCharacter]; 9082 v6 = pPlayers[uActiveCharacter];
9063 if ( !v6->uTimeToRecovery ) 9083 if ( !v6->uTimeToRecovery )
9064 { 9084 {
9070 pTurnEngine->_40471C(); 9090 pTurnEngine->_40471C();
9071 } 9091 }
9072 } 9092 }
9073 break; 9093 break;
9074 case INPUT_Combat: 9094 case INPUT_Combat:
9075 __debugbreak(); 9095 //__debugbreak();
9076 if ( !pCurrentScreen ) 9096 if ( !pCurrentScreen )
9077 { 9097 {
9078 if (pParty->bTurnBasedModeOn) 9098 if (pParty->bTurnBasedModeOn)
9079 { 9099 {
9080 if ( pTurnEngine->field_4 == 3 || (pTurnEngine->pQueue[0].uPackedID & 7) == 4 ) 9100 if ( pTurnEngine->field_4 == 3 || (pTurnEngine->pQueue[0].uPackedID & 7) == 4 )
9089 pParty->bTurnBasedModeOn = true; 9109 pParty->bTurnBasedModeOn = true;
9090 } 9110 }
9091 } 9111 }
9092 break; 9112 break;
9093 case INPUT_CastReady: 9113 case INPUT_CastReady:
9094 __debugbreak(); 9114 //__debugbreak();
9095 if ( pCurrentScreen ) 9115 if ( pCurrentScreen )
9096 break; 9116 break;
9097 if (pParty->bTurnBasedModeOn && pTurnEngine->field_4 == 3) 9117 if (pParty->bTurnBasedModeOn && pTurnEngine->field_4 == 3)
9098 goto LABEL_118; 9118 //goto LABEL_118;
9119 {
9120 pTurnEngine->field_18 |= 8u;
9121 break;
9122 }
9099 if ( !uActiveCharacter ) 9123 if ( !uActiveCharacter )
9100 break; 9124 break;
9101 v7 = pPlayers[uActiveCharacter]; 9125 v7 = pPlayers[uActiveCharacter];
9102 v8 = v7->uQuickSpell; 9126 v8 = v7->uQuickSpell;
9103 if ( !v8 9127 if ( !v8
9123 *(&dword_50C9E8 + 3 * dword_50C9E8 + 3) = 0; 9147 *(&dword_50C9E8 + 3 * dword_50C9E8 + 3) = 0;
9124 ++dword_50C9E8; 9148 ++dword_50C9E8;
9125 } 9149 }
9126 } 9150 }
9127 break; 9151 break;
9128 default:
9129 __debugbreak();
9130 break;
9131 case INPUT_Attack: 9152 case INPUT_Attack:
9132 __debugbreak(); 9153 //__debugbreak();
9133 if ( pCurrentScreen ) 9154 if ( pCurrentScreen )
9134 break; 9155 break;
9135 if (!pParty->bTurnBasedModeOn || pTurnEngine->field_4 != 3) 9156 if (!pParty->bTurnBasedModeOn || pTurnEngine->field_4 != 3)
9136 goto LABEL_120; 9157 goto LABEL_120;
9137 LABEL_118: 9158 //LABEL_118:
9138 pTurnEngine->field_18 |= 8u; 9159 pTurnEngine->field_18 |= 8u;
9139 break; 9160 break;
9140 case INPUT_EventTrigger: 9161 case INPUT_EventTrigger:
9141 if ( !pCurrentScreen ) 9162 if ( !pCurrentScreen )
9142 { 9163 {
9168 if ( (signed int)v11 < 40 ) 9189 if ( (signed int)v11 < 40 )
9169 goto LABEL_132; 9190 goto LABEL_132;
9170 } 9191 }
9171 break; 9192 break;
9172 case INPUT_CharCycle: 9193 case INPUT_CharCycle:
9173 __debugbreak(); 9194 //__debugbreak();
9174 if ( pCurrentScreen == 8 9195 if ( pCurrentScreen == 8
9175 || dword_50C9E8 >= 40 ) 9196 || dword_50C9E8 >= 40 )
9176 break; 9197 break;
9177 dword_50C9EC[3 * dword_50C9E8] = 176; 9198 dword_50C9EC[3 * dword_50C9E8] = 176;
9178 goto LABEL_155; 9199 goto LABEL_155;
9179 case INPUT_LookUp: 9200 case INPUT_LookUp:
9180 __debugbreak(); 9201 //__debugbreak();
9181 if ( pEventTimer->bPaused ) 9202 if ( pEventTimer->bPaused )
9182 break; 9203 break;
9183 partyAction = (PartyAction)7; 9204 partyAction = (PartyAction)7;
9184 goto _add_action_and_continue_; 9205 goto _add_action_and_continue_;
9185 case INPUT_CenterView: 9206 case INPUT_CenterView:
9186 __debugbreak(); 9207 //__debugbreak();
9187 if ( pEventTimer->bPaused ) 9208 if ( pEventTimer->bPaused )
9188 break; 9209 break;
9189 partyAction = (PartyAction)9; 9210 partyAction = (PartyAction)9;
9190 goto _add_action_and_continue_; 9211 goto _add_action_and_continue_;
9191 case INPUT_LookDown: 9212 case INPUT_LookDown:
9192 __debugbreak(); 9213 //__debugbreak();
9193 if ( pEventTimer->bPaused ) 9214 if ( pEventTimer->bPaused )
9194 break; 9215 break;
9195 partyAction = (PartyAction)8; 9216 partyAction = (PartyAction)8;
9196 goto _add_action_and_continue_; 9217 goto _add_action_and_continue_;
9197 case INPUT_FlyUp: 9218 case INPUT_FlyUp:
9198 __debugbreak(); 9219 //__debugbreak();
9199 if ( pCurrentScreen 9220 if ( pCurrentScreen
9200 || pEventTimer->bPaused ) 9221 || pEventTimer->bPaused )
9201 break; 9222 break;
9202 partyAction = (PartyAction)13; 9223 partyAction = (PartyAction)13;
9203 goto _add_action_and_continue_; 9224 goto _add_action_and_continue_;
9204 case INPUT_Land: 9225 case INPUT_Land:
9205 __debugbreak(); 9226 //__debugbreak();
9206 if ( pCurrentScreen 9227 if ( pCurrentScreen
9207 || pEventTimer->bPaused ) 9228 || pEventTimer->bPaused )
9208 break; 9229 break;
9209 partyAction = (PartyAction)15; 9230 partyAction = (PartyAction)15;
9210 goto _add_action_and_continue_; 9231 goto _add_action_and_continue_;
9211 case INPUT_FlyDown: 9232 case INPUT_FlyDown:
9212 __debugbreak(); 9233 //__debugbreak();
9213 if ( !pCurrentScreen 9234 if ( !pCurrentScreen
9214 && !pEventTimer->bPaused ) 9235 && !pEventTimer->bPaused )
9215 { 9236 {
9216 partyAction = (PartyAction)14; 9237 partyAction = (PartyAction)14;
9217 _add_action_and_continue_: 9238 _add_action_and_continue_:
9219 _add_action_and_continue: 9240 _add_action_and_continue:
9220 v5->Add(partyAction); 9241 v5->Add(partyAction);
9221 } 9242 }
9222 break; 9243 break;
9223 case INPUT_ZoomIn: 9244 case INPUT_ZoomIn:
9224 __debugbreak(); 9245 //__debugbreak();
9225 if ( dword_50C9E8 >= 40 ) 9246 if ( dword_50C9E8 >= 40 )
9226 break; 9247 break;
9227 dword_50C9EC[3 * dword_50C9E8] = 367; 9248 dword_50C9EC[3 * dword_50C9E8] = 367;
9228 goto LABEL_155; 9249 goto LABEL_155;
9229 case INPUT_ZoomOut: 9250 case INPUT_ZoomOut:
9230 __debugbreak(); 9251 //__debugbreak();
9231 if ( dword_50C9E8 < 40 ) 9252 if ( dword_50C9E8 < 40 )
9232 { 9253 {
9233 dword_50C9EC[3 * dword_50C9E8] = 368; 9254 dword_50C9EC[3 * dword_50C9E8] = 368;
9234 LABEL_155: 9255 LABEL_155:
9235 dword_50C9F0[3 * dword_50C9E8] = 0; 9256 dword_50C9F0[3 * dword_50C9E8] = 0;
9237 ++dword_50C9E8; 9258 ++dword_50C9E8;
9238 } 9259 }
9239 break; 9260 break;
9240 case INPUT_AlwaysRun: 9261 case INPUT_AlwaysRun:
9241 bAlwaysRun = bAlwaysRun == 0; 9262 bAlwaysRun = bAlwaysRun == 0;
9263 break;
9264 default:
9265 //__debugbreak();
9242 break; 9266 break;
9243 } 9267 }
9244 } 9268 }
9245 inputAction = (InputAction)((int)inputAction + 1); 9269 inputAction = (InputAction)((int)inputAction + 1);
9246 if ( (signed int)inputAction >= 30 ) 9270 if ( (signed int)inputAction >= 30 )
9261 if ( !pCurrentScreen ) 9285 if ( !pCurrentScreen )
9262 { 9286 {
9263 if ( (signed int)pMessageQueue_50CBD0->uNumMessages >= 40 ) 9287 if ( (signed int)pMessageQueue_50CBD0->uNumMessages >= 40 )
9264 goto LABEL_175; 9288 goto LABEL_175;
9265 pMessageQueue_50CBD0->pMessages[pMessageQueue_50CBD0->uNumMessages].eType = (UIMessageType)404; 9289 pMessageQueue_50CBD0->pMessages[pMessageQueue_50CBD0->uNumMessages].eType = (UIMessageType)404;
9266 goto LABEL_174; 9290 //goto LABEL_174;
9291 pMessageQueue_50CBD0->pMessages[pMessageQueue_50CBD0->uNumMessages].param = 0;
9292 *(&pMessageQueue_50CBD0->uNumMessages + 3 * pMessageQueue_50CBD0->uNumMessages + 3) = 0;
9293 ++pMessageQueue_50CBD0->uNumMessages;
9294 goto LABEL_175;
9267 } 9295 }
9268 if ( pCurrentScreen == 4 9296 if ( pCurrentScreen == 4
9269 || pCurrentScreen == 19 ) 9297 || pCurrentScreen == 19 )
9270 { 9298 {
9271 v15 = pMessageQueue_50CBD0->uNumMessages; 9299 v15 = pMessageQueue_50CBD0->uNumMessages;
9274 v15 = 0; 9302 v15 = 0;
9275 if ( pMessageQueue_50CBD0->pMessages[0].field_8 ) 9303 if ( pMessageQueue_50CBD0->pMessages[0].field_8 )
9276 { 9304 {
9277 v15 = 1; 9305 v15 = 1;
9278 pMessageQueue_50CBD0->uNumMessages = 1; 9306 pMessageQueue_50CBD0->uNumMessages = 1;
9279 goto LABEL_173; 9307 //goto LABEL_173;
9308 pMessageQueue_50CBD0->pMessages[v15].eType = (UIMessageType)113;
9309 pMessageQueue_50CBD0->pMessages[pMessageQueue_50CBD0->uNumMessages].param = 0;
9310 *(&pMessageQueue_50CBD0->uNumMessages + 3 * pMessageQueue_50CBD0->uNumMessages + 3) = 0;
9311 ++pMessageQueue_50CBD0->uNumMessages;
9312 goto LABEL_175;
9280 } 9313 }
9281 pMessageQueue_50CBD0->uNumMessages = 0; 9314 pMessageQueue_50CBD0->uNumMessages = 0;
9282 } 9315 }
9283 if ( (signed int)v15 >= 40 ) 9316 if ( (signed int)v15 >= 40 )
9284 goto LABEL_175; 9317 goto LABEL_175;
9285 LABEL_173: 9318 //LABEL_173:
9286 pMessageQueue_50CBD0->pMessages[v15].eType = (UIMessageType)113; 9319 pMessageQueue_50CBD0->pMessages[v15].eType = (UIMessageType)113;
9287 LABEL_174: 9320 //LABEL_174:
9288 pMessageQueue_50CBD0->pMessages[pMessageQueue_50CBD0->uNumMessages].param = 0; 9321 pMessageQueue_50CBD0->pMessages[pMessageQueue_50CBD0->uNumMessages].param = 0;
9289 *(&pMessageQueue_50CBD0->uNumMessages + 3 * pMessageQueue_50CBD0->uNumMessages + 3) = 0; 9322 *(&pMessageQueue_50CBD0->uNumMessages + 3 * pMessageQueue_50CBD0->uNumMessages + 3) = 0;
9290 ++pMessageQueue_50CBD0->uNumMessages; 9323 ++pMessageQueue_50CBD0->uNumMessages;
9291 goto LABEL_175; 9324 goto LABEL_175;
9292 } 9325 }