Changeset 233
- Timestamp:
- Sep 19, 2018, 3:20:20 PM (6 years ago)
- Location:
- trunk
- Files:
-
- 6 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/UClientGUI.pas
r231 r233 95 95 if Assigned(ControlPlayer) then begin 96 96 for Cell in ControlPlayer.PlayerMap.Cells do begin 97 if (Cell.MapCell.Terrain <> ttVoid) and View.IsCellVisible(Cell.MapCell) then begin97 if View.IsCellVisible(Cell.MapCell) and (Cell.MapCell.Terrain <> ttVoid) then begin 98 98 if Cell.MapCell.Player = ControlPlayer then 99 99 CellText := IntToStr(Cell.GetAvialPower) -
trunk/UCore.pas
r231 r233 308 308 Game.Running := False; 309 309 FormNew.Save(Server); 310 GameSettings.PostConfig; 310 311 Game.Assign(GameSettings); 311 312 StartNewGame; … … 533 534 534 535 if Game.FileName = '' then begin 536 GameSettings.PostConfig; 535 537 Game.Assign(GameSettings); 536 538 StartNewGame; -
trunk/UGame.pas
r231 r233 7 7 uses 8 8 Classes, SysUtils, ExtCtrls, Graphics, XMLConf, XMLRead, XMLWrite, Forms, 9 DOM, Math, LazFileUtils, UXMLUtils, Dialogs, Types,LCLType, LCLIntf, fgl,9 DOM, Math, LazFileUtils, UXMLUtils, Dialogs, LCLType, LCLIntf, fgl, 10 10 UGeometry, UPlayer, UMap, UMapType; 11 11 … … 77 77 BridgeEnabled: Boolean; 78 78 MaxPower: Integer; 79 procedure PostConfig; 79 80 procedure Assign(Source: TGame); 80 81 function AttackProbability(AttackCount, DefendCount: Integer): Double; … … 273 274 Cell: TCell; 274 275 begin 275 if (Map.Shape = msImage) and FileExists(MapImageFileName) and276 (LoadedImageFileName <> MapImageFileName) then begin277 LoadedImageFileName := MapImageFileName;278 Map.Image.Picture.LoadFromFile(MapImageFileName);279 end;280 281 276 // Randomize map terrain 282 277 for Cell in Map.Cells do … … 290 285 Power := Random(MaxNeutralUnits + 1); 291 286 Player := nil; 287 end; 288 end; 289 290 procedure TGame.PostConfig; 291 begin 292 if (Map.Shape = msImage) and FileExists(MapImageFileName) and 293 (LoadedImageFileName <> MapImageFileName) then begin 294 LoadedImageFileName := MapImageFileName; 295 Map.Image.Picture.LoadFromFile(MapImageFileName); 292 296 end; 293 297 end; -
trunk/UGameClient.pas
r231 r233 7 7 uses 8 8 Classes, SysUtils, UGame, Forms, fgl, UGameProtocol, UGameServer, UCommThread, 9 UThreading, UCommFrame, U Map, UPlayer;9 UThreading, UCommFrame, UPlayer; 10 10 11 11 type -
trunk/UMap.pas
r231 r233 6 6 7 7 uses 8 Classes, SysUtils, Graphics, ExtCtrls, UGeometry, XMLRead, XMLWrite,DOM, fgl,8 Classes, SysUtils, Graphics, ExtCtrls, UGeometry, DOM, fgl, 9 9 UXMLUtils; 10 10 -
trunk/UPlayer.pas
r231 r233 6 6 7 7 uses 8 Classes, SysUtils, Graphics, UMap, XmlRead, XmlWrite,DOM, fgl, XMLConf,8 Classes, SysUtils, Graphics, UMap, DOM, fgl, XMLConf, 9 9 UXMLUtils, Math, UGeometry; 10 10
Note:
See TracChangeset
for help on using the changeset viewer.