Register for your free account! | Forgot your password?

Go Back   elitepvpers > Other Online Games > Browsergames > DarkOrbit
You last visited: Today at 21:25

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

Advertisement



Your own CLI Commands in Azure (Private Server)

Discussion on Your own CLI Commands in Azure (Private Server) within the DarkOrbit forum part of the Browsergames category.

Reply
 
Old   #1


 
Requi's Avatar
 
elite*gold: 3570
The Black Market: 244/0/0
Join Date: Dec 2012
Posts: 13,044
Received Thanks: 8,252
Your own CLI Commands in Azure (Private Server)

Welcome to a little tutorial, how to add your own CLI Commands in Azure or another private server.
Let' start.

If you write something in to the CLI, the client send this to the server.
Not as a stupid
Code:
A|0|BRB...
Packet

So if you write as example "ship 98", you need to check, if the packetHeader Contains ship. As every packet

Code:
if (packetHeader.StartsWith("ship"))
Then you need to get the ID of the ship. Xdr implented a nice function into the packets.cs
You can easily read types.
So:
Code:
if (packetHeader.StartsWith("ship"))
{
this.Ship.ID = packetHeader.ReadUInt32();
}
As the packets.cs only split at a |, you actually need to write a split function for the " " (Space).

Open the packets.cs and edit one of the first lines, where the | get splitted.
Code:
if (packet.Contains("|"))
{
packetData = packet.Split('|');
}
else //for the spacebar
{
packetData = packet.Split(' ');
}
So, if you write now at the CLI: "ship 98", you need the relog and you have the ship.

But you don't want to relog?
Send the RDY packet again.

Code:
private void updateShip()
{
INSERT HERE THE RDY PACKET FROM START
}
And at the end, we have at the packetReader in the Users.cs this code at the end for one simply CLI Command:
Code:
if (packetHeader.StartsWith("ship"))
{
this.Ship.ID = packetHeader.ReadUInt32();
this.updateShip();
}
Regards,
Requi
Requi is offline  
Thanks
14 Users
Old 08/02/2013, 02:10   #2
 
elite*gold: 73
Join Date: May 2012
Posts: 517
Received Thanks: 548
Nice tutorial xD,

I got it before everyone else .

Thanks for this useful thread.
DrSkyfall™ is offline  
Thanks
1 User
Old 08/02/2013, 02:20   #3
 
Peshо's Avatar
 
elite*gold: 0
The Black Market: 387/2/0
Join Date: Sep 2012
Posts: 8,002
Received Thanks: 3,863
Nice one, but why don't you put all tutorials into 1 thread?
Peshо is offline  
Old 08/02/2013, 08:51   #4
 
KratonVsPande's Avatar
 
elite*gold: 35
Join Date: Jul 2013
Posts: 266
Received Thanks: 221
nice requi is not that hard to understand even for a beginner like me :P thx ^_^
KratonVsPande is offline  
Old 08/02/2013, 09:15   #5
 
arvatadryan's Avatar
 
elite*gold: 9
Join Date: Sep 2010
Posts: 433
Received Thanks: 199
Nice tutorial
arvatadryan is offline  
Old 08/02/2013, 13:31   #6
 
Sήøwy's Avatar
 
elite*gold: 1
Join Date: Aug 2010
Posts: 1,330
Received Thanks: 1,724
Again guys you feed the noobs
Sήøwy is offline  
Old 08/02/2013, 15:17   #7
 
»Barney«'s Avatar
 
elite*gold: 0
Join Date: May 2012
Posts: 868
Received Thanks: 947
Quote:
Originally Posted by asd26 View Post
Again guys you feed the noobs
Someone has to help them, we need programmers here in epvp to make DO better
»Barney« is offline  
Old 08/02/2013, 17:29   #8
 
Sήøwy's Avatar
 
elite*gold: 1
Join Date: Aug 2010
Posts: 1,330
Received Thanks: 1,724
I'm happy to hear that haha...yeah..but i don't care anymore about darkorbit too many idiots at support.
Sήøwy is offline  
Old 08/03/2013, 17:42   #9


 
Requi's Avatar
 
elite*gold: 3570
The Black Market: 244/0/0
Join Date: Dec 2012
Posts: 13,044
Received Thanks: 8,252
If you have any suggestions for tutorials, just tell me.
Requi is offline  
Old 12/31/2014, 04:23   #10
 
elite*gold: 0
Join Date: Sep 2013
Posts: 134
Received Thanks: 7
i need my tchat system on
MS-Colder is offline  
Reply




All times are GMT +1. The time now is 21:25.


Powered by vBulletin®
Copyright ©2000 - 2025, 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 ©2025 elitepvpers All Rights Reserved.