Changeset 31
- Timestamp:
- Mar 4, 2014, 10:18:09 PM (11 years ago)
- Location:
- trunk
- Files:
-
- 6 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Languages/xtactics.cs.po
r30 r31 112 112 msgstr "x" 113 113 114 #: tformnew.label3.caption 115 msgid "%" 116 msgstr "" 117 114 118 #: tformnew.listview1.columns[0].caption 115 119 msgid "Name" … … 170 174 msgid "You need at least two players" 171 175 msgstr "Potřebujete alespoň dva hráče" 176 -
trunk/Languages/xtactics.po
r29 r31 103 103 msgstr "" 104 104 105 #: tformnew.label3.caption 106 msgid "%" 107 msgstr "" 108 105 109 #: tformnew.listview1.columns[0].caption 106 110 msgid "Name" -
trunk/UFormNew.lfm
r29 r31 30 30 end 31 31 object CheckBoxVoid: TCheckBox 32 Left = 832 Left = 16 33 33 Height = 24 34 Top = 1 6834 Top = 172 35 35 Width = 175 36 36 Caption = 'Inaccessible places' 37 OnChange = CheckBoxVoidChange 37 38 TabOrder = 2 38 39 end … … 129 130 TabOrder = 8 130 131 end 132 object SpinEdit1: TSpinEdit 133 Left = 224 134 Height = 32 135 Top = 168 136 Width = 106 137 MinValue = 1 138 TabOrder = 9 139 Value = 1 140 end 141 object Label3: TLabel 142 Left = 339 143 Height = 22 144 Top = 173 145 Width = 15 146 Caption = '%' 147 ParentColor = False 148 end 131 149 end -
trunk/UFormNew.lrt
r29 r31 12 12 TFORMNEW.LABEL2.CAPTION=x 13 13 TFORMNEW.BUTTONPLAYERMODIFY.CAPTION=Modify 14 TFORMNEW.LABEL3.CAPTION=% -
trunk/UFormNew.pas
r30 r31 22 22 Label1: TLabel; 23 23 Label2: TLabel; 24 Label3: TLabel; 24 25 ListView1: TListView; 26 SpinEdit1: TSpinEdit; 25 27 SpinEditMapSizeX: TSpinEdit; 26 28 SpinEditMapSizeY: TSpinEdit; … … 29 31 procedure ButtonPlayerModifyClick(Sender: TObject); 30 32 procedure ButtonPlayerRemoveClick(Sender: TObject); 33 procedure CheckBoxVoidChange(Sender: TObject); 31 34 procedure FormCreate(Sender: TObject); 32 35 procedure FormDestroy(Sender: TObject); … … 99 102 end; 100 103 104 procedure TFormNew.CheckBoxVoidChange(Sender: TObject); 105 begin 106 SpinEdit1.Enabled := CheckBoxVoid.Checked; 107 end; 108 101 109 procedure TFormNew.ButtonPlayerAddClick(Sender: TObject); 102 110 var … … 134 142 begin 135 143 CheckBoxVoid.Checked := Game.VoidEnabled; 144 SpinEdit1.Value := Game.VoidPercentage; 145 SpinEdit1.Enabled := Game.VoidEnabled; 136 146 for I := 0 to Players.Count - 1 do 137 147 Players[I] := nil; … … 158 168 end; 159 169 Game.VoidEnabled := CheckBoxVoid.Checked; 170 Game.VoidPercentage := SpinEdit1.Value; 160 171 Game.Map.Size := Point(SpinEditMapSizeX.Value, SpinEditMapSizeY.Value); 161 172 end; -
trunk/UGame.pas
r30 r31 159 159 Map: THexMap; 160 160 VoidEnabled: Boolean; 161 VoidPercentage: Integer; 161 162 CurrentPlayer: TPlayer; 162 163 Moves: TObjectList; // TList<TMove> … … 644 645 Players.Add(Player); 645 646 646 //VoidEnabled := True; 647 VoidEnabled := True; 648 VoidPercentage := 20; 647 649 648 650 Map := THexMap.Create; … … 673 675 for X := 0 to Map.Size.X - 1 do 674 676 with Map.Cells[Y, X] do begin 675 if VoidEnabled and (Random (2) =0) then Terrain := ttVoid677 if VoidEnabled and (Random < VoidPercentage / 100) then Terrain := ttVoid 676 678 else Terrain := ttNormal; 677 679 Power := Random(4);
Note:
See TracChangeset
for help on using the changeset viewer.