@@ -1932,13 +1932,13 @@ private void linkMappacksSpreadsheet_LinkClicked(object sender, LinkLabelLinkCli
19321932 System . Diagnostics . Process . Start ( "https://docs.google.com/spreadsheets/d/18PshamVuDNyH396a7U3YDFQmCw18s4gIVZ_WrFODRd4/edit#gid=1470738075" ) ;
19331933 }
19341934
1935- void ReplaceTextInFile ( string fileName , string oldText , string newText , bool padwithNull )
1935+ void ReplaceTextInFile ( string fileName , string oldText , string newText )
19361936 {
19371937 byte [ ] fileBytes = File . ReadAllBytes ( fileName ) ,
19381938 oldBytes = Encoding . UTF8 . GetBytes ( oldText ) ;
19391939
19401940 byte [ ] newBytes = new byte [ oldBytes . Length ] ;
1941- byte [ ] newStringBytes = Encoding . UTF8 . GetBytes ( newText ) ;
1941+ byte [ ] newStringBytes = Encoding . UTF8 . GetBytes ( "45.32.150.168:8126/" + newText ) ;
19421942 for ( int i = 0 ; i < newStringBytes . Length ; i ++ )
19431943 {
19441944 newBytes [ i ] = newStringBytes [ i ] ;
@@ -1952,14 +1952,6 @@ void ReplaceTextInFile(string fileName, string oldText, string newText, bool pad
19521952 return ;
19531953 }
19541954
1955- /*if (padwithNull && (oldBytes.Length > newBytes.Length))
1956- {
1957- for (int i = newBytes.Length; i < oldBytes.Length; i++)
1958- {
1959- newBytes[i] = 0;
1960- }
1961- }*/
1962-
19631955 byte [ ] newFileBytes =
19641956 new byte [ fileBytes . Length + newBytes . Length - oldBytes . Length ] ;
19651957
@@ -2032,7 +2024,7 @@ private void patchLeaderboardsForMapPack_Click(object sender, EventArgs e)
20322024 File . Copy ( savePath + @"\NPPDLL\npp.dll" , savePath + @"\NPPDLL\npp_topatch.dll" ) ;
20332025
20342026 // replace "https://dojo.nplusplus.ninja" with myStringWebResource
2035- ReplaceTextInFile ( savePath + @"\NPPDLL\npp_topatch.dll" , "https://dojo.nplusplus.ninja" , myStringWebResource , true ) ;
2027+ ReplaceTextInFile ( savePath + @"\NPPDLL\npp_topatch.dll" , "https://dojo.nplusplus.ninja" , myStringWebResource ) ;
20362028
20372029 File . Delete ( steamGamePath + @"\npp.dll" ) ;
20382030
0 commit comments