You last visited: Today at 06:35
Advertisement
[Release] Titanium Source Code
Discussion on [Release] Titanium Source Code within the Flyff PServer Guides & Releases forum part of the Flyff Private Server category.
03/10/2012, 22:31
#1
elite*gold: 0
Join Date: Feb 2012
Posts: 2,107
Received Thanks: 651
[Release] Titanium Source Code
Ich Release mal den Titanium Source Code.
Er ist in
C# .
Wer damit was anfangen kann hier ist er:
Code:
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.IO;
using System.Windows.Forms;
using System.IO.Compression;
using System.Security.Cryptography;
namespace Titanium
{
public static class Core
{
public static byte[] CreateList(List<string> lstFiles)
{
string strReturnValue = "";//ver:21\r\n Z:\\ResClient\r\n";
for (int i = 0; i < lstFiles.Count; i++)
{
bool bImportant;
if (bImportant = lstFiles[i].IndexOf(",IMPORTANT") != -1)
{
lstFiles[i] = lstFiles[i].Replace(",IMPORTANT", "");
}
FileInfo fi = new FileInfo(lstFiles[i]);
if (!fi.Exists)
{
DialogResult dr = MessageBox.Show("File " + lstFiles[i] + " was not found.", "File not found", MessageBoxButtons.AbortRetryIgnore, MessageBoxIcon.Error);
if (dr == DialogResult.Abort)
{
return new byte[0];
}
if (dr == DialogResult.Retry)
{
i--;
continue;
}
if (dr == DialogResult.Ignore)
{
continue;
}
}
string strDate = Core.GetDateFormat(fi.LastWriteTime);
if (!bImportant)
{
strReturnValue += string.Format("{0},{1}\r\n", lstFiles[i], fi.Length);
}
else
{
strReturnValue += string.Format("{0},{1},{2}\r\n", lstFiles[i], fi.Length, BitConverter.ToString(MD5.Create().ComputeHash(File.ReadAllBytes(fi.FullName))).Replace("-", ""));
}
}
return DoEncryption(bytes(strReturnValue));
}
static byte[] bytes(string s)
{
byte[] a = new byte[s.Length];
for (int i = 0; i < s.Length; i++)
{
a[i] = (byte)s[i];
}
return a;
}
public static byte[] DoEncryption(byte[] b)
{
if (b.Length < 1)
{
return new byte[0];
}
byte[] dec = new byte[b.Length];
byte bySeed = b[0];
for (int i = 0; i < b.Length; i++)
{
byte by = b[i];
for (int j = 0; j < DECRYPT_PASSWORD.Length; j++)
{
by = (byte)(b[i] ^ 0xFF ^ DECRYPT_PASSWORD[j]);
}
bySeed = by;
dec[i] = by;
}
return dec;
}
public const string DECRYPT_PASSWORD = "barbeque";
public static string GetDateFormat(DateTime dt)
{
int dwHour = dt.Hour;
string strMeridiem = "a";
if (dwHour > 12)
{
strMeridiem = "p";
dwHour -= 12;
}
return string.Format("{0:0000}-{1:00}-{2:00} {3:00}:{4:00}{5}", dt.Year, dt.Month, dt.Day, dwHour, dt.Minute, strMeridiem);
}
public static void CompressFile(string strPath)
{
strPath = strPath.Replace(",IMPORTANT", "");
lblRetry:
FileStream fh = null;
try
{
fh = new FileStream(strPath, FileMode.Open, FileAccess.Read, FileShare.Read);
}
catch
{
if (DialogResult.Retry != MessageBox.Show("File " + strPath + " could not be compressed: access was denied, or the file does not exist.", "Compression error", MessageBoxButtons.AbortRetryIgnore, MessageBoxIcon.Error))
{
return;
}
else
{
goto lblRetry;
}
}
byte[] buffer = new byte[fh.Length];
try
{
if (fh.Read(buffer, 0, buffer.Length) != buffer.Length)
{
if (DialogResult.Retry != MessageBox.Show("File " + strPath + " could not be compressed: failed to read the entire file.", "Compression error", MessageBoxButtons.AbortRetryIgnore, MessageBoxIcon.Error))
{
return;
}
else
{
goto lblRetry;
}
}
}
finally
{
fh.Close();
}
MemoryStream hmsInitialStream = new MemoryStream();
GZipStream gzh = new GZipStream(hmsInitialStream, CompressionMode.Compress, true);
gzh.Write(buffer, 0, buffer.Length);
gzh.Close();
hmsInitialStream.Position = 0;
byte[] @out = new byte[hmsInitialStream.Length];
hmsInitialStream.Read(@out, 0, @out.Length);
hmsInitialStream.Close();
lblRetryVerify:
try
{
if (!Core.VerifyDirectories("Morpheus\\PatchData\\" + strPath))
{
if (DialogResult.Retry != MessageBox.Show("Could not create directory: Morpheus\\PatchData\\" + Core.GetDirectoryName(strPath), "Compression error", MessageBoxButtons.AbortRetryIgnore, MessageBoxIcon.Error))
{
return;
}
else
{
goto lblRetryVerify;
}
}
else
{
File.WriteAllBytes("Morpheus\\PatchData\\" + Core.CutPath(strPath) + ".gz", @out);
}
}
catch
{
MessageBox.Show("Test");
}
}
public static bool VerifyDirectories(string strPath)
{
if (Directory.Exists(GetDirectoryName(strPath)))
{
return true;
}
else
{
try
{
strPath = GetDirectoryName(strPath);
string[] dirs = strPath.Split('\\');
string strCurrent = "";
for (int i = 0; i < dirs.Length; i++)
{
strCurrent += dirs[i] + "\\";
Directory.CreateDirectory(strCurrent);
}
return true;
}
catch
{
return false;
}
}
}
public static string GetDirectoryName(string strPath)
{
strPath = Core.CutPath(strPath);
if (strPath.IndexOf('\\') == -1 || strPath == "\\")
{
return ".";
}
else
{
string strTmp = strPath.Substring(0, strPath.LastIndexOf('\\'));
if (strTmp.Trim().Length == 0)
{
return ".";
}
else
{
return strTmp;
}
}
}
public static string CutPath(string strPath)
{
strPath = strPath.Replace('/', '\\');
if (strPath.IndexOf(Environment.CurrentDirectory) != -1)
{
strPath = strPath.Remove(strPath.IndexOf(Environment.CurrentDirectory), Environment.CurrentDirectory.Length);
}
return strPath;
}
public static List<InitialFile> ReadList(string strList)
{
//2009-08-27 06:03p
string[] data = strList.Split('\n');
List<InitialFile> lstRet = new List<InitialFile>();
for (int i = 0; i < data.Length; i++)
{
// Integrity check - sort of o_O
if (data[i].Length < 40 || data[i][4] != '-' || data[i][7] != '-' || data[i][14] != ':' || data[i].ToLower().IndexOf("<dir>") != -1)
{
continue;
}
InitialFile file = new InitialFile()
{
strTimestamp = data[i].Substring(0, "0000-00-00 00:00x".Length),
qwSize = long.Parse(data[i].Substring(18, 20).Trim()),
strPath = data[i].Substring(39).Trim(),
};
lstRet.Add(file);
}
return lstRet;
}
public static string ReverseDateFormat(string p)
{
/* public static string GetDateFormat(DateTime dt)
{
int dwHour = dt.Hour;
string strMeridiem = "a";
if (dwHour > 12)
{
strMeridiem = "p";
dwHour -= 12;
}
return string.Format("{0:0000}-{1:00}-{2:00} {3:00}:{4:00}{5}", dt.Year, dt.Month, dt.Day, dwHour, dt.Minute, strMeridiem);
}*/
string[] data = p.Split(" ".ToCharArray(), StringSplitOptions.RemoveEmptyEntries);
string[] date = data[0].Split('-');
string[] time = data[1].Split(':');
if (time[1][2] == 'p')
{
time[0] = (int.Parse(time[0].ToString()) + 12).ToString();
}
return new DateTime(int.Parse(date[0]), int.Parse(date[1]), int.Parse(date[2]), int.Parse(time[0]), int.Parse(time[1].Substring(0, 2)), 0).ToString();
}
}
public class InitialFile
{
public string strPath;
public string strTimestamp;
public long qwSize;
}
}
Er stammt nicht von mir ich habe ihn auf ein anderen Forum gefunden.
03/10/2012, 23:35
#2
elite*gold: 1
Join Date: May 2010
Posts: 676
Received Thanks: 223
Kannst doch noch drüber schreiben von was es ist.
Für die Leute die nicht wissen für was es ist:
Es ist der ehmaliger Patcher Source vom Server Titanuim wenn ich mich nicht irre . Da fehlt noch etwas?
Lg
DerGunga
03/10/2012, 23:48
#3
elite*gold: 0
Join Date: Feb 2012
Posts: 2,107
Received Thanks: 651
Das ist der Code von Titanium PatchList Creator...wie gesagt wer was mit anfangen kann bitte ansonsten klappe halten
03/11/2012, 16:06
#4
elite*gold: 0
Join Date: Sep 2010
Posts: 72
Received Thanks: 59
better titanium (source code + exe)
03/11/2012, 17:39
#5
elite*gold: 0
Join Date: Feb 2012
Posts: 2,107
Received Thanks: 651
yes its better but in franze
03/11/2012, 19:19
#6
elite*gold: 0
Join Date: Sep 2010
Posts: 72
Received Thanks: 59
easy to translate with google translate
10/22/2012, 18:48
#7
elite*gold: 0
Join Date: Nov 2011
Posts: 156
Received Thanks: 28
Hat jemand den französichen noch?
10/22/2012, 18:51
#8
elite*gold: 80
Join Date: Oct 2010
Posts: 2,238
Received Thanks: 1,271
Quote:
Originally Posted by
Eragøn
Hat jemand den französichen noch?
Quote:
Originally Posted by
jtb1
better titanium (source code + exe)
Wurde doch vor deinen augen geposted
10/22/2012, 18:53
#9
elite*gold: 12
Join Date: Jun 2011
Posts: 2,512
Received Thanks: 1,062
Quote:
Originally Posted by
Fremo.
Wurde doch vor deinen augen geposted
Vllt hast du Blitzmerker mal auf den Link geklickt ?
Similar Threads
[RELEASE(SOURCE CODE)]-- KabBOT2 v1 Full Source(vb6)
10/07/2011 - Dekaron Exploits, Hacks, Bots, Tools & Macros - 106 Replies
I've been meaning to post this for awhile but I pretty much forgot about it. I've been getting quite a few requests for it so I decided to finally get around to posting it.
#1. So here you go, Just have or Download Visual Basic 6, you need to update it to VbRuntime 6 Service Pack 6.
#2. Run the file name KabBOT.vbp.
#3. Enjoy.
100% Virus Free VirusTotal.com report.
VirusTotal - Free Online Virus, Malware and URL Scanner
[RELEASE] [OPEN SOURCE] CE 5.5 Pointer to AutoIt Source-Code
02/13/2011 - AutoIt - 6 Replies
Habe heute erst gemerkt, dass es hier eine AutoIt Sektion gibt xD also poste ich mal mein Programm mit rein.
Funktionsweise:
1. in CE Rechtsklick auf den Pointer und auf "Copy" klicken
2. in meinem Programm auf "Code generieren" klicken
3. In euer Scite gehen und einfügen
Hier ist der Source Code vom Programm:
All times are GMT +2. The time now is 06:36 .