Register for your free account! | Forgot your password?

You last visited: Today at 21:17

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


Open cap after Teleport

Reply
 
Old   #1
 
elite*gold: 0
Join Date: May 2007
Posts: 275
Received Thanks: 20
Open cap after Teleport

any idea about how to make char wear pvp cap after teleport to map
like survival at electus ?



kotsh is offline  
Old 12/09/2018, 17:52   #2
 
elite*gold: 0
Join Date: Apr 2017
Posts: 514
Received Thanks: 133
based on the packet filter


Zoro.Sro is offline  
Old 12/10/2018, 11:31   #3


 
elite*gold: 778
Join Date: Apr 2011
Posts: 326
Received Thanks: 66
The Packet if you start the process of joining a pvp team is this one:
Code:
[C->S] [1] [0x7516] 
05
The Packet is 7516
and for example the 05 is the color of the Team.
In my example is 05 the team yellow.
So after the teleport you have to send the packet 7516 with the 05 to the Server.

I did it a few days ago.


If you need any help feel free to ask me
putzeimer195 is offline  
Old 12/11/2018, 09:02   #4
 
elite*gold: 950
Join Date: Aug 2015
Posts: 1,720
Received Thanks: 958
^

if u need help pm me


B1Q is offline  
Old 12/12/2018, 14:00   #5
 
elite*gold: 0
Join Date: Sep 2017
Posts: 439
Received Thanks: 102
It's very simple as an idea and it wouldn't take much time to implement.

This is with a packet filter.

You're gonna work at 0x3012 | AGENT_CLIENT_GAME_READY after specifying character region from database or 0x3013 | AGENT_SERVER_ENTITY_SPAWN, you're gonna prevent the character from doing anything that would cancel the cape like using (pvp cape options,movement,exchange,pick,stall,wearing a job suit...etc), some of them might be already blocked with wearing the cape in usual, but taking precautions... Then start wearing the pvp cape using 0x7516 | AGENT_FRPVP_UPDATE with the pvp cape color flag and after the cape is worn, allow him some stuff, like walking.. picking, whatever you want.

OFC, you're gonna need some flags at your packets to prevent them from doing stuff like exchange, you're gonna have to do something like this at your exchange packet section:
Code:
if (this.BlockExchange)
{
  this.SendNotice("You are not allowed to use exchange.");
  this.continue;
}
And to implement this you can basically do something like this at your 0x3012 | AGENT_CLIENT_GAME_READY section:
Code:
if (this.CurrentRegion == myspecificregion)
	{
	  PrepareWearingCape(true);
	}
else
	{
	  PrepareWearingCape(false);
	}
While you're having these functions:
Code:
public async void PrepareWearingCape(bool dojobflag)
	{
	  this.BlockMovement = dojobflag;
	  this.BlockPvPCape = dojobflag;
	  this.BlockExchange = dojobflag;
	  this.BlockStall = dojobflag;
	  this.BlockPick = dojobflag;
	  this.BlockInventoryControl = dojobflag;
	  if (dojobflag)
	  {
	    this.OpenCape("Yellow");
	    await Task.Delay(10500); // cape takes 10 seconds to finish, so we're gonna wait 10.5 seconds. We can do it with receiving the server packet but this easier.
	    this.BlockMovement = false;
	    this.BlockPick = false;
	  }
	}

public void OpenCape(string color)
        {
	   try
	   {
            int capeindex = 0;
            switch (color)
            {
                case "Red":
                    capeindex = 1;
                    break;
                case "Black":
                    capeindex = 2;
                    break;
                case "Blue":
                    capeindex = 3;
                    break;
                case "White":
                    capeindex = 4;
                    break;
                case "Yellow":
                    capeindex = 5;
                    break;
            }

		Packet cape = new Packet(0x7516, true);
                cape.WriteUInt8(capeindex);
                this.LocalSecuirity.Send(cape);
		this.SendToHost(true);
	       }
	    catch { }
	}
#HB is offline  
Old Yesterday, 06:09   #6
 
elite*gold: 950
Join Date: Aug 2015
Posts: 1,720
Received Thanks: 958
Quote:
Originally Posted by #HB View Post
Code:
if (this.BlockExchange)
{
  this.SendNotice("You are not allowed to use exchange.");
  this.continue;
}
And to implement this you can basically do something like this at your 0x3012 | AGENT_CLIENT_GAME_READY section:
Code:
if (this.CurrentRegion == myspecificregion)
	{
	  PrepareWearingCape(true);
	}
else
	{
	  PrepareWearingCape(false);
	}
While you're having these functions:
Code:
public async void PrepareWearingCape(bool dojobflag)
	{
	  this.BlockMovement = dojobflag;
	  this.BlockPvPCape = dojobflag;
	  this.BlockExchange = dojobflag;
	  this.BlockStall = dojobflag;
	  this.BlockPick = dojobflag;
	  this.BlockInventoryControl = dojobflag;
	  if (dojobflag)
	  {
	    this.OpenCape("Yellow");
	    [highlight]await Task.Delay(10500);[/highlight] // cape takes 10 seconds to finish, so we're gonna wait 10.5 seconds. We can do it with receiving the server packet but this easier.
	    this.BlockMovement = false;
	    this.BlockPick = false;
	  }
	}

public void OpenCape(string color)
        {
	   try
	   {
            int capeindex = 0;
            switch (color)
            {
                case "Red":
                    capeindex = 1;
                    break;
                case "Black":
                    capeindex = 2;
                    break;
                case "Blue":
                    capeindex = 3;
                    break;
                case "White":
                    capeindex = 4;
                    break;
                case "Yellow":
                    capeindex = 5;
                    break;
            }

		Packet cape = new Packet(0x7516, true);
                cape.WriteUInt8(capeindex);
                this.LocalSecuirity.Send(cape);
		this.SendToHost(true);
	       }
	    catch { }
	}
this is really bad
pls don't use await

instead wait for server response (which is more reliable, in this case anything could go wrong and player could be standing still without the cape for the next 10 seconds then they will start moving)
the response packet is B516
Code:
 if (pck.ReadByte() == 1)
            {               
                bool isuid = pck.ReadUInt() == client.Character.UniqueID;
                byte cape = pck.ReadByte(); 
                if (isuid)
                {
                    if (cape > 0)
                    {
                        client.Character.PVPCapeNum = cape;
                        client.Character.PVPOn = true;
                        client.Character.CanMove = true;
                    }
                    else 
                    {
                        client.Character.PVPCapeNum = 0;
                        client.Character.PVPOn = false;
                        if (AutoCapeRegions.Contains(client.Character.Region))                       
                            client.Character.CanMove = false;
                    }
                }
            }


B1Q is offline  
Reply



« Donwload on official Site not working - Any Solution? | - »

Similar Threads
KBot_5.62_setup.exe ' Open Open Open '
12/18/2011 - DarkOrbit - 5 Replies
KBot_5.62_setup.exe LİNK : http://www.kbotik.com/files/mo_IMG_3.jpg SCAN : http://www.metascan-online.com/img/metascanonline-logo.png
[tut] speed teleport (not map teleport)
08/11/2009 - 12Sky2 - 2 Replies
you need cheat eng for this find the movement speed address current: C61778 2. change to 99999 3. enable your run skill your done you will go so fast you will teleport make sure you don't click in anything bad shit will happen thank me :mofo: :mofo: :mofo:



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


Powered by vBulletin®
Copyright ©2000 - 2018, Jelsoft Enterprises Ltd.
SEO by vBSEO ©2011, Crawlability, Inc.

Support | Contact Us | FAQ | Advertising | Privacy Policy | Abuse
Copyright ©2018 elitepvpers All Rights Reserved.