Jump to content

Pathfind broken for Dungeon profile


Ivkan1997

Recommended Posts

As title said...

 

I have well scripted dungeon profile and my character wont die by itself, but when internet lag happens or server crush, my character is dead and he cant find path to instance where corpse is. He is going strainght into obstacles etc...

Is there any way to make some task(followpath) to make character follow it "ONLY IF DEAD" so there would be no problem...

Link to comment
Share on other sites

  • 2 weeks later...

Many times I asked this question, including the Droidz. But no one answered the options to fix it. In theory, you need to write a plugin that will turn off the standard algorithm of running to the corpse after death and activate a script that will make it run to the entrance to the dungeon.

But I did not read the documentation and I do not know if there is a technical possibility to implement it using the plug-in. It would be much easier to add in the bot one tick for the quest bot that sounds like "it's a dungeon". Which will disable the standard algorithm and then the resurrection will only be managed by your profile. Then it's already a few simple conditions and it's done

Link to comment
Share on other sites

Would this not work?

Also this was some ugly code I worked on only once and never touched again. If I remember correctly, it doesnt work but is an easy fix.

public void Resurrect()
	{
		while (ObjectManager.Me.IsDead)
		{
			if (!ObjectManager.Me.HaveBuff(8326))
			{
				Lua.LuaDoString("RepopMe();");
				Thread.Sleep(2500);
			}
			else if (ObjectManager.Me.PositionCorpse.DistanceTo(ObjectManager.Me.Position) > 10)
			{
				wManager.Wow.Bot.Tasks.GoToTask.ToPosition(ObjectManager.Me.PositionCorpse);
				Thread.Sleep(2500);
			}
			else
			{
				if (ObjectManager.Me.GetCorpseRecoveryDelay() > 0)
				{
					Thread.Sleep(ObjectManager.Me.GetCorpseRecoveryDelay() * 1000 + 1000);
				}
				else
				{
					Lua.LuaDoString("RetrieveCorpse();");
				}
			}	
		}
	}

 

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...