Changeset 614
- Timestamp:
- Sep 14, 2024, 5:43:37 PM (2 months ago)
- Location:
- trunk
- Files:
-
- 13 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/GameServer.pas
r604 r614 75 75 MovieMode: Boolean): Boolean; 76 76 procedure EditMap(const AMapFileName: string; Newlx, Newly, NewLandMass: Integer); 77 procedure FillMap(TerrainType: Cardinal); 77 78 procedure DirectHelp(Command: Integer); 78 79 function ToAutoSaveFileName(FileName: string): string; … … 1363 1364 Notify(ntBackOff); 1364 1365 Inform(pTurn); 1365 ChangeClientWhenDone(cTurn, 0, nil^, 0) 1366 ChangeClientWhenDone(cTurn, 0, nil^, 0); 1367 end; 1368 1369 procedure FillMap(TerrainType: Cardinal); 1370 var 1371 Loc1: Integer; 1372 begin 1373 for Loc1 := 0 to MapSize - 1 do 1374 RealMap[Loc1] := TerrainType or ($F shl 27); 1366 1375 end; 1367 1376 … … 1375 1384 procedure EditMap(const AMapFileName: string; Newlx, Newly, NewLandMass: Integer); 1376 1385 var 1377 p1 , Loc1: Integer;1386 p1: Integer; 1378 1387 Game: TNewGameData; 1379 1388 Map: TMap; … … 1402 1411 FreeAndNil(Map); 1403 1412 end else begin 1404 for Loc1 := 0 to MapSize - 1 do 1405 RealMap[Loc1] := fOcean or ($F shl 27); 1413 FillMap(fOcean); 1406 1414 end; 1407 1415 CL := nil; … … 3069 3077 3070 3078 sRandomMap: 3071 if (Player = 0) and MapGeneratorAvailable then 3072 begin 3079 if (Player = 0) and MapGeneratorAvailable then begin 3073 3080 CreateElevation; 3074 3081 PreviewElevation := False; … … 3076 3083 FillChar(ObserveLevel, MapSize * 4, 0); 3077 3084 DiscoverAll(Player, lObserveSuper); 3078 end 3079 else 3080 Result := eInvalid; 3085 end else Result := eInvalid; 3086 3087 sFillMap: 3088 if Player = 0 then begin 3089 FillMap(TFillMapData(Data).Tile); 3090 FillChar(ObserveLevel, MapSize * 4, 0); 3091 DiscoverAll(Player, lObserveSuper); 3092 end else Result := eInvalid; 3081 3093 3082 3094 sMapGeneratorRequest: -
trunk/Language.txt
r473 r614 421 421 #MAP_PREFSTART Preferred Starting Position 422 422 #MAP_RANDOM Do you want to dismiss this map and replace it by an automatically generated random map? 423 #MAP_FILL Do you want to dismiss this map and replace it by an automatically filled map? 423 424 #MAP_CLOSE You're going to close this map.\Do you wish to save it? 424 425 … … 551 552 Previous Unit 552 553 Next Unit 554 Filled Map 553 555 554 556 #ADVANCES -
trunk/LocalPlayer/KeyBindings.pas
r468 r614 57 57 BResign: TKeyBinding; 58 58 BRandomMap: TKeyBinding; 59 BFillMap: TKeyBinding; 59 60 BDisbandUnit: TKeyBinding; 60 61 BFortify: TKeyBinding; … … 321 322 BResign := AddItem('Resign', 'Resign', 'Ctrl+Q'); 322 323 BRandomMap := AddItem('RandomMap', 'Random map', 'Ctrl+R'); 324 BFillMap := AddItem('FillMap', 'Fill map', 'Ctrl+F'); 323 325 BDisbandUnit := AddItem('DisbandUnit', 'Disband unit', 'Ctrl+D'); 324 326 BFortify := AddItem('Fortify', 'Fortify', 'F'); -
trunk/LocalPlayer/Term.lfm
r533 r614 14 14 DesignTimePPI = 144 15 15 Font.Color = clWindowText 16 Font.Height = - 2016 Font.Height = -45 17 17 Font.Name = 'MS Sans Serif' 18 18 KeyPreview = True … … 31 31 OnShow = FormShow 32 32 Position = poDefault 33 LCLVersion = ' 2.2.0.4'33 LCLVersion = '3.4.0.0' 34 34 Scaled = False 35 WindowState = wsNormal36 35 object UnitBtn: TButtonB 37 36 Tag = 14 … … 555 554 OnClick = mRandomMapClick 556 555 end 556 object mFillMap: TMenuItem 557 Tag = 102 558 GroupIndex = 1 559 ShortCut = 16454 560 OnClick = mFillMapClick 561 end 557 562 object N3: TMenuItem 558 563 Caption = '-' -
trunk/LocalPlayer/Term.pas
r613 r614 12 12 {$ENDIF} 13 13 Protocol, Tribes, PVSB, ClientTools, ScreenTools, BaseWin, Messg, ButtonBase, 14 LCLIntf, LCLType, SysUtils, Classes, DrawDlg, Types, Math,14 LCLIntf, LCLType, Menus, SysUtils, Classes, DrawDlg, Types, Math, 15 15 DateUtils, Platform, ButtonB, ButtonC, EOTButton, Area, 16 16 GraphicSet, MiniMap, IsoEngine, Wonders, TechTree, Enhance, Nego, CityType, … … 34 34 TMainScreen = class(TDrawDlg) 35 35 mBigTiles: TMenuItem; 36 mFillMap: TMenuItem; 36 37 mNextUnit: TMenuItem; 37 38 N13: TMenuItem; … … 197 198 procedure mDiagramClick(Sender: TObject); 198 199 procedure mEmpireClick(Sender: TObject); 200 procedure mFillMapClick(Sender: TObject); 199 201 procedure mEnhanceClick(Sender: TObject); 200 202 procedure mEnhanceDefClick(Sender: TObject); … … 3761 3763 end; 3762 3764 3765 procedure TMainScreen.mFillMapClick(Sender: TObject); 3766 var 3767 FillMapData: TFillMapData; 3768 begin 3769 if not Edited or (SimpleQuery(mkYesNo, Phrases.Lookup('MAP_FILL'), '') 3770 = mrOK) then begin 3771 FillMapData.Tile := BrushType; 3772 Server(sFillMap, Me, 0, FillMapData); 3773 Edited := True; 3774 MapValid := False; 3775 PaintAllMaps; 3776 end; 3777 end; 3778 3763 3779 procedure TMainScreen.mEnhanceClick(Sender: TObject); 3764 3780 begin … … 5220 5236 end; 5221 5237 end; 5222 Inc(Count) 5238 Inc(Count); 5223 5239 end; 5224 5240 end; // for uix:=0 to MyRO.nUn-1 … … 5270 5286 JobFocus := nJob + 3 5271 5287 else 5272 JobFocus := nJob + 4 5288 JobFocus := nJob + 4; 5273 5289 end; 5274 5290 S := Phrases.Lookup('JOBRESULT', JobFocus); … … 5294 5310 (PanelHeight - 1), Left + Width, Top + Height - Self.ClientHeight + 5295 5311 PanelHeight, MainTexture.ColorBevelShade, MainTexture.ColorBevelLight) 5296 end; { if TroopLoc >=0 }5312 end; { if TroopLoc >= 0 } 5297 5313 end; 5298 5314 … … 5332 5348 xTreasurySection := ClientWidth div 2 - 172; 5333 5349 xResearchSection := ClientWidth div 2; 5334 // ClientWidth div 2 +68 = maximum to right5350 // ClientWidth div 2 + 68 = maximum to right 5335 5351 FillLarge(TopBar.Canvas, 0, 0, ClientWidth, TopBarHeight - 3, 5336 5352 ClientWidth div 2); … … 5422 5438 if ScienceSum > 0 then 5423 5439 begin 5424 { j :=(i-MyRO.Research-1) div ScienceSum +1;5425 if J <1 then J:=1;5426 if J >1 then5427 S :=Format(Phrases.Lookup('TECHWAIT'),[S,J]); }5440 { j := (i - MyRO.Research - 1) div ScienceSum + 1; 5441 if J < 1 then J := 1; 5442 if J > 1 then 5443 S := Format(Phrases.Lookup('TECHWAIT'), [S, J]); } 5428 5444 LoweredTextOut(TopBar.Canvas, -1, MainTexture, 5429 5445 xResearchSection + 48, 0, S); … … 7003 7019 mResign.ShortCut := BResign.ShortCut; 7004 7020 mRandomMap.ShortCut := BRandomMap.ShortCut; 7021 mFillMap.ShortCut := BFillMap.ShortCut; 7005 7022 mDisband.ShortCut := BDisbandUnit.ShortCut; 7006 7023 mFort.ShortCut := BFortify.ShortCut; … … 7122 7139 if BResign.Test(ShortCut) then mResign.Click 7123 7140 else if BRandomMap.Test(ShortCut) then mRandomMap.Click 7141 else if BFillMap.Test(ShortCut) then mFillMap.Click 7124 7142 else if BHelp.Test(ShortCut) then mHelp.Click; 7125 7143 (*if Shift = [ssCtrl] then … … 7474 7492 mRandomMap.Visible := (ClientMode = cEditMap) and 7475 7493 (Server(sMapGeneratorRequest, Me, 0, nil^) = eOK); 7494 mFillMap.Visible := mRandomMap.Visible; 7476 7495 mOptions.Visible := ClientMode <> cEditMap; 7477 7496 mManip.Visible := ClientMode <> cEditMap; -
trunk/Localization/cs/Language.txt
r473 r614 421 421 #MAP_PREFSTART Preferovaná startovní pozice 422 422 #MAP_RANDOM Chcete zrušit tuto mapu a nahradit ji automaticky vygenerovanou mapou? 423 #MAP_FILL Chcete zrušit tuto mapu a nahradit ji automaticky vyplněnou mapou? 423 424 #MAP_CLOSE Chystáte se zavřít tuto mapu.\Chcete ji uložit? 424 425 … … 551 552 Předchozí jednotka 552 553 Další jednotka 554 Vyplněná mapa 553 555 554 556 #ADVANCES -
trunk/Localization/de/Language.txt
r473 r614 430 430 #MAP_PREFSTART Bevorzugte Startposition 431 431 #MAP_RANDOM Karte löschen und durch eine automatisch erstellte Zufallskarte ersetzen? 432 #MAP_FILL Do you want to dismiss this map and replace it by an automatically filled map? 432 433 #MAP_CLOSE Der Kartograf wird beendet.\Soll die Karte gespeichert werden? 433 434 … … 560 561 Previous Unit 561 562 Next Unit 563 Filled Map 562 564 563 565 #ADVANCES -
trunk/Localization/fr/Language.txt
r544 r614 140 140 #TITLE_SPYMISSION Opération secrète 141 141 #TITLE_SUICIDE Mission suicide 142 #TITLE_MESSAGE Message 142 143 #FRMILREP Rapport militaire 143 144 144 'Message Text 145 145 #NOALTAI Aucune autre IA n'est installée.\Téléchargez d'autres modules d'IA à partir de la page d'accueil de C-evo ou créez le vôtre. … … 406 406 #UTILIZE Utilisez 407 407 #INTEGRATE Intégrer 408 #NETWORK_SERVER Network Server 409 #NETWORK_CLIENT Network Client 408 410 409 411 'Busy Messages … … 418 420 #MAP_PREFSTART Position de départ préférée 419 421 #MAP_RANDOM Voulez-vous rejeter cette carte et la remplacer par une carte aléatoire générée automatiquement? 422 #MAP_FILL Do you want to dismiss this map and replace it by an automatically filled map? 420 423 #MAP_CLOSE Vous allez fermer cette carte.\Souhaitez-vous la sauvegarder? 421 424 … … 543 546 Patrouilles, attaques et captures uniquement 544 547 Taille des carreaux 548 Small 549 Medium 550 Big 551 Previous Unit 552 Next Unit 553 Filled Map 545 554 546 555 #ADVANCES -
trunk/Localization/it/Language.txt
r473 r614 411 411 #MAP_PREFSTART Punto di partenza preferenziale 412 412 #MAP_RANDOM Vuoi buttare via questa mappa e rimpiazzarla con una generata casualmente? 413 #MAP_FILL Do you want to dismiss this map and replace it by an automatically filled map? 413 414 #MAP_CLOSE Stai chiudendo questa mappa.\La vuoi salvare? 414 415 … … 541 542 Previous Unit 542 543 Next Unit 544 Filled Map 543 545 544 546 #ADVANCES -
trunk/Localization/ru/Language.txt
r473 r614 437 437 #MAP_PREFSTART Привилегированная исходная позиция 438 438 #MAP_RANDOM Вы хотите отказаться от этой карты и заменить её случайно сгенерированной картой? 439 #MAP_FILL Do you want to dismiss this map and replace it by an automatically filled map? 439 440 #MAP_CLOSE Вы собираетесь закрыть Карту.\Вы хотите сохранить изменения? 440 441 … … 567 568 Previous Unit 568 569 Next Unit 570 Filled Map 569 571 570 572 #ADVANCES -
trunk/Localization/zh-Hans/Language.txt
r473 r614 429 429 #MAP_PREFSTART 玩家种族初始位置 430 430 #MAP_RANDOM 放弃当前的地图, 重新随机生成新的地图? 431 #MAP_FILL Do you want to dismiss this map and replace it by an automatically filled map? 431 432 #MAP_CLOSE 选择关闭当前的地图。\是否保存? 432 433 … … 559 560 Previous Unit 560 561 Next Unit 562 Filled Map 561 563 562 564 #ADVANCES -
trunk/Localization/zh-Hant/Language.txt
r473 r614 429 429 #MAP_PREFSTART 玩家种族初始位置 430 430 #MAP_RANDOM 放棄當前的地圖, 重新隨机生成新的地圖? 431 #MAP_FILL Do you want to dismiss this map and replace it by an automatically filled map? 431 432 #MAP_CLOSE 選擇關閉當前的地圖。\是否保存? 432 433 … … 559 560 Previous Unit 560 561 Next Unit 562 Filled Map 561 563 562 564 #ADVANCES -
trunk/Protocol.pas
r457 r614 116 116 sRandomMap = $0780; 117 117 sMapGeneratorRequest = $0790; 118 sFillMap = $07a0; 118 119 119 120 // Server Internal Commands … … 1647 1648 mix: Integer; 1648 1649 end; 1650 TFillMapData = record 1651 Tile: Integer; 1652 end; 1649 1653 1650 1654 TTileList = array [0 .. INFIN] of Cardinal;
Note:
See TracChangeset
for help on using the changeset viewer.