CoEmu v2 5095: Errors, help, problems... POST HERE

06/03/2009 18:51 coreymills#121
Picture Error: [Only registered and activated users can see links. Click Here To Register...]

line of error: C = new MySqlConnection("Server=" + SERVER + ";Database='" + DATA_BASE + "';Username='" + USER_NAME + "';Password='" + PASSWORD + '"');

can someone help please.
06/03/2009 22:01 Adziunia#122
well i made step by step few times i used his helps Zeroxelli but i have still problem with acces danied i put correct username's and pass's and still nothing even i reinstalled appserv to change pass and nothing rolf other sources r working fine but this 1 cant lol maybe theres a bug idk if some1 could help :P
i am adding a pic but few ppl made it already :P [Only registered and activated users can see links. Click Here To Register...]
06/03/2009 22:05 DevilNemo#123
i need to know how i can Fix The NPC ?? In All Game
06/04/2009 00:39 kennylai#124
Hello, I need help on one of the steps. I saved the source and opened it. When I extracted and opened CoEmu v2.snl, this appears. Can someone tell me what I did wrong? Please and Thank you. Well you can't really see my picture, so I'll type it out. It says "One or more projects in the solutions could not be loaded for the following reason(s): The project file or web has been moved, renamed or is not on your computer. These projects will be labeled as unavailable in Solution Explorer. Expand the project node to show the reason the project could not be loaded."



And can anyone tell me how MySQL and PHPADMIN works? lol
06/04/2009 03:43 m4l4ria#125
How i Fix NPC item +1,+2...
And How i add Seller in Market and Fix Guard
06/04/2009 03:48 m4l4ria#126
Quote:
Originally Posted by Adziunia View Post
well i made step by step few times i used his helps Zeroxelli but i have still problem with acces danied i put correct username's and pass's and still nothing even i reinstalled appserv to change pass and nothing rolf other sources r working fine but this 1 cant lol maybe theres a bug idk if some1 could help :P
i am adding a pic but few ppl made it already :P [Only registered and activated users can see links. Click Here To Register...]
Go to database/databaseconnection.cs and add u ID and password of ur mysql
06/06/2009 18:00 Adziunia#127
lol as i said i put correct pass and id. does it working for anybody? i got few other sources and they r working!! this 1 cant maybe i am noob idk but for me its broken.
it would be great if some1 make an video guide for this

and i am using navicat for mysql for me its much more easier than phpmyadmin in browser :P
06/07/2009 20:53 Andrew.A#128
Im gettin this an error on line 31 of Auth Server
[Only registered and activated users can see links. Click Here To Register...]
This is my AuthServer.cs

Code:
/*
 * Created by SharpDevelop.
 * User: sams
 * Date: 3/8/2009
 * Time: 2:19 PM
 * 
 * To change this template use Tools | Options | Coding | Edit Standard Headers.
 */
using System;
using System.IO;
using System.Net.Sockets;

namespace CoEmu_v2_LoginServer.Connections
{
	/// <summary>
	/// Description of AuthSocket.
	/// </summary>
	public static class AuthSocket
	{
		private static Socket Auth;
        private const string SERVER_IP = "127.0.0.1";
        public const string NANO_IP = "86.149.255.50";
		private const int AUTH_PORT = 5817;
		
		public static bool Authorize(string user, uint key, bool nano)
		{
			try{
				Auth = new Socket(AddressFamily.InterNetwork, SocketType.Stream, ProtocolType.Tcp);
				if(!nano)
				{
					[COLOR="Red"]Auth.Connect(SERVER_IP, AUTH_PORT);[/COLOR]				}
				else{
					Auth.Connect(NANO_IP, AUTH_PORT);
				}
				Auth.Send(System.Text.Encoding.ASCII.GetBytes("(A)" + user + "," + key));
				Auth.Close();
			}
			catch(Exception e)
			{
				Console.WriteLine(e.ToString());
				return false;
			}
			return true;
		}
	}
}
However when i open this i manage to log in after a few tries?

Help????

I this it has something to do with this....
Code:
/*
 * Created by SharpDevelop.
 * User: sams
 * Date: 3/8/2009
 * Time: 12:38 PM
 * 
 * To change this template use Tools | Options | Coding | Edit Standard Headers.
 */
using System;
using CoEmu_v2_LoginServer.Connections;
using CoEmu_v2_LoginServer.Database;

namespace CoEmu_v2_LoginServer
{
	/// <summary>
	/// Allows for handling of packets from the client->loginserver or client->gameserver.
	/// </summary>
	public static class PacketProcessor
	{
		public static void ProcessPacket(byte[] Data, ClientSocket CSocket)
		{
			int Type = (Data[3] << 8) + Data[2];
			switch(Type)
			{
				case 1086:
					{
						RequestLogin(Data, CSocket);
						break;
					}
				default:
					{
						Console.WriteLine("[LoginServer] Unknown packet type: " + Type);
						break;
					}
			}
		}
		public static void RequestLogin(byte[] Data, ClientSocket CSocket)
		{
			string AccountName = "";
	        string Password = "";
	        string ServerName = "";
	        if(Data.Length >= 276)
	        {
		        for (int i = 4; i < 0x114; i++)
		        {
		            if (i >= 0x14 && i < 0xf9)
		            {
		            	if(Data[i] != 0x00)
		                Password += (Convert.ToString(Data[i], 16)).PadLeft(2, '0');
		            }
		            if (i < 0x14)
		                if (Data[i] != 0x00)
		                    AccountName += Convert.ToChar(Data[i]);
		            if (i > 0xfa)
		            	if (Data[i] != 0x00)
		                    ServerName += Convert.ToChar(Data[i]);
		        }
	        }
	        else
	        {
	        	return;
	        }
	       /* if(AccountName != "dsfreak")
	        {
	        	CSocket.Disconnect();
	        	return;
	        }*/
	        System.Random Random = new System.Random();
	        Console.WriteLine("[LoginServer] " + AccountName + " logging in to " + ServerName);
	        string DBPass = Database.Database.Password(AccountName);
	        //TODO: Check for ban.
	        if(DBPass != "ERROR")
	        {
	        	if(DBPass == Password)
	        	{
	        		//OKAY to login!
	        		uint Key = (uint)(Random.Next(10000000) << 32);
	        		Key = Key << 32;
        			Key = (uint)(Key | (uint)Random.Next(10000000));
        			byte[] Key1 = new byte[4];
			        byte[] Key2 = new byte[4];
			        Key1[0] = (byte)(((ulong)Key & 0xff00000000000000L) >> 56);
			        Key1[1] = (byte)((Key & 0xff000000000000) >> 48);
			        Key1[2] = (byte)((Key & 0xff0000000000) >> 40);
			        Key1[3] = (byte)((Key & 0xff00000000) >> 32);
			        Key2[0] = (byte)((Key & 0xff000000) >> 24);
			        Key2[1] = (byte)((Key & 0xff0000) >> 16);
			        Key2[2] = (byte)((Key & 0xff00) >> 8);
			        Key2[3] = (byte)(Key & 0xff);
[COLOR="red"]			        if(ServerName == "PixelEmpire")
			        {
                        /*if(AuthSocket.Authorize(AccountName, Key, false))
                        {
                            CSocket.Send(Packets.AuthResponse("127.0.0.1", Key1, Key2));
                        }
                        else
                        {
                            CSocket.Disconnect();
                        }*/
                        if (AuthSocket.Authorize(AccountName, Key, false))
				        {
                            CSocket.Send(Packets.AuthResponse("127.0.0.1", Key1, Key2));
				        }
				        else
				        {
				        	CSocket.Disconnect();
				        }
			        }
			        else if(ServerName == "CoEmu.Nano")
			        {
			        	if(AuthSocket.Authorize(AccountName, Key, true))
				        {
                            CSocket.Send(Packets.AuthResponse("127.0.0.1", Key1, Key2));
				        }
				        else
				        {
				        	CSocket.Disconnect();
				        }
			        }
	        	}[/COLOR]	        	else if(DBPass == "")
	        	{
	        		Console.WriteLine("[LoginServer](Diagnostic) Set password for " + AccountName);
	        		Database.Database.SetPass(AccountName, Password);
	        		//OKAY to login!
	        		uint Key = (uint)(Random.Next(10000000) << 32);
	        		Key = Key << 32;
        			Key = (uint)(Key | (uint)Random.Next(10000000));
        			byte[] Key1 = new byte[4];
			        byte[] Key2 = new byte[4];
			        Key1[0] = (byte)(((ulong)Key & 0xff00000000000000L) >> 56);
			        Key1[1] = (byte)((Key & 0xff000000000000) >> 48);
			        Key1[2] = (byte)((Key & 0xff0000000000) >> 40);
			        Key1[3] = (byte)((Key & 0xff00000000) >> 32);
			        Key2[0] = (byte)((Key & 0xff000000) >> 24);
			        Key2[1] = (byte)((Key & 0xff0000) >> 16);
			        Key2[2] = (byte)((Key & 0xff00) >> 8);
			        Key2[3] = (byte)(Key & 0xff);
[COLOR="RoyalBlue"]			        if(ServerName == "PixelEmpire")
			        {
                        /*if(AuthSocket.Authorize(AccountName, Key, false))
                        {
                            CSocket.Send(Packets.AuthResponse("86.149.255.50", Key1, Key2));
                        }
                        else
                        {
                            CSocket.Disconnect();
                        }*/
                        if (AuthSocket.Authorize(AccountName, Key, false))
				        {
                            CSocket.Send(Packets.AuthResponse("86.149.255.50", Key1, Key2));
				        }
				        else
				        {
				        	CSocket.Disconnect();
				        }
			        }
			        else if(ServerName == "CoEmu.Nano")
			        {
			        	if(AuthSocket.Authorize(AccountName, Key, true))
				        {
                            CSocket.Send(Packets.AuthResponse("86.149.255.50", Key1, Key2));
				        }
				        else
				        {
				        	CSocket.Disconnect();
				        }
			        }
	        	}
	        	else
	        	{
	        		CSocket.Send(Packets.WrongPass());
	        		CSocket.Disconnect();
	        	}
	        }
	        else
	        {
	        	Console.WriteLine("DBPass equals ERROR: " + DBPass);
	        	CSocket.Disconnect();
	        }
		}
	}
}[/COLOR]
I did that to see If it would let both on at the same time but im confused now Help please.
06/07/2009 21:33 dodolinobobo#129
Quote:
Originally Posted by coreymills View Post
Picture Error: [Only registered and activated users can see links. Click Here To Register...]

line of error: C = new MySqlConnection("Server=" + SERVER + ";Database='" + DATA_BASE + "';Username='" + USER_NAME + "';Password='" + PASSWORD + '"');

can someone help please.
Just change:C = new MySqlConnection("Server=" + SERVER + ";Database='" + DATA_BASE + "';Username='" + USER_NAME + "';Password='" + PASSWORD + '"')

With:C = new MySqlConnection("Server=" + SERVER + ";Database='" + DATA_BASE + "';Username='" + USER_NAME + "';Password='" + PASSWORD + "'; Min Pool Size = 300; Max Pool Size = 900");pooling = false;

Thanks me if Helped you:)

Edit:All credits 4 Zeroxelli :)
06/07/2009 23:42 samig#130
Known problems:
*This CANNOTbe run on any 64 Bit OS unless you rebuild ManagedOpenSSL using libeay64.dll, change the name of the dll the project wraps (at the moment it's libeay32, you need to change it to libeay64) *credits go to tanelipe* (but how do u go about rebuilding it? D=)


Uhm, i dn if im a 64-bit, but i do know im getting the OpenSSL problem. ALL my ips are right, my root user and pssword in both game and login server, everything is done correctly. Uhm, then someone told me i have to recompile it in the C# editor thing, and this is what i get.

Error 2 The type or namespace name 'OpenSSL' could not be found (are you missing a using directive or an assembly reference?) C:\Documents and Settings\Mark\Desktop\Arctic Server\CoEmu v2\CoEmu v2 GameServer\Encryption\GameEncryption.cs 12 7 CoEmu v2 GameServer


i get this in error, according to the program, in like 8 different places. i changed libeay32 to 64, but what do u mean repair it by changing the name?
lollll this is painful to get going
06/07/2009 23:54 pedro93#131
How do people come to my server because when I try to tell you that the server is under maintenance
06/08/2009 00:18 samig#132
Ok, i re extrated the source, and i was hoping someone who knows how to fix the OpenSSL thingy could do a teamviewer and help me out >>__<< And apperently im running a 32-bit, so thats not the problem...
06/08/2009 02:55 samig#133
OK i got both login and game server to load. Now my connection keeps timing out. wtf do i need to do? shud i b using hamachi? cuz i am XD
06/08/2009 03:52 killerbee#134
anybody know how to make other char see the equipment on other char. i log in 2 acc and you will see the other char naked.
06/08/2009 04:25 samig#135
Whenever I try to log in it says *Failed to connect, please relogin later*

rayne authenticated from Login Server
rayne's connection has timed out

Either add me ([Only registered and activated users can see links. Click Here To Register...]) or post the cure..