Changeset 473 for tools/wow_patcher
- Timestamp:
- Apr 23, 2010, 8:45:12 PM (15 years ago)
- Location:
- tools/wow_patcher
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
tools/wow_patcher/wowpatcher.lpi
r470 r473 39 39 <IsPartOfProject Value="True"/> 40 40 <UnitName Value="wowpatcher"/> 41 <CursorPos X=" 24" Y="39"/>42 <TopLine Value=" 27"/>41 <CursorPos X="30" Y="130"/> 42 <TopLine Value="122"/> 43 43 <EditorIndex Value="0"/> 44 <UsageCount Value="4 8"/>44 <UsageCount Value="49"/> 45 45 <Loaded Value="True"/> 46 46 </Unit0> … … 71 71 <Position1> 72 72 <Filename Value="wowpatcher.pas"/> 73 <Caret Line="9 4" Column="1" TopLine="75"/>73 <Caret Line="96" Column="17" TopLine="78"/> 74 74 </Position1> 75 75 <Position2> 76 76 <Filename Value="wowpatcher.pas"/> 77 <Caret Line="9 2" Column="5" TopLine="76"/>77 <Caret Line="95" Column="1" TopLine="76"/> 78 78 </Position2> 79 79 <Position3> 80 80 <Filename Value="wowpatcher.pas"/> 81 <Caret Line="9 5" Column="1" TopLine="76"/>81 <Caret Line="96" Column="1" TopLine="77"/> 82 82 </Position3> 83 83 <Position4> 84 84 <Filename Value="wowpatcher.pas"/> 85 <Caret Line="9 6" Column="1" TopLine="77"/>85 <Caret Line="95" Column="1" TopLine="76"/> 86 86 </Position4> 87 87 <Position5> 88 88 <Filename Value="wowpatcher.pas"/> 89 <Caret Line="9 7" Column="1" TopLine="78"/>89 <Caret Line="96" Column="1" TopLine="77"/> 90 90 </Position5> 91 91 <Position6> 92 92 <Filename Value="wowpatcher.pas"/> 93 <Caret Line="9 8" Column="1" TopLine="79"/>93 <Caret Line="95" Column="1" TopLine="76"/> 94 94 </Position6> 95 95 <Position7> 96 96 <Filename Value="wowpatcher.pas"/> 97 <Caret Line="9 9" Column="1" TopLine="80"/>97 <Caret Line="97" Column="1" TopLine="78"/> 98 98 </Position7> 99 99 <Position8> 100 100 <Filename Value="wowpatcher.pas"/> 101 <Caret Line=" 100" Column="1" TopLine="81"/>101 <Caret Line="98" Column="1" TopLine="79"/> 102 102 </Position8> 103 103 <Position9> 104 104 <Filename Value="wowpatcher.pas"/> 105 <Caret Line=" 101" Column="1" TopLine="82"/>105 <Caret Line="99" Column="1" TopLine="80"/> 106 106 </Position9> 107 107 <Position10> 108 108 <Filename Value="wowpatcher.pas"/> 109 <Caret Line=" 104" Column="1" TopLine="85"/>109 <Caret Line="98" Column="1" TopLine="79"/> 110 110 </Position10> 111 111 <Position11> 112 112 <Filename Value="wowpatcher.pas"/> 113 <Caret Line="9 5" Column="1" TopLine="76"/>113 <Caret Line="99" Column="1" TopLine="80"/> 114 114 </Position11> 115 115 <Position12> 116 116 <Filename Value="wowpatcher.pas"/> 117 <Caret Line=" 96" Column="17" TopLine="78"/>117 <Caret Line="100" Column="1" TopLine="81"/> 118 118 </Position12> 119 119 <Position13> 120 120 <Filename Value="wowpatcher.pas"/> 121 <Caret Line=" 95" Column="1" TopLine="76"/>121 <Caret Line="85" Column="64" TopLine="84"/> 122 122 </Position13> 123 123 <Position14> 124 124 <Filename Value="wowpatcher.pas"/> 125 <Caret Line=" 96" Column="1" TopLine="77"/>125 <Caret Line="149" Column="1" TopLine="131"/> 126 126 </Position14> 127 127 <Position15> 128 128 <Filename Value="wowpatcher.pas"/> 129 <Caret Line=" 95" Column="1" TopLine="76"/>129 <Caret Line="117" Column="24" TopLine="98"/> 130 130 </Position15> 131 131 <Position16> 132 132 <Filename Value="wowpatcher.pas"/> 133 <Caret Line=" 96" Column="1" TopLine="77"/>133 <Caret Line="157" Column="5" TopLine="125"/> 134 134 </Position16> 135 135 <Position17> 136 136 <Filename Value="wowpatcher.pas"/> 137 <Caret Line=" 95" Column="1" TopLine="76"/>137 <Caret Line="159" Column="65" TopLine="128"/> 138 138 </Position17> 139 139 <Position18> 140 140 <Filename Value="wowpatcher.pas"/> 141 <Caret Line=" 97" Column="1" TopLine="78"/>141 <Caret Line="157" Column="1" TopLine="130"/> 142 142 </Position18> 143 143 <Position19> 144 144 <Filename Value="wowpatcher.pas"/> 145 <Caret Line=" 98" Column="1" TopLine="79"/>145 <Caret Line="158" Column="49" TopLine="121"/> 146 146 </Position19> 147 147 <Position20> 148 148 <Filename Value="wowpatcher.pas"/> 149 <Caret Line=" 99" Column="1" TopLine="80"/>149 <Caret Line="76" Column="60" TopLine="55"/> 150 150 </Position20> 151 151 <Position21> 152 152 <Filename Value="wowpatcher.pas"/> 153 <Caret Line=" 98" Column="1" TopLine="79"/>153 <Caret Line="148" Column="23" TopLine="125"/> 154 154 </Position21> 155 155 <Position22> 156 156 <Filename Value="wowpatcher.pas"/> 157 <Caret Line=" 99" Column="1" TopLine="80"/>157 <Caret Line="118" Column="29" TopLine="99"/> 158 158 </Position22> 159 159 <Position23> 160 160 <Filename Value="wowpatcher.pas"/> 161 <Caret Line="1 00" Column="1" TopLine="81"/>161 <Caret Line="132" Column="42" TopLine="110"/> 162 162 </Position23> 163 163 <Position24> 164 164 <Filename Value="wowpatcher.pas"/> 165 <Caret Line=" 85" Column="64" TopLine="84"/>165 <Caret Line="129" Column="12" TopLine="110"/> 166 166 </Position24> 167 167 <Position25> 168 168 <Filename Value="wowpatcher.pas"/> 169 <Caret Line=" 149" Column="1" TopLine="131"/>169 <Caret Line="21" Column="50" TopLine="2"/> 170 170 </Position25> 171 171 <Position26> 172 172 <Filename Value="wowpatcher.pas"/> 173 <Caret Line="1 17" Column="24" TopLine="98"/>173 <Caret Line="108" Column="40" TopLine="102"/> 174 174 </Position26> 175 175 <Position27> 176 176 <Filename Value="wowpatcher.pas"/> 177 <Caret Line="1 57" Column="5" TopLine="125"/>177 <Caret Line="133" Column="22" TopLine="114"/> 178 178 </Position27> 179 179 <Position28> 180 180 <Filename Value="wowpatcher.pas"/> 181 <Caret Line=" 159" Column="65" TopLine="128"/>181 <Caret Line="20" Column="43" TopLine="2"/> 182 182 </Position28> 183 183 <Position29> 184 184 <Filename Value="wowpatcher.pas"/> 185 <Caret Line=" 157" Column="1" TopLine="130"/>185 <Caret Line="76" Column="55" TopLine="76"/> 186 186 </Position29> 187 187 <Position30> 188 188 <Filename Value="wowpatcher.pas"/> 189 <Caret Line="1 58" Column="49" TopLine="121"/>189 <Caret Line="138" Column="15" TopLine="119"/> 190 190 </Position30> 191 191 </JumpHistory> -
tools/wow_patcher/wowpatcher.pas
r406 r473 18 18 TWoWPatcher = class(TCustomApplication) 19 19 private 20 function FindSequence(Data, Sequence: array of Byte; Position: Integer = 0): Integer; 20 function FindSequence(Data: array of Byte; Sequence: array of Integer; Position: Integer = 0): Integer; 21 procedure WriteHexData(Data: array of Integer; From, Count: Integer); 21 22 procedure WriteHexData(Data: array of Byte; From, Count: Integer); 22 23 protected … … 74 75 end; 75 76 76 function TWoWPatcher.FindSequence(Data , Sequence: array of Byte; Position: Integer = 0): Integer;77 function TWoWPatcher.FindSequence(Data: array of Byte; Sequence: array of Integer; Position: Integer = 0): Integer; 77 78 var 78 79 I: Integer; … … 87 88 Same := True; 88 89 for II := 0 to High(Sequence) do begin 89 if Data[I + II] <> Sequence[II]then begin90 if (Sequence[II] <> -1) and (Data[I + II] <> Sequence[II]) then begin 90 91 Same := False; 91 92 Break; … … 98 99 end; 99 100 end; 101 end; 102 103 procedure TWoWPatcher.WriteHexData(Data: array of Integer; From, Count: Integer); 104 var 105 I: Integer; 106 begin 107 for I := From to From + Count - 1 do 108 if Data[I] <> -1 then 109 Write(IntToHex(Data[I], 2) + ' ') 110 else Write('XX '); 100 111 end; 101 112 … … 116 127 I: Integer; 117 128 const 118 StartSequence: array[0.. 9] of Byte = ($FF, $FF, $5B, $8B, $E5, $5D, $C3, $8D, $49, $00);119 StartSequence2: array[0.. 9] of Byte = ($E8, $71, $09, $FB, $FF, $5B, $8B, $E5, $5D, $C3);129 StartSequence: array[0..15] of Integer = ($8D, $4D, $E8, $E8, -1, -1, -1, -1, $5B, $8B, $E5, $5D, $C3, $8D, $49, $00); 130 StartSequence2: array[0..15] of Integer = ($88, $1D, -1, -1, -1, -1, $E8, -1, -1, -1, -1, $5B, $8B, $E5, $5D, $C3); 120 131 begin 121 132 OriginalFile := TFileStream.Create(FileName, fmOpenRead);
Note:
See TracChangeset
for help on using the changeset viewer.