comparison Events.cpp @ 538:1d876589a030

Слияние
author Ritor1
date Sat, 02 Mar 2013 09:01:48 +0600
parents f0eff7c35a2b 35f28d4c0ff9
children d6711da258f1
comparison
equal deleted inserted replaced
537:db4631a484ae 538:1d876589a030
296 ShowStatusBarString(pGlobalTXT_LocalizationStrings[521], 2u);// Nothing here 296 ShowStatusBarString(pGlobalTXT_LocalizationStrings[521], 2u);// Nothing here
297 return; 297 return;
298 } 298 }
299 player_choose = (uActiveCharacter == 0)?6:4; //4 - active or 6 - random player if active =0 299 player_choose = (uActiveCharacter == 0)?6:4; //4 - active or 6 - random player if active =0
300 curr_seq_num = start_event_seq_number; 300 curr_seq_num = start_event_seq_number;
301 if ( GlobalEventInfo ) 301 if ( activeLevelDecoration )
302 { 302 {
303 uSomeEVT_NumEvents = uGlobalEVT_NumEvents; 303 uSomeEVT_NumEvents = uGlobalEVT_NumEvents;
304 pSomeEVT = pGlobalEVT; 304 pSomeEVT = pGlobalEVT;
305 memcpy(pSomeEVT_Events, pGlobalEVT_Index, sizeof(EventIndex)*4400); //4400 evts 305 memcpy(pSomeEVT_Events, pGlobalEVT_Index, sizeof(EventIndex)*4400); //4400 evts
306 } 306 }
522 522
523 //v6 = v123; 523 //v6 = v123;
524 //v7 = ""; 524 //v7 = "";
525 break; 525 break;
526 case EVENT_ChangeEvent: 526 case EVENT_ChangeEvent:
527 v25 = _evt->v5 + ((_evt->v6 + ((_evt->v7 + ((unsigned int)_evt->v8 << 8)) << 8)) << 8); 527 v25 = EVT_DWORD(_evt->v5);
528 if ( v25 ) 528 if ( v25 )
529 { 529 {
530 stru_5E4C90._decor_events[GlobalEventInfo + 28] = _evt->v5 - 124; 530 stru_5E4C90._decor_events[activeLevelDecoration->_idx_in_stru123] = _evt->v5 - 124;
531 } 531 }
532 else 532 else
533 { 533 {
534 v26 = (LevelDecoration *)GlobalEventInfo; 534 v26 = (LevelDecoration *)activeLevelDecoration;
535 stru_5E4C90._decor_events[GlobalEventInfo + 28] = 0; 535 stru_5E4C90._decor_events[activeLevelDecoration ->_idx_in_stru123] = 0;
536 LOBYTE(v26->field_2) |= 0x20u; 536 LOBYTE(v26->field_2) |= 0x20u;
537 } 537 }
538 ++curr_seq_num; 538 ++curr_seq_num;
539 v4 = v124; 539 v4 = v124;
540 540
720 { 720 {
721 sub_4BD8B5(); 721 sub_4BD8B5();
722 pVideoPlayer->Unload(); 722 pVideoPlayer->Unload();
723 window_SpeakInHouse->Release(); 723 window_SpeakInHouse->Release();
724 pParty->uFlags &= 0xFFFFFFFDu; 724 pParty->uFlags &= 0xFFFFFFFDu;
725 GlobalEventInfo = 1; 725 activeLevelDecoration = (LevelDecoration*)1;
726 if ( EnterHouse(HOUSE_BODY_GUILD_ERATHIA) ) 726 if ( EnterHouse(HOUSE_BODY_GUILD_ERATHIA) )
727 { 727 {
728 pAudioPlayer->PlaySound((SoundID)0, 0, 0, -1, 0, 0, 0, 0); 728 pAudioPlayer->PlaySound((SoundID)0, 0, 0, -1, 0, 0, 0, 0);
729 v47 = GUIWindow::Create(0, 0, 640, 480, WINDOW_HouseInterior, 165, 0); 729 v47 = GUIWindow::Create(0, 0, 640, 480, WINDOW_HouseInterior, 165, 0);
730 window_SpeakInHouse = v47; 730 window_SpeakInHouse = v47;
1239 //v6 = v123; 1239 //v6 = v123;
1240 //v7 = ""; 1240 //v7 = "";
1241 break; 1241 break;
1242 case EVENT_StatusText: 1242 case EVENT_StatusText:
1243 v90 = _evt->v5 + ((_evt->v6 + ((_evt->v7 + ((uint)_evt->v8 << 8)) << 8)) << 8); 1243 v90 = _evt->v5 + ((_evt->v6 + ((_evt->v7 + ((uint)_evt->v8 << 8)) << 8)) << 8);
1244 if ( GlobalEventInfo ) 1244 if ( activeLevelDecoration )
1245 { 1245 {
1246 if ( GlobalEventInfo == 1 ) 1246 if ( activeLevelDecoration == (void*)1 )
1247 { 1247 {
1248 ptr_F8B1E8 = pNPCTopics[v90-1].pText;//(&dword_721664)[8 * v90]; 1248 ptr_F8B1E8 = pNPCTopics[v90-1].pText;//(&dword_721664)[8 * v90];
1249 ++curr_seq_num; 1249 ++curr_seq_num;
1250 v4 = v124; 1250 v4 = v124;
1251 1251
1286 //v6 = v123; 1286 //v6 = v123;
1287 //v7 = ""; 1287 //v7 = "";
1288 break; 1288 break;
1289 case EVENT_ShowMessage: 1289 case EVENT_ShowMessage:
1290 v92 = _evt->v5 + ((_evt->v6 + ((_evt->v7 + ((uint)_evt->v8 << 8)) << 8)) << 8); 1290 v92 = _evt->v5 + ((_evt->v6 + ((_evt->v7 + ((uint)_evt->v8 << 8)) << 8)) << 8);
1291 if ( GlobalEventInfo ) 1291 if ( activeLevelDecoration )
1292 { 1292 {
1293 v93 = (char *)pNPCTopics[v92-1].pText;//(&dword_721664)[8 * v92]; 1293 v93 = (char *)pNPCTopics[v92-1].pText;//(&dword_721664)[8 * v92];
1294 byte_5B0938[0] = 0; 1294 byte_5B0938[0] = 0;
1295 ptr_F8B1E8 = v93; 1295 ptr_F8B1E8 = v93;
1296 } 1296 }
1439 pAudioPlayer->PlaySound((SoundID)v106, v107, v108, v109, v110, v111, v116, v120); 1439 pAudioPlayer->PlaySound((SoundID)v106, v107, v108, v109, v110, v111, v116, v120);
1440 } 1440 }
1441 } 1441 }
1442 else 1442 else
1443 { 1443 {
1444 pGameLoadingUI_ProgressBar->uType = (GUIProgressBar::Type)((GlobalEventInfo == 0) + 1); 1444 pGameLoadingUI_ProgressBar->uType = (GUIProgressBar::Type)((activeLevelDecoration == NULL) + 1);
1445 sub_44987B(v99, 0); 1445 sub_44987B(v99, 0);
1446 v133 = 1; 1446 v133 = 1;
1447 if ( pCurrentScreen == SCREEN_HOUSE ) 1447 if ( pCurrentScreen == SCREEN_HOUSE )
1448 { 1448 {
1449 if ( uGameState == 2 ) 1449 if ( uGameState == 2 )