Changeset 328
- Timestamp:
- Mar 25, 2021, 3:02:29 PM (4 years ago)
- Location:
- trunk
- Files:
-
- 15 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/AI/StdAI/AI.pas
r319 r328 1122 1122 begin // settlers could be added to this city 1123 1123 Happy := BasicHappy; 1124 for i := 0 to 27do1124 for i := 0 to nWonder - 1 do 1125 1125 if Built[i] > 0 then 1126 1126 Inc(Happy); -
trunk/AI/StdAI/Barbarina.pas
r319 r328 1242 1242 WonderAvailable := WonderAvailable and PrimeWonder; // alway prefer prime wonders 1243 1243 Count := 0; 1244 for iix := 0 to 27do1244 for iix := 0 to nWonder - 1 do 1245 1245 begin 1246 1246 if (1 shl iix) and WonderAvailable <> 0 then … … 1254 1254 end; 1255 1255 Count := Random(Count); 1256 for iix := 0 to 27do1256 for iix := 0 to nWonder - 1 do 1257 1257 begin 1258 1258 if (1 shl iix) and WonderAvailable <> 0 then … … 1326 1326 WonderAvailable := 0; 1327 1327 WonderInWork := 0; 1328 for iix := 0 to 27do1328 for iix := 0 to nWonder - 1 do 1329 1329 if (Imp[iix].Preq <> preNA) and ((Imp[iix].Preq = preNone) or 1330 1330 IsResearched(Imp[iix].Preq)) and (RO.Wonder[iix].CityID = WonderNotBuiltYet) then … … 1334 1334 begin 1335 1335 iix := City_CurrentImprovementProject(cix); 1336 if (iix >= 0) and (iix < 28) then1336 if (iix >= 0) and (iix < nWonder) then 1337 1337 Inc(WonderInWork, 1 shl iix) 1338 1338 else if iix = imPalace then … … 1428 1428 1429 1429 iix := City_CurrentImprovementProject(cix); 1430 if (iix >= 0) and (iix < 28) or (iix = imPalace) or1430 if (iix >= 0) and (iix < nWonder) or (iix = imPalace) or 1431 1431 (iix = imShipComp) or (iix = imShipPow) or (iix = imShipHab) then 1432 1432 City_OptimizeTiles(cix, rwMaxProd) … … 1447 1447 if cix = cixNewCapital then 1448 1448 City_StartImprovement(cix, imPalace) 1449 else if (iix >= 0) and (iix < 28) and ((1 shl iix) and1449 else if (iix >= 0) and (iix < nWonder) and ((1 shl iix) and 1450 1450 WonderAvailable <> 0) then 1451 1451 // complete wonder production first … … 1503 1503 City_StartImprovement(cix, woZeus) 1504 1504 else if (City_CurrentImprovementProject(cix) >= 0) and 1505 (City_CurrentImprovementProject(cix) < 28) then1505 (City_CurrentImprovementProject(cix) < nWonder) then 1506 1506 begin// wonder already built, try to switch to different one 1507 1507 if (WonderAvailable and not WonderInWork > 0) and … … 1553 1553 begin // low prio projects 1554 1554 ImportantCity := WillProduceColonyShip or (Built[imPalace] > 0); 1555 for iix := 0 to 27do1555 for iix := 0 to nWonder - 1 do 1556 1556 if Built[iix] > 0 then 1557 1557 ImportantCity := True; … … 1605 1605 City_RebuildImprovement(cix, imTownHall) 1606 1606 else if (RO.Government = gFundamentalism) and not WillProduceColonyShip then 1607 for iix := 28to nImp - 1 do1607 for iix := nWonder to nImp - 1 do 1608 1608 if (Built[iix] > 0) and 1609 1609 ((iix in [imTemple, imTheater, imCathedral, imColosseum, -
trunk/AI/StdAI/Protocol.pas
r319 r328 11 11 nImp = 70; { number of improvements } 12 12 nPl = 15; { max number of players, don't change! } 13 nWonder = 28; { max number of wonders } 13 14 nUmax = 4096; { max units/player, don't set above 4096 } 14 15 nCmax = 1024; { max cities/player, don't set above 4096 } … … 1291 1292 Flags: Cardinal; 1292 1293 end; 1294 PUn = ^TUn; 1293 1295 1294 1296 { TCity } … … 1314 1316 // array value =1 indicates built improvement 1315 1317 end; 1318 PCity = ^TCity; 1316 1319 1317 1320 TModel = packed record … … 1352 1355 Flags: Word; 1353 1356 end; 1357 PUnitInfo = ^TUnitInfo; 1354 1358 1355 1359 TCityInfo = packed record … … 1362 1366 Flags: Word; 1363 1367 end; 1368 PCityInfo = ^TCityInfo; 1364 1369 1365 1370 TModelInfo = packed record … … 1591 1596 1592 1597 TTileList = array [0 .. INFIN] of Cardinal; 1598 PTileList = ^TTileList; 1593 1599 TTileObservedLastList = array [0 .. INFIN] of SmallInt; 1594 1600 TOwnerList = array [0 .. INFIN] of ShortInt; … … 1645 1651 Tribute: array [0 .. nPl - 1] of Integer; // no longer in use 1646 1652 TributePaid: array [0 .. nPl - 1] of Integer; // no longer in use 1647 Wonder: array [0 .. 27] of TWonderInfo;1653 Wonder: array [0 .. nWonder - 1] of TWonderInfo; 1648 1654 Ship: array [0 .. nPl - 1] of TShipInfo; 1649 NatBuilt: array [ 28.. (nImp + 3) div 4 * 4 - 1] of ShortInt;1655 NatBuilt: array [nWonder .. (nImp + 3) div 4 * 4 - 1] of ShortInt; 1650 1656 nBattleHistory: Integer; 1651 1657 BattleHistory: ^TBattleList; // complete list of all my battles in the whole game -
trunk/AI/StdAI/ToolAI.pas
r289 r328 234 234 Inc(Result, CityReport.FoodRep - CityReport.Eaten); 235 235 end; 236 for i := 28to nImp - 1 do236 for i := nWonder to nImp - 1 do 237 237 if MyCity[cix].Built[i] > 0 then 238 238 Dec(Result, Imp[i].Maint); -
trunk/CityProcessing.pas
r319 r328 292 292 begin { improvement project } 293 293 result := Imp[Project and cpIndex].Cost; 294 if (Project and cpIndex < 28) and (GWonder[woColossus].EffectiveOwner = p)294 if (Project and cpIndex < nWonder) and (GWonder[woColossus].EffectiveOwner = p) 295 295 then 296 296 result := result * ColossusEffect div 100; … … 370 370 BaseHappiness := Size; 371 371 end; 372 for i := 0 to 27do372 for i := 0 to nWonder - 1 do 373 373 if Built[i] = 1 then 374 374 begin … … 773 773 begin 774 774 with RW[p], City[cix] do 775 for i := 28to nImp - 1 do775 for i := nWonder to nImp - 1 do 776 776 if (Built[i] > 0) and (Project0 and (cpImp or cpIndex) <> (cpImp or i)) 777 777 then // don't pay maintenance when just completed … … 971 971 972 972 // check if wonder already built 973 if (Project and cpImp <> 0) and (Project and cpIndex < 28) and973 if (Project and cpImp <> 0) and (Project and cpIndex < nWonder) and 974 974 (GWonder[Project and cpIndex].CityID <> WonderNotBuiltYet) then 975 975 begin … … 1050 1050 end; 1051 1051 1052 if NewImp < 28then1052 if NewImp < nWonder then 1053 1053 begin // wonder 1054 1054 GWonder[NewImp].CityID := ID; … … 1060 1060 woEiffel: 1061 1061 begin // reactivate wonders 1062 for i := 0 to 27do1062 for i := 0 to nWonder - 1 do 1063 1063 if Imp[i].Expiration >= 0 then 1064 1064 for cix2 := 0 to nCity - 1 do … … 1303 1303 dxdy(Loc, Loc1, dx, dy); 1304 1304 dec(SubCriterion[(dy + 3) shl 2 + (dx + 3) shr 1], 160); 1305 end 1306 end 1307 end 1308 end 1305 end; 1306 end; 1307 end; 1308 end; 1309 1309 end; 1310 1310 … … 1414 1414 Hierarchy[iH, iT].Trade := TileInfo.Trade; 1415 1415 Hierarchy[iH, iT].SubValue := SubCriterion[V21]; 1416 end 1416 end; 1417 1417 end; 1418 1418 if NeedRare <> 0 then -
trunk/Database.pas
r319 r328 49 49 GTestFlags: Integer; 50 50 Mode: TGameMode; 51 GWonder: array [0 .. 27] of TWonderInfo;51 GWonder: array [0 .. nWonder - 1] of TWonderInfo; 52 52 ServerVersion: array [0 .. nPl - 1] of integer; 53 53 ProcessClientData: array [0 .. nPl - 1] of boolean; … … 452 452 ResourceMask[p] := ResourceMask[p] or fModern; 453 453 454 for i := 0 to 27do { check whether wonders expired }454 for i := 0 to nWonder - 1 do { check whether wonders expired } 455 455 if (GWonder[i].EffectiveOwner <> GWonder[woEiffel].EffectiveOwner) and 456 456 (Imp[i].Expiration = ad) then … … 3149 3149 i, j, uix1, cix1, nearest: integer; 3150 3150 begin 3151 for i := 0 to 27do3151 for i := 0 to nWonder - 1 do 3152 3152 if RW[p].City[cix].Built[i] = 1 then 3153 3153 begin … … 3156 3156 FreeSlaves; 3157 3157 if i = woEiffel then // deactivate expired wonders 3158 for j := 0 to 27do3158 for j := 0 to nWonder - 1 do 3159 3159 if GWonder[j].EffectiveOwner = p then 3160 3160 CheckExpiration(j); 3161 3161 end; 3162 for i := 28to nImp - 1 do3162 for i := nWonder to nImp - 1 do 3163 3163 if (Imp[i].Kind <> ikCommon) and (RW[p].City[cix].Built[i] > 0) then 3164 3164 begin { destroy national projects } … … 3191 3191 begin 3192 3192 StealCity(p, cix, SaveUnits); 3193 with RW[p].City[cix] do 3194 begin 3195 for i := 0 to 27 do 3193 with RW[p].City[cix] do begin 3194 for i := 0 to nWonder - 1 do 3196 3195 if Built[i] > 0 then 3197 3196 GWonder[i].CityID := WonderDestroyed; … … 3243 3242 Built[imTownHall] := 0; 3244 3243 Built[imCourt] := 0; 3245 for i := 28to nImp - 1 do3244 for i := nWonder to nImp - 1 do 3246 3245 if Imp[i].Kind <> ikCommon then 3247 3246 Built[i] := 0; { destroy national projects } 3248 for i := 0 to 27do3247 for i := 0 to nWonder - 1 do 3249 3248 if Built[i] = 1 then 3250 3249 begin // new wonder owner! … … 3252 3251 if i = woEiffel then // reactivate expired wonders 3253 3252 begin 3254 for j := 0 to 27do3253 for j := 0 to nWonder - 1 do 3255 3254 if Imp[j].Expiration >= 0 then 3256 3255 for cix1 := 0 to (RW[pNew].nCity - 1) do 3257 3256 if RW[pNew].City[cix1].Built[j] = 1 then 3258 GWonder[j].EffectiveOwner := pNew 3257 GWonder[j].EffectiveOwner := pNew; 3259 3258 end 3260 3259 else -
trunk/GameServer.pas
r326 r328 788 788 789 789 GTurn := 0; 790 for i := 0 to 27do790 for i := 0 to nWonder - 1 do 791 791 with GWonder[i] do 792 792 begin … … 4212 4212 else if built[NewProject and cpIndex] > 0 then 4213 4213 result := eInvalid 4214 else if (NewProject and cpIndex < 28) and4214 else if (NewProject and cpIndex < nWonder) and 4215 4215 (GWonder[NewProject and cpIndex].CityID <> WonderNotBuiltYet) then 4216 4216 result := eViolation // wonder already exists -
trunk/LocalPlayer/CityScreen.pas
r325 r328 325 325 for i := 0 to 29 do 326 326 begin 327 for iix := 28to nImp - 1 do327 for iix := nWonder to nImp - 1 do 328 328 if (ImpPosition[iix] = i) and (c.Built[iix] > 0) then 329 329 begin … … 336 336 i := 30; 337 337 for iix := 0 to nImp do 338 if (c.Built[iix] > 0) and ((iix < 28) or (ImpPosition[iix] < 0)) then338 if (c.Built[iix] > 0) and ((iix < nWonder) or (ImpPosition[iix] < 0)) then 339 339 begin 340 340 FillRect(Rect(5 + 16 * (i mod 3) + 48 * (i div 18), … … 350 350 if iix <> imTrGoods then 351 351 begin 352 if (iix >= 28) and (ImpPosition[iix] >= 0) then352 if (iix >= nWonder) and (ImpPosition[iix] >= 0) then 353 353 i := ImpPosition[iix]; 354 354 if i < 36 then … … 827 827 Cnt := 0; 828 828 for iix := 0 to nImp - 1 do 829 if ((iix < 28) or (ImpPosition[iix] < 0)) and (c.Built[iix] > 0) then829 if ((iix < nWonder) or (ImpPosition[iix] < 0)) and (c.Built[iix] > 0) then 830 830 begin 831 831 i := Cnt - Page * 6; … … 838 838 else 839 839 begin 840 for iix := 28to nImp - 1 do840 for iix := nWonder to nImp - 1 do 841 841 begin 842 842 i := ImpPosition[iix] - 6 * ZoomArea; -
trunk/LocalPlayer/CityType.pas
r188 r328 158 158 159 159 nPool := 0; 160 for iix := 28to nImp - 1 do160 for iix := nWonder to nImp - 1 do 161 161 if not(iix in listed) and (Imp[iix].Kind = ikCommon) and (iix <> imTrGoods) 162 162 and (Imp[iix].Preq <> preNA) and -
trunk/LocalPlayer/ClientTools.pas
r327 r328 261 261 Inc(Result, CityReport.FoodSurplus); 262 262 end; 263 for i := 28to nImp - 1 do263 for i := nWonder to nImp - 1 do 264 264 if MyCity[cix].Built[i] > 0 then 265 265 Dec(Result, Imp[i].Maint); -
trunk/LocalPlayer/Help.pas
r318 r328 1484 1484 hkMisc + hkCrossLink, miscGovList); 1485 1485 NextSection('BUILDALLOW'); 1486 for i := 0 to 27do1486 for i := 0 to nWonder - 1 do 1487 1487 if Imp[i].Preq = no then 1488 1488 AddImprovement(i); 1489 for i := 28to nImp - 1 do1489 for i := nWonder to nImp - 1 do 1490 1490 if (Imp[i].Preq = no) and (Imp[i].Kind <> ikCommon) then 1491 1491 AddImprovement(i); 1492 for i := 28to nImp - 1 do1492 for i := nWonder to nImp - 1 do 1493 1493 if (Imp[i].Preq = no) and (Imp[i].Kind = ikCommon) then 1494 1494 AddImprovement(i); … … 1527 1527 end; 1528 1528 NextSection('EXPIRATION'); 1529 for i := 0 to 27do1529 for i := 0 to nWonder - 1 do 1530 1530 if (Imp[i].Preq <> preNA) and (Imp[i].Expiration = no) then 1531 1531 AddImprovement(i); … … 1545 1545 List := THyperText.Create; 1546 1546 List.OwnsObjects := True; 1547 for i := 28to nImp - 1 do1547 for i := nWonder to nImp - 1 do 1548 1548 if (i <> imTrGoods) and (Imp[i].Preq <> preNA) and 1549 1549 (Imp[i].Kind = ikCommon) then … … 1558 1558 Caption := HelpText.Lookup('HELPTITLE_UNIQUELIST'); 1559 1559 // AddLine(HelpText.Lookup('HELPTITLE_UNIQUELIST'),pkSection); 1560 for i := 28to nImp - 1 do1560 for i := nWonder to nImp - 1 do 1561 1561 if (Imp[i].Preq <> preNA) and 1562 1562 ((Imp[i].Kind = ikNatLocal) or (Imp[i].Kind = ikNatGlobal)) then … … 1566 1566 LineFeed; 1567 1567 AddLine(HelpText.Lookup('HELPTITLE_SHIPPARTLIST'),pkSection); 1568 for i:= 28to nImp-1 do1568 for i:= nWonder to nImp-1 do 1569 1569 if (Imp[i].Preq<>preNA) and (Imp[i].Kind=ikShipPart) then 1570 1570 AddLine(Phrases.Lookup('IMPROVEMENTS',i),pkSmallIcon,i,hkImp,i); } … … 1574 1574 Caption := HelpText.Lookup('HELPTITLE_WONDERLIST'); 1575 1575 // AddLine(HelpText.Lookup('HELPTITLE_WONDERLIST'),pkSection); 1576 for i := 0 to 27do1576 for i := 0 to nWonder - 1 do 1577 1577 if Imp[i].Preq <> preNA then 1578 1578 AddLine(Phrases.Lookup('IMPROVEMENTS', i), pkSmallIcon, i, … … 1600 1600 AddFeature(mcAcademy); 1601 1601 end; 1602 if (no < 28) and not Phrases2FallenBackToEnglish then1602 if (no < nWonder) and not Phrases2FallenBackToEnglish then 1603 1603 begin 1604 1604 LineFeed; … … 1646 1646 [Phrases.Lookup('TERRAIN', 3 * 12 + i)]), pkTer, 3 * 12 + i); 1647 1647 end; 1648 if (no < 28) and (Imp[no].Expiration >= 0) then1648 if (no < nWonder) and (Imp[no].Expiration >= 0) then 1649 1649 begin 1650 1650 NextSection('EXPIRATION'); … … 1656 1656 end; 1657 1657 NextSection('SEEALSO'); 1658 if (no < 28) and (Imp[no].Expiration >= 0) then1658 if (no < nWonder) and (Imp[no].Expiration >= 0) then 1659 1659 AddImprovement(woEiffel); 1660 1660 for i := 0 to nImpReplacement - 1 do -
trunk/LocalPlayer/Select.pas
r318 r328 1068 1068 code[0, 0] := cpImp + imTrGoods; 1069 1069 Lines[0] := 1; 1070 for i := 28to nImp - 1 do1070 for i := nWonder to nImp - 1 do 1071 1071 if Imp[i].Kind = ikCommon then 1072 1072 TryAddImpLine(0, i + cpImp); 1073 for i := 28to nImp - 1 do1073 for i := nWonder to nImp - 1 do 1074 1074 if not(Imp[i].Kind in [ikCommon, ikTrGoods]) and 1075 1075 ((MyRO.NatBuilt[i] = 0) or (Imp[i].Kind = ikNatLocal)) then … … 1083 1083 1084 1084 // wonders 1085 for i := 0 to 27do1085 for i := 0 to nWonder - 1 do 1086 1086 TryAddImpLine(1, i + cpImp); 1087 1087 -
trunk/LocalPlayer/Term.pas
r327 r328 458 458 EnhancementJobs: TEnhancementJobs; 459 459 ImpOrder: array [0 .. nCityType - 1] of TImpOrder; 460 ToldWonders: array [0 .. 27] of TWonderInfo;460 ToldWonders: array [0 .. nWonder - 1] of TWonderInfo; 461 461 ToldTech: array [0 .. nAdv - 1] of ShortInt; 462 462 end; … … 469 469 DeliveredPrices: TPriceSet; 470 470 ReceivedPrices: TPriceSet; 471 end; 472 473 TCurrentMoveInfo = record 474 AfterMovePaintRadius: Integer; 475 AfterAttackExpeller: Integer; 476 DoShow: Boolean; 477 IsAlly: Boolean; 471 478 end; 472 479 … … 568 575 569 576 var 570 Jump: array [0 .. nPl - 1] of integer; 571 pTurn, pLogo, UnStartLoc, ToldSlavery: integer; 572 SmallScreen, GameOK, MapValid, skipped, idle: boolean; 573 574 SaveOption: array of integer; 575 MiniColors: array [0..11, 0..1] of TColor; 577 Jump: array [0 .. nPl - 1] of Integer; 578 pTurn: Integer; 579 pLogo: Integer; 580 UnStartLoc: Integer; 581 ToldSlavery: Integer; 582 SmallScreen: Boolean; 583 GameOK: Boolean; 584 MapValid: Boolean; 585 Skipped: Boolean; 586 Idle: Boolean; 587 588 SaveOption: array of Integer; 576 589 MainMap: TIsoMap; 577 CurrentMoveInfo: record AfterMovePaintRadius, AfterAttackExpeller: integer; 578 DoShow, IsAlly: boolean; 579 end; 590 CurrentMoveInfo: TCurrentMoveInfo; 580 591 581 592 function CityEventName(i: integer): string; … … 1070 1081 begin 1071 1082 result := false; 1072 exit 1083 exit; 1073 1084 end; 1074 1085 ChosenResearch := ModalSelectDlg.result; … … 1396 1407 begin 1397 1408 need := false; 1398 for i := 0 to 27do1409 for i := 0 to nWonder - 1 do 1399 1410 if MyRO.Wonder[i].CityID <> WonderNotBuiltYet then 1400 1411 need := true; … … 1492 1503 $FF - Tribe[i].Color and $FF) * 2; 1493 1504 if TestColorDistance < ColorDistance then 1494 ColorDistance := TestColorDistance 1505 ColorDistance := TestColorDistance; 1495 1506 end; 1496 1507 if ColorDistance > BestColorDistance then 1497 1508 begin 1498 1509 CountBest := 0; 1499 BestColorDistance := ColorDistance 1510 BestColorDistance := ColorDistance; 1500 1511 end; 1501 1512 if ColorDistance = BestColorDistance then … … 1503 1514 inc(CountBest); 1504 1515 if DelphiRandom(CountBest) = 0 then 1505 result := j 1516 result := j; 1506 1517 end; 1507 1518 end; … … 1574 1585 begin 1575 1586 MostCost := TestCost; 1576 IconIndex := imShipComp + i 1587 IconIndex := imShipComp + i; 1577 1588 end; 1578 1589 end; … … 1586 1597 procedure TMainScreen.InitModule; 1587 1598 var 1588 x, y,i, j, Domain: integer;1599 i, j, Domain: integer; 1589 1600 begin 1590 1601 { search icons for advances: } … … 1610 1621 else 1611 1622 AdvIcon[i] := 86 + Domain; 1612 for j := 28to nImp - 1 do1623 for j := nWonder to nImp - 1 do 1613 1624 if Imp[j].Preq = i then 1614 1625 AdvIcon[i] := j; 1615 for j := 28to nImp - 1 do1626 for j := nWonder to nImp - 1 do 1616 1627 if (Imp[j].Preq = i) and (Imp[j].Kind <> ikCommon) then 1617 1628 AdvIcon[i] := j; … … 1619 1630 if i = JobPreq[j] then 1620 1631 AdvIcon[i] := 84; 1621 for j := 0 to 27do1632 for j := 0 to nWonder - 1 do 1622 1633 if Imp[j].Preq = i then 1623 1634 AdvIcon[i] := j; … … 1637 1648 TribeNames := tstringlist.Create; 1638 1649 1639 for x := 0 to 11 do1640 for y := 0 to 1 do1641 MiniColors[x, y] := HGrSystem.Data.Canvas.Pixels[66 + x, 67 + y];1642 1650 IsoEngine.Init(InitEnemyModel); 1643 1651 if not IsoEngine.ApplyTileSize(TileSize) and (TileSize <> tsMedium) then … … 2049 2057 end; 2050 2058 2051 for i := 0 to 27do2059 for i := 0 to nWonder - 1 do 2052 2060 begin 2053 2061 OwnWonder := false; … … 2221 2229 if (MyRO.Turn > 0) and (Loc >= 0) and (Flags and chCaptured = 0) and 2222 2230 (WondersOnly = (Flags and chProduction <> 0) and 2223 (Project0 and cpImp <> 0) and (Project0 and cpIndex < 28)) then2231 (Project0 and cpImp <> 0) and (Project0 and cpIndex < nWonder)) then 2224 2232 begin 2225 2233 if WondersOnly then … … 2602 2610 inc(ToldAlive, 1 shl i); 2603 2611 PeaceEvaHappened := 0; 2604 for i := 0 to 27do2612 for i := 0 to nWonder - 1 do 2605 2613 with ToldWonders[i] do 2606 2614 begin … … 5852 5860 if CityCaptured and (MyMap[ToLoc] and fCity = 0) then 5853 5861 begin // city destroyed 5854 for i := 0 to 27do { tell about destroyed wonders }5862 for i := 0 to nWonder - 1 do { tell about destroyed wonders } 5855 5863 if (MyRO.Wonder[i].CityID = WonderDestroyed) and (MyData.ToldWonders[i].CityID <> WonderDestroyed) 5856 5864 then … … 5874 5882 begin // city captured 5875 5883 ListDlg.AddCity; 5876 for i := 0 to 27do { tell about capture of wonders }5884 for i := 0 to nWonder - 1 do { tell about capture of wonders } 5877 5885 if MyRO.City[MyRO.nCity - 1].Built[i] > 0 then 5878 5886 with MessgExDlg do … … 7183 7191 // check if city types already usefull: 7184 7192 if MyRO.nCity > 0 then 7185 for i := 28to nImp - 1 do7193 for i := nWonder to nImp - 1 do 7186 7194 if (i <> imTrGoods) and (Imp[i].Kind = ikCommon) and 7187 7195 (Imp[i].Preq <> preNA) and … … 7262 7270 mEUnitStat.Enabled := MyRO.nEnemyModel > 0; 7263 7271 { mWonders.Enabled:= false; 7264 for i:=0 to 27do if MyRO.Wonder[i].CityID <> WonderNotBuiltYet then7272 for i:=0 to nWonder - 1 do if MyRO.Wonder[i].CityID <> WonderNotBuiltYet then 7265 7273 mWonders.Enabled:=true; } 7266 7274 mDiagram.Enabled := MyRO.Turn >= 2; -
trunk/Protocol.pas
r326 r328 11 11 nImp = 70; { number of improvements } 12 12 nPl = 15; { max number of players, don't change! } 13 nWonder = 28; { number of wonders } 13 14 nUmax = 4096; { max units/player, don't set above 4096 } 14 15 nCmax = 1024; { max cities/player, don't set above 4096 } … … 1650 1651 Tribute: array [0 .. nPl - 1] of Integer; // no longer in use 1651 1652 TributePaid: array [0 .. nPl - 1] of Integer; // no longer in use 1652 Wonder: array [0 .. 27] of TWonderInfo;1653 Wonder: array [0 .. nWonder - 1] of TWonderInfo; 1653 1654 Ship: array [0 .. nPl - 1] of TShipInfo; 1654 NatBuilt: array [ 28.. (nImp + 3) div 4 * 4 - 1] of ShortInt;1655 NatBuilt: array [nWonder .. (nImp + 3) div 4 * 4 - 1] of ShortInt; 1655 1656 nBattleHistory: Integer; 1656 1657 BattleHistory: ^TBattleList; // complete list of all my battles in the whole game -
trunk/UMiniMap.pas
r327 r328 312 312 else if moPolitical in MapOptions then begin 313 313 // Political 314 if MyMap[Loc] and fTerrain < fGrass then 315 cm := cmPolOcean 316 else if MyRO.Territory[Loc] < 0 then 317 cm := cmPolNone 318 else 319 cm := Tribe[MyRO.Territory[Loc]].Color; 314 if MyMap[Loc] and fTerrain < fGrass then cm := cmPolOcean 315 else if MyRO.Territory[Loc] < 0 then cm := cmPolNone 316 else cm := Tribe[MyRO.Territory[Loc]].Color; 320 317 end; 321 318 MiniPixel.Pixel^.B := (cm shr 16) and $ff;
Note:
See TracChangeset
for help on using the changeset viewer.