Changeset 336 for trunk/GameServer.pas
- Timestamp:
- Mar 31, 2021, 10:49:44 PM (4 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/GameServer.pas
r328 r336 15 15 FirstBookCompatibleVersion = $010103; 16 16 17 // notifications18 ntCreateWorld = 0;19 ntInitModule = $100;20 ntInitLocalHuman = $1FF;21 ntDLLError = $200;22 ntAIError = $2FF;23 ntClientError = $300;24 ntInitPlayers = $400;25 ntDeactivationMissing = $410;26 ntSetAIName = $420;27 ntException = $500;28 ntLoadBegin = $600;29 ntLoadState = $601;30 ntEndInfo = $6FC;31 ntBackOn = $6FD;32 ntBackOff = $6FE;33 ntLoadError = $6FF;34 ntStartDone = $700;35 ntStartGo = $701;36 ntStartGoRefresh = $702;37 ntStartGoRefreshMaps = $703;38 ntChangeClient = $800;39 ntNextPlayer = $810;40 ntDeinitModule = $900;41 42 17 // module flags 43 18 fMultiple = $10000000; … … 48 23 49 24 type 50 TNotifyFunction = procedure(ID: integer); 25 // notifications 26 TNotify = ( 27 ntCreateWorld = 0, 28 ntInitModule = $100, 29 ntInitLocalHuman = $1FF, 30 ntDLLError = $200, 31 ntAIError = $2FF, 32 ntClientError = $300, 33 ntInitPlayers = $400, 34 ntDeactivationMissing = $410, 35 ntSetAIName = $420, 36 ntException = $500, 37 ntLoadBegin = $600, 38 ntLoadState = $601, 39 ntEndInfo = $6FC, 40 ntBackOn = $6FD, 41 ntBackOff = $6FE, 42 ntLoadError = $6FF, 43 ntStartDone = $700, 44 ntStartGo = $701, 45 ntStartGoRefresh = $702, 46 ntStartGoRefreshMaps = $703, 47 ntChangeClient = $800, 48 ntNextPlayer = $810, 49 ntDeinitModule = $900 50 ); 51 52 TNotifyFunction = procedure(ID: TNotify; Index: Integer = 0); 51 53 52 54 TBrainType = (btNoTerm, btSuperVirtual, btTerm, btRandom, btAI); … … 365 367 (CCPlayer < 0) then 366 368 begin 367 Notify(ntDeactivationMissing +p);369 Notify(ntDeactivationMissing, p); 368 370 ForceClientDeactivation; 369 371 end … … 513 515 if Kind = btAI then 514 516 begin { get client function } 515 Notify(ntInitModule +Brains.IndexOf(bix));517 Notify(ntInitModule, Brains.IndexOf(bix)); 516 518 if Flags and fDotNet > 0 then 517 519 Client := DotNetClient … … 522 524 begin 523 525 Client := nil; 524 Notify(ntDLLError +Brains.IndexOf(bix));526 Notify(ntDLLError, Brains.IndexOf(bix)); 525 527 end 526 528 else … … 528 530 Client := GetProcAddress(hm, 'client'); 529 531 if @Client = nil then 530 Notify(ntClientError +Brains.IndexOf(bix));531 end 532 end 532 Notify(ntClientError, Brains.IndexOf(bix)); 533 end; 534 end; 533 535 end; 534 536 if @Client <> nil then … … 545 547 DataSize := 0; 546 548 Flags := Flags or InitModuleData.Flags; 547 end 548 end 549 end; 550 end; 549 551 end; 550 552 … … 730 732 if bix[0].Kind <> btNoTerm then 731 733 Notify(ntInitLocalHuman); 734 732 735 BrainUsed := []; 733 736 for p := 0 to nPl - 1 do … … 955 958 else 956 959 NotifyMessage := ''; 957 Notify(ntSetAIName +p1);958 end 960 Notify(ntSetAIName, p1); 961 end; 959 962 end; 960 963 … … 1278 1281 end; 1279 1282 if not MovieMode then 1280 Notify(ntLoadState +CL.Progress * 128 div 1000);1283 Notify(ntLoadState, CL.Progress * 128 div 1000); 1281 1284 end; 1282 1285 … … 3250 3253 begin 3251 3254 if Brains[i].Kind = btAI then 3252 Notify(ntDeinitModule +i);3255 Notify(ntDeinitModule, i); 3253 3256 CallClient(i, cBreakGame, nil^); 3254 3257 end;
Note:
See TracChangeset
for help on using the changeset viewer.