- Timestamp:
- Mar 6, 2011, 6:43:01 PM (14 years ago)
- Location:
- trunk
- Files:
-
- 2 added
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/UCore.pas
r3 r4 8 8 Dialogs, Classes, SysUtils, Contnrs, Graphics, SpecializedMatrix, SpecializedList; 9 9 10 const 11 MaxBulletCount = 10; 12 10 13 type 11 14 TEngine = class; 12 13 TSurfaceMatter = (smNothing, smDirt1, smDirt2, smRock, 14 smPlayer1H, smPlayer1L, smPlayer2H, smPlayer2L, smCannon, smBullet); 15 TPlayer = class; 16 17 TSurfaceMatter = (smNothing, smDirt1, smDirt2, smRock, smCannon, smBullet, 18 smPlayer1H, smPlayer1L, smPlayer2H, smPlayer2L, 19 smPlayer3H, smPlayer3L, smPlayer4H, smPlayer4L); 15 20 16 21 TPlayerKeys = record … … 22 27 end; 23 28 29 TBullet = class 30 Player: TPlayer; 31 Position: TPoint; 32 Direction: Integer; 33 end; 34 24 35 { TTank } 25 36 … … 35 46 TPlayer = class 36 47 private 48 NewDirection: Integer; 49 NewPosition: TPoint; 50 Dig: Boolean; 37 51 function ShowTankProc(Item1, Item2: Byte): Byte; 38 52 function HideTankProc(Item1, Item2: Byte): Byte; … … 46 60 Keys: TPlayerKeys; 47 61 Tanks: TListObject; 62 Bullets: TListObject; 48 63 procedure Control; 49 64 procedure Paint; 50 65 procedure PlaceHouse; 51 function CheckColision: Boolean;66 function CheckColision: TSurfaceMatter; 52 67 procedure ShowTank; 53 68 procedure HideTank; … … 69 84 constructor Create; 70 85 destructor Destroy; override; 86 procedure DrawToBitmap(Bitmap: TBitmap); 71 87 property Size: TMatrixByteIndex read GetSize write SetSize; 72 88 end; … … 78 94 FBitmap: TBitmap; 79 95 FRedrawPending: Boolean; 96 FBitmapLower: TBitmap; 80 97 function GetPlayerCount: Integer; 81 98 procedure SetBitmap(const AValue: TBitmap); … … 90 107 procedure ResizePlayerFrames; 91 108 procedure Tick; 109 procedure Draw; 92 110 property PlayerCount: Integer read GetPlayerCount write SetPlayerCount; 93 111 property Bitmap: TBitmap read FBitmap write SetBitmap; … … 97 115 const 98 116 SurfaceMatterColors: array[TSurfaceMatter] of TColor = (clBlack, $0756b0, 99 $2170c3, TColor($9a9a9a), TColor($00ff00), TColor($00a000), 100 TColor($ff2c2c), TColor($b60000), clYellow, clRed); 117 $2170c3, TColor($9a9a9a), clYellow, clRed, 118 TColor($00ff00), TColor($00a000), TColor($ff2c2c), TColor($b60000), 119 TColor($0000ff), TColor($0000a0), TColor($ff2cff), TColor($b600b6)); 120 DirectionToDelta: array[0..7] of TPoint = 121 ((X: 0; Y: -1), (X: 1; Y: -1), (X: 1; Y: 0), (X: 1; Y: 1), 122 (X: 0; Y: 1), (X: -1; Y: 1), (X: -1; Y: 0), (X: -1; Y: -1)); 101 123 102 124 var … … 136 158 var 137 159 X, Y: Integer; 160 Distance: Double; 161 Delta: Double; 138 162 begin 139 163 for Y := 0 to Surface.Count.Y - 1 do … … 143 167 Surface.ItemsXY[Y, X] := Byte(smDirt2); 144 168 end; 169 170 Distance := 0.1 * Surface.Count.X; 171 Delta := 0; 172 for Y := 0 to Surface.Count.Y - 1 do begin 173 for X := 0 to Round(Distance) - 1 do begin 174 Surface.ItemsXY[Y, X] := Byte(smRock); 175 end; 176 Delta := (Random * 2 - 1) * 3 - (Distance / (0.1 * Surface.Count.X) * 2 - 1); 177 Distance := Distance + Delta; 178 end; 179 180 Distance := 0.1 * Surface.Count.X; 181 Delta := 0; 182 for Y := 0 to Surface.Count.Y - 1 do begin 183 for X := 0 to Round(Distance) - 1 do begin 184 Surface.ItemsXY[Y, Surface.Count.X - 1 - X] := Byte(smRock); 185 end; 186 Delta := (Random * 2 - 1) * 3 - (Distance / (0.1 * Surface.Count.X) * 2 - 1); 187 Distance := Distance + Delta; 188 end; 189 190 Distance := 0.1 * Surface.Count.Y; 191 Delta := 0; 192 for X := 0 to Surface.Count.X - 1 do begin 193 for Y := 0 to Round(Distance) - 1 do begin 194 Surface.ItemsXY[Y, X] := Byte(smRock); 195 end; 196 Delta := (Random * 2 - 1) * 3 - (Distance / (0.1 * Surface.Count.Y) * 2 - 1); 197 Distance := Distance + Delta; 198 end; 199 200 Distance := 0.1 * Surface.Count.Y; 201 Delta := 0; 202 for X := 0 to Surface.Count.X - 1 do begin 203 for Y := 0 to Round(Distance) - 1 do begin 204 Surface.ItemsXY[Surface.Count.Y - 1 - Y, X] := Byte(smRock); 205 end; 206 Delta := (Random * 2 - 1) * 3 - (Distance / (0.1 * Surface.Count.Y) * 2 - 1); 207 Distance := Distance + Delta; 208 end; 145 209 end; 146 210 … … 150 214 begin 151 215 Surface := TMatrixByte.Create; 152 NewSize.X := 100;153 NewSize.Y := 100;216 NewSize.X := 800; 217 NewSize.Y := 300; 154 218 Size := NewSize; 155 219 end; … … 161 225 end; 162 226 227 procedure TWorld.DrawToBitmap(Bitmap: TBitmap); 228 var 229 X, Y: Integer; 230 begin 231 try 232 Bitmap.BeginUpdate(True); 233 for Y := 0 to Bitmap.Height - 1 do 234 for X := 0 to Bitmap.Width - 1 do 235 Bitmap.Canvas.Pixels[X, Y] := SurfaceMatterColors[TSurfaceMatter( 236 Surface.ItemsXY[Trunc(Y / Bitmap.Height * Surface.Count.Y), 237 Trunc(X / Bitmap.Width * Surface.Count.X)])]; 238 finally 239 Bitmap.EndUpdate; 240 end; 241 end; 242 163 243 { TPlayer } 164 244 165 245 procedure TPlayer.Control; 166 246 var 167 NewPosition: TPoint;168 NewDirection: Integer;169 247 Delta: TPoint; 248 Matter: TSurfaceMatter; 249 NewBullet: TBullet; 250 I: Integer; 170 251 begin 171 252 Delta.X := 0; 172 253 Delta.Y := 0; 173 if Engine.KeyState[Ord(Keys. Up)] then Delta.Y := Delta.Y + 1;174 if Engine.KeyState[Ord(Keys. Down)] then Delta.Y := Delta.Y - 1;254 if Engine.KeyState[Ord(Keys.Down)] then Delta.Y := Delta.Y + 1; 255 if Engine.KeyState[Ord(Keys.Up)] then Delta.Y := Delta.Y - 1; 175 256 if Engine.KeyState[Ord(Keys.Right)] then Delta.X := Delta.X + 1; 176 257 if Engine.KeyState[Ord(Keys.Left)] then Delta.X := Delta.X - 1; … … 186 267 else if (Delta.X = -1) and (Delta.Y = 0) then NewDirection := 6 187 268 else if (Delta.X = -1) and (Delta.Y = -1) then NewDirection := 7; 188 end; 189 190 NewPosition := Point(Position.X + Delta.X, Position.Y + Delta.Y);191 if CheckColision then begin269 270 if NewDirection = Direction then 271 NewPosition := Point(Position.X + Delta.X, Position.Y + Delta.Y) 272 else NewPosition := Position; 192 273 HideTank; 193 Position := NewPosition; 194 Direction := NewDirection; 274 Matter := CheckColision; 275 if (Matter = smDirt1) then Dig := not Dig; 276 if (Matter = smNothing) or ((Matter = smDirt1) and (not Dig)) then begin 277 Position := NewPosition; 278 Direction := NewDirection; 279 Engine.Redraw; 280 end; 195 281 ShowTank; 196 Engine.Redraw; 282 end; 283 284 285 if Engine.KeyState[Ord(Keys.Shoot)] then 286 if Bullets.Count < MaxBulletCount then begin 287 NewBullet := TBullet.Create; 288 NewBullet.Player := Self; 289 NewBullet.Position := Position; 290 NewBullet.Direction := Direction; 291 Bullets.Add(NewBullet); 292 end; 293 294 for I := Bullets.Count - 1 downto 0 do 295 with TBullet(Bullets[I]) do begin 296 Engine.World.Surface.ItemsXY[Position.Y, Position.X] := Byte(smNothing); 297 298 Position.X := Position.X + DirectionToDelta[Direction].X; 299 Position.Y := Position.Y + DirectionToDelta[Direction].Y; 300 301 with Engine.World.Surface do 302 if (Position.X >= Count.X) or (Position.X < 0) or 303 (Position.Y >= Count.Y) or (Position.Y < 0) then 304 Bullets.Delete(I) else 305 Engine.World.Surface.ItemsXY[Position.Y, Position.X] := Byte(smBullet); 197 306 end; 198 307 end; … … 203 312 XX, YY: Integer; 204 313 begin 205 with Engine. Bitmap.Canvas do begin314 with Engine.FBitmapLower.Canvas do begin 206 315 Rectangle(ScreenFrame); 207 //FillRect(ScreenFrame); 316 Brush.Color := SurfaceMatterColors[smRock]; 317 FillRect(ScreenFrame); 208 318 209 319 … … 248 358 end; 249 359 250 function TPlayer.CheckColision: Boolean; 251 begin 252 360 function TPlayer.CheckColision: TSurfaceMatter; 361 var 362 X, Y: Integer; 363 begin 364 Result := smNothing; 365 with Engine.World, TTank(Tanks[NewDirection]) do 366 for Y := 0 to Image.Count.Y - 1 do 367 for X := 0 to Image.Count.X - 1 do 368 if (Image.ItemsXY[Y, X] > 0) and 369 (Surface.ItemsXY[Y + NewPosition.Y, X + NewPosition.X] <> Byte(smNothing)) then 370 begin 371 Result := smDirt1; 372 if (Surface.ItemsXY[Y + NewPosition.Y, X + NewPosition.X] <> Byte(smDirt1)) and 373 (Surface.ItemsXY[Y + NewPosition.Y, X + NewPosition.X] <> Byte(smDirt2)) then 374 begin 375 Result := TSurfaceMatter(Surface.ItemsXY[Y + NewPosition.Y, X + NewPosition.X]); 376 Exit; 377 end; 378 end; 253 379 end; 254 380 … … 261 387 begin 262 388 with Engine.World do begin 263 Surface.Merge( TMatrixByte.Point(Position.X, Position.Y), TTank(Tanks[Direction]).Image, ShowTankProc);389 Surface.Merge(Surface.CreateIndex(Position.X, Position.Y), TTank(Tanks[Direction]).Image, ShowTankProc); 264 390 end; 265 391 end; … … 273 399 begin 274 400 with Engine.World do begin 275 Surface.Merge( TMatrixByte.Point(Position.X, Position.Y), TTank(Tanks[Direction]).Image, HideTankProc);401 Surface.Merge(Surface.CreateIndex(Position.X, Position.Y), TTank(Tanks[Direction]).Image, HideTankProc); 276 402 end; 277 403 end; … … 287 413 NewTank := TTank.Create; 288 414 with NewTank do begin 289 Image.Count := TMatrixByte.Point(7, 7);415 Image.Count := Image.CreateIndex(7, 7); 290 416 for I := 0 to 3 do 291 417 Image[I, 3] := Byte(smCannon); … … 305 431 NewTank := TTank.Create; 306 432 with NewTank do begin 307 Image.Count := TMatrixByte.Point(7, 7);433 Image.Count := Image.CreateIndex(7, 7); 308 434 for I := 0 to 2 do 309 435 Image[3 - I, 3 + I] := Byte(smCannon); … … 368 494 begin 369 495 Tanks := TListObject.Create; 496 Bullets := TListObject.Create; 370 497 end; 371 498 372 499 destructor TPlayer.Destroy; 373 500 begin 501 Bullets.Free; 374 502 Tanks.Free; 375 503 inherited Destroy; … … 422 550 I: Integer; 423 551 begin 424 // TODO: Determine frames from player count 425 if Assigned(Bitmap) then begin 426 HorizFrameCount := 2; 427 VertFrameCount := 1; 552 if Assigned(FBitmapLower) then begin 553 if Players.Count > 1 then begin 554 if Players.Count > 2 then VertFrameCount := 2 555 else VertFrameCount := 1; 556 HorizFrameCount := Round(Players.Count / VertFrameCount); 557 end else begin 558 VertFrameCount := 1; 559 HorizFrameCount := 1; 560 end; 561 FBitmapLower.SetSize(80 * HorizFrameCount, 60 * VertFrameCount); 428 562 for I := 0 to Players.Count - 1 do begin 429 563 TPlayer(Players[I]).ScreenFrame := Rect( 430 (I mod HorizFrameCount) * (Bitmap.Width div HorizFrameCount), 431 (I div HorizFrameCount) * (Bitmap.Height div VertFrameCount), 432 ((I mod HorizFrameCount) + 1) * (Bitmap.Width div HorizFrameCount), 433 ((I div HorizFrameCount) + 1) * (Bitmap.Height div VertFrameCount)); 434 end; 435 end; 564 (I mod HorizFrameCount) * (FBitmapLower.Width div HorizFrameCount), 565 (I div HorizFrameCount) * (FBitmapLower.Height div VertFrameCount), 566 ((I mod HorizFrameCount) + 1) * (FBitmapLower.Width div HorizFrameCount), 567 ((I div HorizFrameCount) + 1) * (FBitmapLower.Height div VertFrameCount)); 568 end; 569 end; 570 Redraw; 436 571 end; 437 572 438 573 constructor TEngine.Create; 439 574 begin 575 FBitmapLower := TBitmap.Create; 440 576 Players := TObjectList.Create; 441 577 World := TWorld.Create; 442 578 World.Engine := Self; 579 Redraw; 443 580 end; 444 581 445 582 destructor TEngine.Destroy; 446 583 begin 584 FBitmapLower.Free; 447 585 Players.Free; 448 586 World.Free; … … 457 595 TPlayer(Players[I]).Control; 458 596 end; 459 597 end; 598 599 procedure TEngine.Draw; 600 var 601 I: Integer; 602 begin 460 603 if FRedrawPending then begin 461 if Assigned(Bitmap) then begin462 Bitmap.Canvas.FillRect(0, 0, Bitmap.Width, Bitmap.Height);463 for I := 0 to Players.Count - 1 do begin464 TPlayer(Players[I]).Control;465 TPlayer(Players[I]).Paint;466 end;604 FBitmapLower.Canvas.FillRect(0, 0, FBitmapLower.Width, FBitmapLower.Height); 605 for I := 0 to Players.Count - 1 do begin 606 TPlayer(Players[I]).Paint; 607 end; 608 if Assigned(FBitmap) then begin 609 FBitmap.Canvas.StretchDraw(Rect(0, 0, FBitmap.Width, FBitmap.Height), FBitmapLower); 467 610 end; 468 611 FRedrawPending := False; … … 481 624 begin 482 625 // Reset position 483 Position := Point( 25 + Random(World.Surface.Count.X - 50),484 25 + Random(World.Surface.Count.Y - 50));626 Position := Point(Round(World.Surface.Count.X * 0.2) + Random(Round(World.Surface.Count.X * 0.6)), 627 Round(World.Surface.Count.Y * 0.2) + Random(Round(World.Surface.Count.Y * 0.6))); 485 628 486 629 PlaceHouse; 487 630 end; 631 Redraw; 488 632 end; 489 633 -
trunk/UMainForm.lfm
r2 r4 4 4 Top = 95 5 5 Width = 514 6 Caption = ' MainForm'6 Caption = 'Tunneler' 7 7 ClientHeight = 389 8 8 ClientWidth = 514 … … 11 11 OnKeyDown = FormKeyDown 12 12 OnKeyUp = FormKeyUp 13 OnShow = FormShow 13 14 LCLVersion = '0.9.31' 14 15 object Image1: TImage … … 19 20 Align = alClient 20 21 OnResize = Image1Resize 21 Stretch = True22 22 end 23 23 object StatusBar1: TStatusBar … … 35 35 SimplePanel = False 36 36 end 37 object Timer 1: TTimer37 object TimerDraw: TTimer 38 38 Interval = 50 39 OnTimer = Timer 1Timer39 OnTimer = TimerDrawTimer 40 40 left = 99 41 41 top = 50 … … 50 50 OnClick = MenuItem3Click 51 51 end 52 object MenuItemShowMap: TMenuItem 53 Caption = 'Show map' 54 OnClick = MenuItemShowMapClick 55 end 52 56 object MenuItem2: TMenuItem 53 57 Caption = 'Exit' … … 56 60 end 57 61 end 62 object TimerEngineTick: TTimer 63 Interval = 10 64 OnTimer = TimerEngineTickTimer 65 left = 96 66 top = 104 67 end 58 68 end -
trunk/UMainForm.pas
r3 r4 19 19 MenuItem2: TMenuItem; 20 20 MenuItem3: TMenuItem; 21 MenuItemShowMap: TMenuItem; 21 22 StatusBar1: TStatusBar; 22 Timer1: TTimer; 23 TimerDraw: TTimer; 24 TimerEngineTick: TTimer; 23 25 procedure FormCreate(Sender: TObject); 24 26 procedure FormKeyDown(Sender: TObject; var Key: Word; Shift: TShiftState); 25 27 procedure FormKeyUp(Sender: TObject; var Key: Word; Shift: TShiftState); 28 procedure FormShow(Sender: TObject); 26 29 procedure Image1Resize(Sender: TObject); 27 30 procedure MenuItem2Click(Sender: TObject); 28 31 procedure MenuItem3Click(Sender: TObject); 29 procedure Timer1Timer(Sender: TObject); 32 procedure MenuItemShowMapClick(Sender: TObject); 33 procedure TimerDrawTimer(Sender: TObject); 34 procedure TimerEngineTickTimer(Sender: TObject); 30 35 private 31 { private declarations }32 36 public 33 37 { public declarations } … … 41 45 {$R *.lfm} 42 46 47 uses 48 UMapForm; 49 43 50 { TMainForm } 44 51 45 procedure TMainForm.Timer 1Timer(Sender: TObject);52 procedure TMainForm.TimerDrawTimer(Sender: TObject); 46 53 begin 47 54 try 48 Timer 1.Enabled := False;49 Engine. Tick;55 TimerDraw.Enabled := False; 56 Engine.Draw; 50 57 StatusBar1.Panels[1].Text := IntToStr(TPlayer(Engine.Players[0]).Position.X) + ', ' + 51 58 IntToStr(TPlayer(Engine.Players[0]).Position.Y) + ' ' + 52 59 IntToStr(TPlayer(Engine.Players[0]).Direction); 53 60 finally 54 Timer 1.Enabled := True;61 TimerDraw.Enabled := True; 55 62 end; 63 end; 64 65 procedure TMainForm.TimerEngineTickTimer(Sender: TObject); 66 begin 67 Engine.Tick; 56 68 end; 57 69 … … 59 71 begin 60 72 Engine.Bitmap := Image1.Picture.Bitmap; 61 Image1Resize(Self);62 73 with Engine do begin 63 PlayerCount := 2;74 PlayerCount := 4; 64 75 with TPlayer(Players[0]) do begin 65 76 Keys.Left := 65; 66 Keys.Down := 8 7;77 Keys.Down := 83; 67 78 Keys.Right := 68; 68 Keys.Up := 8 3;79 Keys.Up := 87; 69 80 Keys.Shoot := 69; 70 81 end; 71 82 with TPlayer(Players[1]) do begin 72 83 Keys.Left := 37; 73 Keys.Down := 38;84 Keys.Down := 40; 74 85 Keys.Right := 39; 75 Keys.Up := 40;86 Keys.Up := 38; 76 87 Keys.Shoot := 17; 88 end; 89 with TPlayer(Players[2]) do begin 90 Keys.Left := 76; 91 Keys.Down := 186; 92 Keys.Right := 222; 93 Keys.Up := 80; 94 Keys.Shoot := 186; 95 end; 96 with TPlayer(Players[3]) do begin 97 Keys.Left := 100; 98 Keys.Down := 98; 99 Keys.Right := 102; 100 Keys.Up := 104; 101 Keys.Shoot := 98; 77 102 end; 78 103 end; 79 104 Engine.NewGame; 105 Image1Resize(Self); 80 106 end; 81 107 … … 93 119 end; 94 120 121 procedure TMainForm.FormShow(Sender: TObject); 122 begin 123 end; 124 95 125 procedure TMainForm.Image1Resize(Sender: TObject); 96 126 begin 97 // Image1.Picture.Bitmap.SetSize(Image1.Width, Image1.Height); 98 Image1.Picture.Bitmap.SetSize(80, 60); 127 Image1.Picture.Bitmap.SetSize(Image1.Width, Image1.Height); 99 128 Engine.ResizePlayerFrames; 100 129 end; … … 110 139 end; 111 140 141 procedure TMainForm.MenuItemShowMapClick(Sender: TObject); 142 begin 143 MapForm.Show; 144 end; 145 112 146 end. 113 147 -
trunk/tunneler.lpi
r3 r4 30 30 </local> 31 31 </RunParams> 32 <RequiredPackages Count=" 2">32 <RequiredPackages Count="3"> 33 33 <Item1> 34 <PackageName Value="TemplateGenerics"/> 34 <PackageName Value="LCLBase"/> 35 <MinVersion Major="1" Release="1" Valid="True"/> 35 36 </Item1> 36 37 <Item2> 38 <PackageName Value="TemplateGenerics"/> 39 </Item2> 40 <Item3> 37 41 <PackageName Value="LCL"/> 38 </Item 2>42 </Item3> 39 43 </RequiredPackages> 40 <Units Count=" 18">44 <Units Count="31"> 41 45 <Unit0> 42 46 <Filename Value="tunneler.lpr"/> 43 47 <IsPartOfProject Value="True"/> 44 48 <UnitName Value="tunneler"/> 45 <EditorIndex Value="0"/>46 49 <WindowIndex Value="0"/> 47 50 <TopLine Value="1"/> 48 <CursorPos X="28" Y="11"/> 49 <UsageCount Value="36"/> 50 <Loaded Value="True"/> 51 <CursorPos X="14" Y="8"/> 52 <UsageCount Value="49"/> 51 53 </Unit0> 52 54 <Unit1> … … 56 58 <ResourceBaseClass Value="Form"/> 57 59 <UnitName Value="UMainForm"/> 58 <EditorIndex Value=" 2"/>59 <WindowIndex Value="0"/> 60 <TopLine Value="1 1"/>61 <CursorPos X=" 1" Y="72"/>62 <UsageCount Value=" 36"/>60 <EditorIndex Value="1"/> 61 <WindowIndex Value="0"/> 62 <TopLine Value="12"/> 63 <CursorPos X="20" Y="27"/> 64 <UsageCount Value="49"/> 63 65 <Loaded Value="True"/> 64 66 <LoadedDesigner Value="True"/> … … 69 71 <UnitName Value="UCore"/> 70 72 <IsVisibleTab Value="True"/> 71 <EditorIndex Value=" 1"/>72 <WindowIndex Value="0"/> 73 <TopLine Value=" 451"/>74 <CursorPos X=" 6" Y="468"/>75 <UsageCount Value=" 36"/>73 <EditorIndex Value="0"/> 74 <WindowIndex Value="0"/> 75 <TopLine Value="161"/> 76 <CursorPos X="38" Y="177"/> 77 <UsageCount Value="49"/> 76 78 <Loaded Value="True"/> 77 79 </Unit2> … … 82 84 <TopLine Value="35"/> 83 85 <CursorPos X="20" Y="51"/> 84 <UsageCount Value="1 3"/>86 <UsageCount Value="11"/> 85 87 </Unit3> 86 88 <Unit4> … … 90 92 <TopLine Value="52"/> 91 93 <CursorPos X="18" Y="57"/> 92 <UsageCount Value="1 2"/>94 <UsageCount Value="10"/> 93 95 </Unit4> 94 96 <Unit5> … … 98 100 <TopLine Value="1"/> 99 101 <CursorPos X="61" Y="11"/> 100 <UsageCount Value="2 7"/>102 <UsageCount Value="25"/> 101 103 </Unit5> 102 104 <Unit6> … … 105 107 <TopLine Value="252"/> 106 108 <CursorPos X="20" Y="271"/> 107 <UsageCount Value=" 10"/>109 <UsageCount Value="9"/> 108 110 </Unit6> 109 111 <Unit7> … … 111 113 <UnitName Value="Graphics"/> 112 114 <WindowIndex Value="0"/> 113 <TopLine Value="1 071"/>114 <CursorPos X="15" Y="1 087"/>115 <UsageCount Value="1 0"/>115 <TopLine Value="1281"/> 116 <CursorPos X="15" Y="1298"/> 117 <UsageCount Value="12"/> 116 118 </Unit7> 117 119 <Unit8> 118 120 <Filename Value="../../../lazarus/lcl/include/rasterimage.inc"/> 119 121 <WindowIndex Value="0"/> 120 <TopLine Value=" 289"/>121 <CursorPos X=" 1" Y="308"/>122 <TopLine Value="143"/> 123 <CursorPos X="3" Y="145"/> 122 124 <UsageCount Value="10"/> 123 125 </Unit8> … … 125 127 <Filename Value="../../../lazarus/lcl/include/canvas.inc"/> 126 128 <WindowIndex Value="0"/> 127 <TopLine Value=" 102"/>128 <CursorPos X=" 7" Y="105"/>129 <UsageCount Value=" 10"/>129 <TopLine Value="34"/> 130 <CursorPos X="1" Y="54"/> 131 <UsageCount Value="9"/> 130 132 </Unit9> 131 133 <Unit10> … … 135 137 <TopLine Value="1433"/> 136 138 <CursorPos X="3" Y="1449"/> 137 <UsageCount Value=" 10"/>139 <UsageCount Value="8"/> 138 140 </Unit10> 139 141 <Unit11> 140 142 <Filename Value="../../PascalClassLibrary/Generics/TemplateGenerics/Generic/GenericMatrix.inc"/> 141 <EditorIndex Value=" 4"/>142 <WindowIndex Value="0"/> 143 <TopLine Value="1 "/>144 <CursorPos X=" 16" Y="3"/>145 <UsageCount Value=" 13"/>143 <EditorIndex Value="3"/> 144 <WindowIndex Value="0"/> 145 <TopLine Value="149"/> 146 <CursorPos X="59" Y="172"/> 147 <UsageCount Value="20"/> 146 148 <Loaded Value="True"/> 147 149 </Unit11> … … 149 151 <Filename Value="../../PascalClassLibrary/Generics/TemplateGenerics/Specialized/SpecializedMatrix.pas"/> 150 152 <UnitName Value="SpecializedMatrix"/> 151 <EditorIndex Value=" 5"/>153 <EditorIndex Value="4"/> 152 154 <WindowIndex Value="0"/> 153 155 <TopLine Value="69"/> 154 156 <CursorPos X="40" Y="98"/> 155 <UsageCount Value="1 1"/>157 <UsageCount Value="17"/> 156 158 <Loaded Value="True"/> 157 159 </Unit12> … … 161 163 <TopLine Value="16"/> 162 164 <CursorPos X="19" Y="32"/> 163 <UsageCount Value="1 3"/>165 <UsageCount Value="11"/> 164 166 </Unit13> 165 167 <Unit14> 166 168 <Filename Value="../../FreePascalManager/trunk/Instance/1/FPC/rtl/objpas/types.pp"/> 167 169 <UnitName Value="types"/> 168 <EditorIndex Value="3"/>169 170 <WindowIndex Value="0"/> 170 171 <TopLine Value="54"/> 171 172 <CursorPos X="3" Y="70"/> 172 <UsageCount Value="13"/> 173 <Loaded Value="True"/> 173 <UsageCount Value="14"/> 174 174 </Unit14> 175 175 <Unit15> 176 176 <Filename Value="../../PascalClassLibrary/Generics/TemplateGenerics/Generic/GenericList.inc"/> 177 <EditorIndex Value=" 6"/>177 <EditorIndex Value="5"/> 178 178 <WindowIndex Value="0"/> 179 179 <TopLine Value="107"/> 180 180 <CursorPos X="1" Y="126"/> 181 <UsageCount Value="1 1"/>181 <UsageCount Value="18"/> 182 182 <Loaded Value="True"/> 183 183 </Unit15> … … 187 187 <TopLine Value="783"/> 188 188 <CursorPos X="3" Y="785"/> 189 <UsageCount Value=" 10"/>189 <UsageCount Value="9"/> 190 190 </Unit16> 191 191 <Unit17> … … 194 194 <TopLine Value="830"/> 195 195 <CursorPos X="11" Y="847"/> 196 <UsageCount Value="9"/> 197 </Unit17> 198 <Unit18> 199 <Filename Value="../../../lazarus/lcl/extctrls.pp"/> 200 <UnitName Value="ExtCtrls"/> 201 <WindowIndex Value="0"/> 202 <TopLine Value="665"/> 203 <CursorPos X="27" Y="682"/> 204 <UsageCount Value="11"/> 205 </Unit18> 206 <Unit19> 207 <Filename Value="../../../lazarus/lcl/include/customimage.inc"/> 208 <WindowIndex Value="0"/> 209 <TopLine Value="112"/> 210 <CursorPos X="10" Y="114"/> 211 <UsageCount Value="11"/> 212 </Unit19> 213 <Unit20> 214 <Filename Value="../../../lazarus/lcl/controls.pp"/> 215 <UnitName Value="Controls"/> 216 <WindowIndex Value="0"/> 217 <TopLine Value="1035"/> 218 <CursorPos X="15" Y="1052"/> 219 <UsageCount Value="9"/> 220 </Unit20> 221 <Unit21> 222 <Filename Value="../../../lazarus/lcl/include/control.inc"/> 223 <WindowIndex Value="0"/> 224 <TopLine Value="3003"/> 225 <CursorPos X="3" Y="3010"/> 226 <UsageCount Value="9"/> 227 </Unit21> 228 <Unit22> 229 <Filename Value="../../../lazarus/lcl/include/picture.inc"/> 230 <WindowIndex Value="0"/> 231 <TopLine Value="392"/> 232 <CursorPos X="1" Y="411"/> 233 <UsageCount Value="9"/> 234 </Unit22> 235 <Unit23> 236 <Filename Value="../../../lazarus/lcl/include/lclintfh.inc"/> 237 <WindowIndex Value="0"/> 238 <TopLine Value="103"/> 239 <CursorPos X="10" Y="120"/> 240 <UsageCount Value="9"/> 241 </Unit23> 242 <Unit24> 243 <Filename Value="../../../lazarus/lcl/include/lclintf.inc"/> 244 <WindowIndex Value="0"/> 245 <TopLine Value="437"/> 246 <CursorPos X="1" Y="443"/> 247 <UsageCount Value="9"/> 248 </Unit24> 249 <Unit25> 250 <Filename Value="../../../lazarus/lcl/interfaces/gtk2/gtk2winapi.inc"/> 251 <WindowIndex Value="0"/> 252 <TopLine Value="9107"/> 253 <CursorPos X="1" Y="9124"/> 254 <UsageCount Value="9"/> 255 </Unit25> 256 <Unit26> 257 <Filename Value="../../../lazarus/lcl/interfaces/gtk2/gtk2widgetset.inc"/> 258 <WindowIndex Value="0"/> 259 <TopLine Value="4226"/> 260 <CursorPos X="1" Y="4254"/> 261 <UsageCount Value="9"/> 262 </Unit26> 263 <Unit27> 264 <Filename Value="UMapForm.pas"/> 265 <IsPartOfProject Value="True"/> 266 <ComponentName Value="MapForm"/> 267 <ResourceBaseClass Value="Form"/> 268 <UnitName Value="UMapForm"/> 269 <EditorIndex Value="2"/> 270 <WindowIndex Value="0"/> 271 <TopLine Value="15"/> 272 <CursorPos X="24" Y="39"/> 273 <UsageCount Value="28"/> 274 <Loaded Value="True"/> 275 </Unit27> 276 <Unit28> 277 <Filename Value="../../../lazarus/lcl/include/customform.inc"/> 278 <WindowIndex Value="0"/> 279 <TopLine Value="858"/> 280 <CursorPos X="1" Y="875"/> 196 281 <UsageCount Value="10"/> 197 </Unit17> 282 </Unit28> 283 <Unit29> 284 <Filename Value="../../../lazarus/lcl/include/application.inc"/> 285 <WindowIndex Value="0"/> 286 <TopLine Value="2102"/> 287 <CursorPos X="1" Y="2119"/> 288 <UsageCount Value="10"/> 289 </Unit29> 290 <Unit30> 291 <Filename Value="/usr/share/fpcsrc/2.4.0/rtl/inc/mathh.inc"/> 292 <WindowIndex Value="0"/> 293 <TopLine Value="63"/> 294 <CursorPos X="65" Y="81"/> 295 <UsageCount Value="9"/> 296 </Unit30> 198 297 </Units> 199 <JumpHistory Count="30" HistoryIndex="2 9">298 <JumpHistory Count="30" HistoryIndex="28"> 200 299 <Position1> 201 <Filename Value=" ../../PascalClassLibrary/Generics/TemplateGenerics/Generic/GenericMatrix.inc"/>202 <Caret Line=" 415" Column="1" TopLine="391"/>300 <Filename Value="UCore.pas"/> 301 <Caret Line="245" Column="56" TopLine="214"/> 203 302 </Position1> 204 303 <Position2> 205 <Filename Value=" ../../PascalClassLibrary/Generics/TemplateGenerics/Generic/GenericMatrix.inc"/>206 <Caret Line=" 410" Column="1" TopLine="391"/>304 <Filename Value="UCore.pas"/> 305 <Caret Line="202" Column="14" TopLine="192"/> 207 306 </Position2> 208 307 <Position3> 209 <Filename Value=" ../../PascalClassLibrary/Generics/TemplateGenerics/Generic/GenericMatrix.inc"/>210 <Caret Line=" 411" Column="1" TopLine="391"/>308 <Filename Value="UMainForm.pas"/> 309 <Caret Line="65" Column="3" TopLine="47"/> 211 310 </Position3> 212 311 <Position4> 213 <Filename Value=" ../../PascalClassLibrary/Generics/TemplateGenerics/Generic/GenericMatrix.inc"/>214 <Caret Line=" 412" Column="1" TopLine="391"/>312 <Filename Value="UCore.pas"/> 313 <Caret Line="234" Column="7" TopLine="207"/> 215 314 </Position4> 216 315 <Position5> 217 <Filename Value=" ../../PascalClassLibrary/Generics/TemplateGenerics/Generic/GenericMatrix.inc"/>218 <Caret Line=" 413" Column="1" TopLine="391"/>316 <Filename Value="UMainForm.pas"/> 317 <Caret Line="65" Column="3" TopLine="47"/> 219 318 </Position5> 220 319 <Position6> 221 <Filename Value=" ../../PascalClassLibrary/Generics/TemplateGenerics/Generic/GenericMatrix.inc"/>222 <Caret Line=" 412" Column="1" TopLine="391"/>320 <Filename Value="UMainForm.pas"/> 321 <Caret Line="72" Column="3" TopLine="49"/> 223 322 </Position6> 224 323 <Position7> 225 <Filename Value=" ../../PascalClassLibrary/Generics/TemplateGenerics/Generic/GenericMatrix.inc"/>226 <Caret Line=" 413" Column="1" TopLine="391"/>324 <Filename Value="UMainForm.pas"/> 325 <Caret Line="67" Column="15" TopLine="65"/> 227 326 </Position7> 228 327 <Position8> 229 <Filename Value=" ../../PascalClassLibrary/Generics/TemplateGenerics/Generic/GenericMatrix.inc"/>230 <Caret Line=" 412" Column="1" TopLine="391"/>328 <Filename Value="UMainForm.pas"/> 329 <Caret Line="56" Column="9" TopLine="52"/> 231 330 </Position8> 232 331 <Position9> 233 <Filename Value=" ../../PascalClassLibrary/Generics/TemplateGenerics/Generic/GenericMatrix.inc"/>234 <Caret Line=" 413" Column="1" TopLine="391"/>332 <Filename Value="UCore.pas"/> 333 <Caret Line="124" Column="15" TopLine="107"/> 235 334 </Position9> 236 335 <Position10> 237 <Filename Value=" ../../PascalClassLibrary/Generics/TemplateGenerics/Generic/GenericMatrix.inc"/>238 <Caret Line=" 412" Column="1" TopLine="391"/>336 <Filename Value="UCore.pas"/> 337 <Caret Line="109" Column="20" TopLine="85"/> 239 338 </Position10> 240 339 <Position11> 241 <Filename Value=" ../../PascalClassLibrary/Generics/TemplateGenerics/Generic/GenericMatrix.inc"/>242 <Caret Line=" 413" Column="1" TopLine="391"/>340 <Filename Value="UCore.pas"/> 341 <Caret Line="553" Column="29" TopLine="541"/> 243 342 </Position11> 244 343 <Position12> 245 <Filename Value=" ../../PascalClassLibrary/Generics/TemplateGenerics/Generic/GenericMatrix.inc"/>246 <Caret Line=" 415" Column="1" TopLine="391"/>344 <Filename Value="UCore.pas"/> 345 <Caret Line="562" Column="1" TopLine="550"/> 247 346 </Position12> 248 347 <Position13> 249 <Filename Value=" ../../PascalClassLibrary/Generics/TemplateGenerics/Generic/GenericMatrix.inc"/>250 <Caret Line=" 410" Column="1" TopLine="391"/>348 <Filename Value="UCore.pas"/> 349 <Caret Line="557" Column="20" TopLine="537"/> 251 350 </Position13> 252 351 <Position14> 253 <Filename Value=" ../../PascalClassLibrary/Generics/TemplateGenerics/Generic/GenericMatrix.inc"/>254 <Caret Line=" 411" Column="1" TopLine="391"/>352 <Filename Value="UCore.pas"/> 353 <Caret Line="554" Column="1" TopLine="537"/> 255 354 </Position14> 256 355 <Position15> 257 <Filename Value=" ../../PascalClassLibrary/Generics/TemplateGenerics/Generic/GenericMatrix.inc"/>258 <Caret Line=" 412" Column="1" TopLine="391"/>356 <Filename Value="UCore.pas"/> 357 <Caret Line="555" Column="1" TopLine="537"/> 259 358 </Position15> 260 359 <Position16> 261 <Filename Value=" ../../PascalClassLibrary/Generics/TemplateGenerics/Generic/GenericMatrix.inc"/>262 <Caret Line=" 413" Column="1" TopLine="391"/>360 <Filename Value="UCore.pas"/> 361 <Caret Line="556" Column="1" TopLine="537"/> 263 362 </Position16> 264 363 <Position17> 265 <Filename Value=" ../../PascalClassLibrary/Generics/TemplateGenerics/Generic/GenericMatrix.inc"/>266 <Caret Line=" 411" Column="22" TopLine="394"/>364 <Filename Value="UCore.pas"/> 365 <Caret Line="557" Column="1" TopLine="537"/> 267 366 </Position17> 268 367 <Position18> 269 <Filename Value="U MainForm.pas"/>270 <Caret Line=" 70" Column="7" TopLine="41"/>368 <Filename Value="UCore.pas"/> 369 <Caret Line="494" Column="1" TopLine="488"/> 271 370 </Position18> 272 371 <Position19> 273 372 <Filename Value="UCore.pas"/> 274 <Caret Line=" 50" Column="17" TopLine="34"/>373 <Caret Line="235" Column="1" TopLine="215"/> 275 374 </Position19> 276 375 <Position20> 277 376 <Filename Value="UCore.pas"/> 278 <Caret Line=" 328" Column="6" TopLine="314"/>377 <Caret Line="495" Column="1" TopLine="478"/> 279 378 </Position20> 280 379 <Position21> 281 <Filename Value=" ../../PascalClassLibrary/Generics/TemplateGenerics/Generic/GenericMatrix.inc"/>282 <Caret Line=" 116" Column="1" TopLine="91"/>380 <Filename Value="UCore.pas"/> 381 <Caret Line="583" Column="1" TopLine="562"/> 283 382 </Position21> 284 383 <Position22> 285 384 <Filename Value="UCore.pas"/> 286 <Caret Line=" 186" Column="9" TopLine="159"/>385 <Caret Line="558" Column="29" TopLine="541"/> 287 386 </Position22> 288 387 <Position23> 289 388 <Filename Value="UCore.pas"/> 290 <Caret Line=" 48" Column="15" TopLine="31"/>389 <Caret Line="547" Column="27" TopLine="541"/> 291 390 </Position23> 292 391 <Position24> 293 392 <Filename Value="UCore.pas"/> 294 <Caret Line=" 39" Column="5" TopLine="20"/>393 <Caret Line="171" Column="62" TopLine="157"/> 295 394 </Position24> 296 395 <Position25> 297 <Filename Value="U Core.pas"/>298 <Caret Line=" 258" Column="1" TopLine="1"/>396 <Filename Value="UMapForm.pas"/> 397 <Caret Line="39" Column="24" TopLine="15"/> 299 398 </Position25> 300 399 <Position26> 301 400 <Filename Value="UCore.pas"/> 302 <Caret Line="2 41" Column="41" TopLine="228"/>401 <Caret Line="210" Column="5" TopLine="197"/> 303 402 </Position26> 304 403 <Position27> 305 404 <Filename Value="UCore.pas"/> 306 <Caret Line=" 89" Column="17" TopLine="66"/>405 <Caret Line="202" Column="16" TopLine="193"/> 307 406 </Position27> 308 407 <Position28> 309 408 <Filename Value="UCore.pas"/> 310 <Caret Line=" 83" Column="15" TopLine="72"/>409 <Caret Line="177" Column="29" TopLine="157"/> 311 410 </Position28> 312 411 <Position29> 313 412 <Filename Value="UCore.pas"/> 314 <Caret Line="1 96" Column="12" TopLine="165"/>413 <Caret Line="188" Column="70" TopLine="161"/> 315 414 </Position29> 316 415 <Position30> 317 <Filename Value=" UCore.pas"/>318 <Caret Line=" 460" Column="7" TopLine="443"/>416 <Filename Value="../../PascalClassLibrary/Generics/TemplateGenerics/Generic/GenericMatrix.inc"/> 417 <Caret Line="172" Column="59" TopLine="149"/> 319 418 </Position30> 320 419 </JumpHistory> -
trunk/tunneler.lpr
r2 r4 8 8 {$ENDIF}{$ENDIF} 9 9 Interfaces, // this includes the LCL widgetset 10 Forms, UMainForm, UCore, TemplateGenerics 10 Forms, UMainForm, UCore, TemplateGenerics, UMapForm 11 11 { you can add units after this }; 12 12 … … 16 16 Application.Initialize; 17 17 Application.CreateForm(TMainForm, MainForm); 18 Application.CreateForm(TMapForm, MapForm); 18 19 Application.Run; 19 20 end.
Note:
See TracChangeset
for help on using the changeset viewer.