Changeset 460 for trunk/LocalPlayer/CityScreen.pas
- Timestamp:
- Nov 28, 2023, 3:16:24 PM (12 months ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LocalPlayer/CityScreen.pas
r456 r460 6 6 uses 7 7 {$IFDEF UNIX}LMessages,{$ENDIF} 8 Protocol, ClientTools, Term, ScreenTools, IsoEngine, BaseWin,9 LCLIntf, LCLType, Messages, SysUtils, Classes, Graphics, Controls, Forms, ExtCtrls,10 Button A, ButtonC, Area, GraphType, Texture;8 Protocol, ClientTools, ScreenTools, IsoEngine, BaseWin, LCLIntf, LCLType, 9 Messages, SysUtils, Classes, Graphics, Controls, Forms, ExtCtrls, ButtonA, 10 ButtonC, Area, GraphType, Texture; 11 11 12 12 const … … 49 49 procedure PrevCityBtnClick(Sender: TObject); 50 50 procedure FormKeyDown(Sender: TObject; var Key: Word; Shift: TShiftState); 51 // procedure AdviceBtnClick(Sender: TObject);52 51 procedure PageUpBtnClick(Sender: TObject); 53 52 procedure PageDownBtnClick(Sender: TObject); … … 101 100 end; 102 101 103 var104 CityDlg: TCityDlg;105 106 102 107 103 implementation 108 104 109 105 uses 110 Select, Messg, MessgEx, Help, Tribes, Directories, Math, Sound ;106 Select, Messg, MessgEx, Help, Tribes, Directories, Math, Sound, Term; 111 107 112 108 {$R *.lfm} … … 205 201 AreaMap.SetPaintBounds(xmArea - 192, ymArea - 96 - 32, xmArea + 192, 206 202 ymArea + 96); 207 SmallMapMode := smImprovements; 208 ZoomArea := 1; 203 Reset; 209 204 ProdHint := False; 210 205 RestoreUnFocus := -1; … … 1171 1166 (X < xView + 73) and (Y < yView + 50) then 1172 1167 if cGov = gAnarchy then 1173 with M essgExDlg do1168 with MainScreen.MessgExDlg do 1174 1169 begin 1175 1170 { MessgText:=Phrases.Lookup('OUTOFCONTROL'); … … 1204 1199 if iix >= 0 then 1205 1200 if ssShift in Shift then 1206 HelpDlg.ShowNewContent(WindowModeMakePersistent(FWindowMode), hkImp, iix)1201 MainScreen.HelpDlg.ShowNewContent(WindowModeMakePersistent(FWindowMode), hkImp, iix) 1207 1202 else if (ClientMode < scContact) then 1208 with M essgExDlg do1203 with MainScreen.MessgExDlg do 1209 1204 begin 1210 1205 IconKind := mikImp; … … 1343 1338 if C.Status and csResourceWeightsMask <> 0 then 1344 1339 begin 1345 with M essgExDlg do1340 with MainScreen.MessgExDlg do 1346 1341 begin 1347 1342 MessgText := Phrases.Lookup('CITYMANAGEOFF'); … … 1351 1346 ShowModal; 1352 1347 end; 1353 if M essgExDlg.ModalResult = mrOK then1348 if MainScreen.MessgExDlg.ModalResult = mrOK then 1354 1349 begin 1355 1350 MyCity[cix].Status := MyCity[cix].Status and … … 1450 1445 begin 1451 1446 Assert(not Supervising); 1452 M odalSelectDlg.ShowNewContent_CityProject(wmModal, cix);1453 if M odalSelectDlg.Result <> -1 then1454 begin 1455 if M odalSelectDlg.Result and cpType <> 0 then1447 MainScreen.ModalSelectDlg.ShowNewContent_CityProject(wmModal, cix); 1448 if MainScreen.ModalSelectDlg.Result <> -1 then 1449 begin 1450 if MainScreen.ModalSelectDlg.Result and cpType <> 0 then 1456 1451 begin 1457 1452 MyCity[cix].Status := MyCity[cix].Status and not 7 or 1458 (1 + M odalSelectDlg.Result and cpIndex);1459 AutoBuild(cix, MyData.ImpOrder[M odalSelectDlg.Result and cpIndex]);1453 (1 + MainScreen.ModalSelectDlg.Result and cpIndex); 1454 AutoBuild(cix, MyData.ImpOrder[MainScreen.ModalSelectDlg.Result and cpIndex]); 1460 1455 end 1461 1456 else 1462 1457 begin 1463 NewProject := M odalSelectDlg.Result;1458 NewProject := MainScreen.ModalSelectDlg.Result; 1464 1459 QueryOk := True; 1465 1460 if (NewProject and cpImp <> 0) and (NewProject and cpIndex >= 28) and 1466 1461 (MyRO.NatBuilt[NewProject and cpIndex] > 0) then 1467 with M essgExDlg do1462 with MainScreen.MessgExDlg do 1468 1463 begin 1469 1464 cix1 := MyRO.nCity - 1; … … 1542 1537 if (cix < 0) or (ClientMode >= scContact) then 1543 1538 Exit; 1544 with MyCity[cix], M essgExDlg do1539 with MyCity[cix], MainScreen.MessgExDlg do 1545 1540 begin 1546 1541 Cost := Report.ProjectCost; … … 1743 1738 end; 1744 1739 1745 { procedure TCityDlg.AdviceBtnClick(Sender: TObject);1746 begin1747 AdvisorDlg.GiveCityAdvice(cix);1748 end; }1749 1750 1740 procedure TCityDlg.PageUpBtnClick(Sender: TObject); 1751 1741 begin
Note:
See TracChangeset
for help on using the changeset viewer.