Jump to content

Bravery Cape Range issues


Recommended Posts

Heyo,

glad to have you here. wanna change the range of my bravery cape but if i change the approx range in char_battle.cpp nothing changes.

struct FuncAggregateMonster
 {
	LPCHARACTER m_ch;
	FuncAggregateMonster(LPCHARACTER ch)
	{
		m_ch = ch;
	}
	void operator()(LPENTITY ent)
	{
		if (ent->IsType(ENTITY_CHARACTER))
		{
			LPCHARACTER ch = (LPCHARACTER) ent;
			if (ch->IsPC())
				return;
			if (!ch->IsMonster())
				return;
			if (ch->GetVictim())
				return;

			if (number(1, 100) <= 100) // Àӽ÷Π50% È®·ü·Î ÀûÀ» ²ø¾î¿Â´Ù
				if (DISTANCE_APPROX(ch->GetX() - m_ch->GetX(), ch->GetY() - m_ch->GetY()) < 10000)
					if (ch->CanBeginFight())
						ch->BeginFight(m_ch);
		}
	}
};

i tried so many values, but there is zero difference.

do i have to change something else?

Thanks for reading!

Link to comment
Share on other sites

in char_state.cpp

Find:

if (fDist >= 4000.0f)
{

	SetVictim(NULL);

	if (pkChrProtege)
		if (DISTANCE_APPROX(GetX() - pkChrProtege->GetX(), GetY() - pkChrProtege->GetY()) > 1000)
			Follow(pkChrProtege, number(150, 400));

	return;

}



and just change fDist to your desired value. So in your case 10.000.

Edited by Baltazar
  • Good 1
Link to comment
Share on other sites

1 hour ago, Baltazar said:

in char_state.cpp

Find:

if (fDist >= 4000.0f)
{

	SetVictim(NULL);

	if (pkChrProtege)
		if (DISTANCE_APPROX(GetX() - pkChrProtege->GetX(), GetY() - pkChrProtege->GetY()) > 1000)
			Follow(pkChrProtege, number(150, 400));

	return;

}



and just change fDist to your desired value. So in your case 10.000.

Works perfect, thanks!

Btw. i dunno if i need to open a new thread for it, but i also added the "PullMonster" function on the bravery effect itself so the mobs are directly get pulled into me.. but the mobs gets pushed arround into 3 seperate bulks. 2 questions on it. first: is it possible that the mobs get pulled directly into the character? second: can i add the "PullMonster" function as skill attribute? example: i use dragon swirl and want that all mobs in x range get pulled.

greetings

Link to comment
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now

Announcements



×
×
  • Create New...

Important Information

Terms of Use / Privacy Policy / Guidelines / We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.