Register for your free account! | Forgot your password?

Go Back   elitepvpers > MMORPGs > Conquer Online 2 > CO2 Private Server > CO2 PServer Guides & Releases
You last visited: Today at 04:45

  • Please register to post and access all features, it's quick, easy and FREE!

Advertisement



[Exclusive]Fixed Source 5165 reed D:\OldCODB Rather than C:\OldCODB and more

Discussion on [Exclusive]Fixed Source 5165 reed D:\OldCODB Rather than C:\OldCODB and more within the CO2 PServer Guides & Releases forum part of the CO2 Private Server category.

Closed Thread
 
Old 12/06/2010, 10:29   #46
 
elite*gold: 0
Join Date: Nov 2010
Posts: 1,162
Received Thanks: 370
Quote:
Originally Posted by Bogdan51 View Post
This ie my source
Man I feel sorry for u, because u aren't the creator.

If you really made it, explain this please:
Code:
    public unsafe class COPacket
    {
        byte[] PData;
        public ushort PType;
        int Count;

        public byte* Ptr
        {
            get
            {
                fixed (byte* p = PData)
                    return p;
            }
        }

        public byte[] Get
        {
            get
            {
                return PData;
            }
        }
        public ushort InLength
        {
            get
            {
                return *((ushort*)(Ptr));
            }
        }
        public ushort Type
        {
            get
            {
                return *((ushort*)(Ptr + 2));
            }
        }
        public unsafe COPacket(byte[] Data)
        {
            Count = 0;
            PData = Data;
        }
        public unsafe void WriteByte(byte val)
        {
            *((byte*)(Ptr + Count)) = val;
            Count++;
        }
        public unsafe void WriteInt16(ushort val)
        {
            *((ushort*)(Ptr + Count)) = val;
            Count += 2;
        }
        public unsafe void WriteInt32(uint val)
        {
            *((uint*)(Ptr + Count)) = val;
            Count += 4;
        }
        public unsafe void WriteInt64(ulong val)
        {
            *((ulong*)(Ptr + Count)) = val;
            Count += 8;
        }
        public unsafe void WriteString(string val)
        {
            for (int i = 0; i < val.Length; i++)
            {
                try
                {
                    *((byte*)(Ptr + Count)) = Convert.ToByte(val[i]);
                }
                catch { }//For weird letters that cannot be converted into byte...
                Count++;
            }
        }
        public unsafe void WriteString(string val, int MaxLength)
        {
            if (val.Length <= MaxLength)
                for (int i = 0; i < val.Length; i++)
                {
                    *((byte*)(Ptr + Count)) = Convert.ToByte(val[i]);
                    Count++;
                }
            else
                for (int i = 0; i < MaxLength; i++)
                {
                    *((byte*)(Ptr + Count)) = Convert.ToByte(val[i]);
                    Count++;
                }
        }
        public unsafe void WriteBytes(byte[] val)
        {
            for (int i = 0; i < val.Length; i++)
            {
                *((byte*)(Ptr + Count)) = val[i];
                Count++;
            }
        }
        public void Move(int count)
        {
            Count += count;
        }
    }
Syst3m_W1z4rd is offline  
Old 12/06/2010, 11:43   #47
 
elite*gold: 0
Join Date: Apr 2010
Posts: 291
Received Thanks: 61
Talking

Quote:
Originally Posted by 1337 H4X0R View Post
Man I feel sorry for u, because u aren't the creator.

If you really made it, explain this please:
Code:
    public unsafe class COPacket
    {
        byte[] PData;
        public ushort PType;
        int Count;

        public byte* Ptr
        {
            get
            {
                fixed (byte* p = PData)
                    return p;
            }
        }

        public byte[] Get
        {
            get
            {
                return PData;
            }
        }
        public ushort InLength
        {
            get
            {
                return *((ushort*)(Ptr));
            }
        }
        public ushort Type
        {
            get
            {
                return *((ushort*)(Ptr + 2));
            }
        }
        public unsafe COPacket(byte[] Data)
        {
            Count = 0;
            PData = Data;
        }
        public unsafe void WriteByte(byte val)
        {
            *((byte*)(Ptr + Count)) = val;
            Count++;
        }
        public unsafe void WriteInt16(ushort val)
        {
            *((ushort*)(Ptr + Count)) = val;
            Count += 2;
        }
        public unsafe void WriteInt32(uint val)
        {
            *((uint*)(Ptr + Count)) = val;
            Count += 4;
        }
        public unsafe void WriteInt64(ulong val)
        {
            *((ulong*)(Ptr + Count)) = val;
            Count += 8;
        }
        public unsafe void WriteString(string val)
        {
            for (int i = 0; i < val.Length; i++)
            {
                try
                {
                    *((byte*)(Ptr + Count)) = Convert.ToByte(val[i]);
                }
                catch { }//For weird letters that cannot be converted into byte...
                Count++;
            }
        }
        public unsafe void WriteString(string val, int MaxLength)
        {
            if (val.Length <= MaxLength)
                for (int i = 0; i < val.Length; i++)
                {
                    *((byte*)(Ptr + Count)) = Convert.ToByte(val[i]);
                    Count++;
                }
            else
                for (int i = 0; i < MaxLength; i++)
                {
                    *((byte*)(Ptr + Count)) = Convert.ToByte(val[i]);
                    Count++;
                }
        }
        public unsafe void WriteBytes(byte[] val)
        {
            for (int i = 0; i < val.Length; i++)
            {
                *((byte*)(Ptr + Count)) = val[i];
                Count++;
            }
        }
        public void Move(int count)
        {
            Count += count;
        }
    }
It Isn't his, Zeko's either,, And You know which is it.. Why Do you even bother with this shit,, let this thread die. *It's Useless*
†he Knight is offline  
Thanks
1 User
Old 12/07/2010, 15:08   #48
 
janvier123's Avatar
 
elite*gold: 20
Join Date: Nov 2007
Posts: 2,854
Received Thanks: 1,891
Reportet at 12.07.2010 - 3:09 PM
-multiple post (please use the "Edit-Button")
Quote:
doubleposting, or pushing up really old topics is not allowed and ends up in an infraction / a warning
Please read the
janvier123 is offline  
Old 12/07/2010, 17:39   #49
 
elite*gold: 0
Join Date: Sep 2008
Posts: 1,683
Received Thanks: 506
Ownership of these sources isn't something we should discuss on this particular thread (nor anywhere else @ epvp - imo)
Basser is offline  
Thanks
2 Users
Closed Thread


Similar Threads Similar Threads
[Help] Explaining npc code in oldcodb (npc.txt) + how to delete npcs
02/05/2012 - CO2 Private Server - 5 Replies
Can anyone help explain to me the code in npc.txt in OLDCODB These are how some of the codes appear: 4 40 1 0 1002 412 366 423 2706 1 0 1002 412 361 44 87 3 0 1036 182 180 185 1086 16 0 1036 230 173 184 1086 16 0 1036 230 177
[Help]Saving Halos (in OldCODB)
01/19/2010 - CO2 Private Server - 6 Replies
okay so my plan is to save the Halos (i assume you all know what that is) in OldCODB same as the other things such as, Nobility. Nobility saves the names of people inside the Nobility.dat in OldCODB. So I found out where it sends the info save to OldCODB which is in Database.cs. So I'm trying to make something similar to saving Halos. (so that when you log out it gets saved so that when you re-log you still have it.) So I'm taking this as an example. But I noticed It's only 1 of these...
[Request]Npc's.txt from OLDCODB!
11/30/2009 - CO2 Private Server - 4 Replies
Hey alll , anyone have Npc's.txt with ALL NPC ADDED PLZ? because when I add npcs my srv give error..:) Thanks



All times are GMT +1. The time now is 04:46.


Powered by vBulletin®
Copyright ©2000 - 2026, Jelsoft Enterprises Ltd.
SEO by vBSEO ©2011, Crawlability, Inc.
This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

Support | Contact Us | FAQ | Advertising | Privacy Policy | Terms of Service | Abuse
Copyright ©2026 elitepvpers All Rights Reserved.