|
You last visited: Today at 01:16
Advertisement
Max Players
Discussion on Max Players within the CO2 Private Server forum part of the Conquer Online 2 category.
11/14/2008, 10:11
|
#1
|
elite*gold: 0
Join Date: Jun 2008
Posts: 70
Received Thanks: 3
|
Max Players
I want Know how i can make My Server Max Player
loggin on it Like 200 Player
and Something more
how i can Delet the NPC Guy For make RB
can some one Give me Id and i will Delet From my Server
i Hate RB
|
|
|
11/14/2008, 11:11
|
#2
|
elite*gold: 20
Join Date: Jun 2005
Posts: 1,489
Received Thanks: 301
|
LOL your server won't even touch anything close to 200 players no need to set a max players you'll be lucky if u can get 20 on yours
|
|
|
11/14/2008, 14:13
|
#3
|
elite*gold: 0
Join Date: Jun 2007
Posts: 387
Received Thanks: 64
|
Lol, even if you did, what makes you think your server can handle 200 people without crashing?
|
|
|
11/14/2008, 15:14
|
#4
|
elite*gold: 1142
Join Date: Aug 2006
Posts: 2,464
Received Thanks: 1,162
|
Not giving this hint for the thread starter,since he will be a loser anyways,but to all the others,this is an example on top of my head:
Lets say you want 50 people to be maximal on your server, you can do like this:
At case 74, above all the surrondme, sendmetoothers blahblah blah, something like this maybe?:
byte MaxPlayers = AMOUT;
Okay,great! Now you have MaxPlayers defined, if we should do what we said,it would be 50, right?
Okay,lets move on.
Now,what is the definiton for the All characters online? Its "World.AllChar", right? Now,we need to have an count on this,simply we do this : World.AllChar.Count , alright?
Good.
Now,we gotta check if the World.AllChar.Count is the same or above as the MaxPlayer Limit, alright? This is simple to anyone who actually knows how to code,so im not even going to mention it, you could give the stupid epvp leeching community a thanks if you're happy with that,lol.
Okay,then, we did , if allchar.count is the same as the limit or above , we drop the player of the server,like this:
SendPacket(General.MyPackets.SendMsg(MessageId, "SYSTEM", MyChar.Name, "The server is full, please try again later! ", 2000));
MyChar.MyClient.Drop();
Note, always have the MaxPlayers one more than the real one, if you want an limit of 20 people, put the MaxPlayers to 21, since it drops the character that reach the limit that is defined.
Hope it gave you some hints and ideas!
Emme
|
|
|
11/14/2008, 17:13
|
#5
|
elite*gold: 0
Join Date: Jun 2008
Posts: 70
Received Thanks: 3
|
i Will Try And i Hope i Make it Work
U Are Best Man in Evrey Thread i Make u Help me
u Are Really Great Man
ty emme Again  
and Who Answer me ur server will be max 20
ty i Just Say Like 200 ppl not i want my server 200 ppl
That Good For me But Bad for u
|
|
|
11/15/2008, 01:08
|
#6
|
elite*gold: 20
Join Date: Mar 2006
Posts: 6,126
Received Thanks: 2,518
|
Quote:
Originally Posted by EmmeTheCoder
Not giving this hint for the thread starter,since he will be a loser anyways,but to all the others,this is an example on top of my head:
Lets say you want 50 people to be maximal on your server, you can do like this:
At case 74, above all the surrondme, sendmetoothers blahblah blah, something like this maybe?:
byte MaxPlayers = AMOUT;
Okay,great! Now you have MaxPlayers defined, if we should do what we said,it would be 50, right?
Okay,lets move on.
Now,what is the definiton for the All characters online? Its "World.AllChar", right? Now,we need to have an count on this,simply we do this : World.AllChar.Count , alright?
Good.
Now,we gotta check if the World.AllChar.Count is the same or above as the MaxPlayer Limit, alright? This is simple to anyone who actually knows how to code,so im not even going to mention it, you could give the stupid epvp leeching community a thanks if you're happy with that,lol.
Okay,then, we did , if allchar.count is the same as the limit or above , we drop the player of the server,like this:
SendPacket(General.MyPackets.SendMsg(MessageId, "SYSTEM", MyChar.Name, "The server is full, please try again later! ", 2000));
MyChar.MyClient.Drop();
Note, always have the MaxPlayers one more than the real one, if you want an limit of 20 people, put the MaxPlayers to 21, since it drops the character that reach the limit that is defined.
Hope it gave you some hints and ideas!
Emme
|
Why do any of that?
Just goto your connection system, and just make the array that stores the active connections have a limit of 200 >_>
|
|
|
11/15/2008, 01:34
|
#7
|
elite*gold: 1142
Join Date: Aug 2006
Posts: 2,464
Received Thanks: 1,162
|
I find this simple enough, no need to change it in my opinion, wont use too much memory and space.
Quote:
byte MaxAmout = 20;
if (World.AllChars.Count == MaxAmout + 1)
{
MyChar.Save();
MyChar.MyClient.Drop();
}
|
Rest is just writelines,nothing important.
|
|
|
11/15/2008, 08:24
|
#8
|
elite*gold: 0
Join Date: Jun 2008
Posts: 70
Received Thanks: 3
|
Quote:
Originally Posted by Korvacs
Why do any of that?
Just goto your connection system, and just make the array that stores the active connections have a limit of 200 >_>
|
ty emme i Will Learn Some C# and try
But Kor Where i can Find Connection
or tell me how i can Create
|
|
|
11/15/2008, 09:19
|
#9
|
elite*gold: 0
Join Date: Dec 2007
Posts: 618
Received Thanks: 213
|
Quote:
Originally Posted by EmmeTheCoder
Not giving this hint for the thread starter,since he will be a loser anyways,but to all the others,this is an example on top of my head:
Lets say you want 50 people to be maximal on your server, you can do like this:
At case 74, above all the surrondme, sendmetoothers blahblah blah, something like this maybe?:
byte MaxPlayers = AMOUT;
Okay,great! Now you have MaxPlayers defined, if we should do what we said,it would be 50, right?
Okay,lets move on.
Now,what is the definiton for the All characters online? Its "World.AllChar", right? Now,we need to have an count on this,simply we do this : World.AllChar.Count , alright?
Good.
Now,we gotta check if the World.AllChar.Count is the same or above as the MaxPlayer Limit, alright? This is simple to anyone who actually knows how to code,so im not even going to mention it, you could give the stupid epvp leeching community a thanks if you're happy with that,lol.
Okay,then, we did , if allchar.count is the same as the limit or above , we drop the player of the server,like this:
SendPacket(General.MyPackets.SendMsg(MessageId, "SYSTEM", MyChar.Name, "The server is full, please try again later! ", 2000));
MyChar.MyClient.Drop();
Note, always have the MaxPlayers one more than the real one, if you want an limit of 20 people, put the MaxPlayers to 21, since it drops the character that reach the limit that is defined.
Hope it gave you some hints and ideas!
Emme
|
that couldnt ever do a "Max Player" thing all u have to add is in general.cs a byte "maxplayers" and at game-connection-handler after the send char info, maxplayers++; bla bla and before if(maxplayers > 50) return;
an example is:
Code:
public void GamePacketHandler(object Sender, HybridSocket Socket)
{
try
{
if (ConnectedPlayers < 51)
{
Socket Sock = Socket.WinSock;
IPEndPoint IPE = (IPEndPoint)Sock.RemoteEndPoint;
string Ip = Convert.ToString(IPE.Address);
int Port = IPE.Port;
byte[] Data = Socket.Packet;
if (Socket.Wrapper != null)
{
Client Cli = (Client)Socket.Wrapper;
Cli.GetPacket(Data);
}
else
{
Cryptographer TempCrypto = new Cryptographer();
TempCrypto.Decrypt(ref Data);
if (Data[0] == 0x1c && Data[1] == 0x00 && Data[2] == 0x1c && Data[3] == 0x04)
{
ulong Keys = Data[11];
Keys = (Keys << 8) | Data[10];
Keys = (Keys << 8) | Data[9];
Keys = (Keys << 8) | Data[8];
Keys = (Keys << 8) | Data[7];
Keys = (Keys << 8) | Data[6];
Keys = (Keys << 8) | Data[5];
Keys = (Keys << 8) | Data[4];
AuthBinder AB2 = (AuthBinder)KeyClients[Keys];
KeyClients.Remove(Keys);
Client ThisClient = AB2.Client;
Socket.Wrapper = ThisClient;
string Account = AB2.Acc;
ThisClient.Crypto = TempCrypto;
ThisClient.Crypto.SetKeys(new byte[4] { Data[11], Data[10], Data[9], Data[8] }, new byte[4] { Data[7], Data[6], Data[5], Data[4] });
ThisClient.Crypto.EnableAlternateKeys();
ThisClient.MessageId = Rand.Next(50000);
ThisClient.ListenSock = Socket;
ThisClient.GetIPE();
if (AB2.Auth == 1)
{
ThisClient.MyChar = new Character();
ThisClient.MyChar.MyClient = ThisClient;
ThisClient.Account = Account;
DataBase.GetCharInfo(ThisClient.MyChar, Account);
ThisClient.SendPacket(MyPackets.LanguageResponse((uint)ThisClient.MessageId));
ThisClient.SendPacket(MyPackets.CharacterInfo(ThisClient.MyChar));
ThisClient.SendPacket(MyPackets.AfterChar());
ConnectedPlayers++;
if (!World.AllChars.Contains(ThisClient.MyChar.UID))
{
World.AllChars.Add(ThisClient.MyChar.UID, ThisClient.MyChar);
}
else
{
ThisClient.MyChar = null;
ThisClient = null;
return;
}
DataBase.ChangeOnlineStatus(ThisClient.Account, 1);
}
else if (AB2.Auth == 2)
{
ThisClient.SendPacket(MyPackets.NewCharPacket(ThisClient.MessageId));
}
else
{
ThisClient.Drop();
}
}
}
}
else
return;
}
catch (Exception Exc) { WriteLine(Exc.ToString()); }
}
and oh, u have to add "byte ConnectedPlayers = 0;" in general.cs, after
Code:
public static System.IO.StreamWriter sw = new System.IO.StreamWriter(Application.StartupPath + @"\ServerLog.txt", true);
and voila , max players added
|
|
|
Similar Threads
|
How to dc other players
09/24/2009 - CO2 Exploits, Hacks & Tools - 5 Replies
type this -----> \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n (for at least 4 rows of whisper chat box) hit enter so you and that person will dc. Make sure you use forward slash and not backslash.. Use copy and paste to do it faster(noob tip)
|
DEX Players
04/22/2009 - Lineage 2 - 1 Replies
Hi, any DEX player that knows something nice t use there?
TKS ;)
|
HI to ALL players of RFO PH
10/05/2008 - Say Hello - 0 Replies
can someone teach me now tricks in RFO PH?
|
All times are GMT +1. The time now is 01:17.
|
|