Jump to content

[C++ client] GM Eye of Sauron


tierrilopes

Recommended Posts

Permite aos GMs ver personagens invisíveis. :VoteYea:

Útil para detectar ghost mode hack. :Keepo:

 

Ir até ao ficheiro UserInterface/InstanceBase.cpp:

Procurar por:

BOOL CInstanceBase::IsMovieMode()

Editar para:

BOOL CInstanceBase::IsMovieMode()
{
#ifdef ENABLE_GM_EYEOFSAURON
	if (IsAffect(AFFECT_INVISIBILITY) && !__GMCanSeeEverything())
		return true;
#else
	if (IsAffect(AFFECT_INVISIBILITY))
		return true;
#endif

	return false;
}

 

Procurar por:

BOOL CInstanceBase::IsInvisibility()

Editar para:

BOOL CInstanceBase::IsInvisibility()
{
#ifdef ENABLE_GM_EYEOFSAURON
	if (IsAffect(AFFECT_INVISIBILITY) && !__GMCanSeeEverything())
		return true;
#else
	if (IsAffect(AFFECT_INVISIBILITY))
		return true;
#endif

	return false;
}

 

Procurar por:

bool CInstanceBase::__IsExistMainInstance()
{
	if(__GetMainInstancePtr())
		return true;
	else
		return false;
}

 

Adicionar debaixo:

bool CInstanceBase::__GMCanSeeEverything()
{
#ifdef ENABLE_GM_EYEOFSAURON
	CInstanceBase * pInstance = __GetMainInstancePtr();
	return (pInstance) ? TRUE == pInstance->IsGameMaster() : false;
#else
	return false;
#endif
}

Procurar por:

bool CInstanceBase::Create(const SCreateData& c_rkCreateData)

No final da função, procurar por:

	const int c_iGuildSymbolRace = 14200;
	if (c_iGuildSymbolRace == GetRace())
	{
		std::string strFileName = GetGuildSymbolFileName(m_dwGuildID);
		if (IsFile(strFileName.c_str()))
			m_GraphicThingInstance.ChangeMaterial(strFileName.c_str());
	}

	return true;
}

Editar para:

	const int c_iGuildSymbolRace = 14200;
	if (c_iGuildSymbolRace == GetRace())
	{
		std::string strFileName = GetGuildSymbolFileName(m_dwGuildID);
		if (IsFile(strFileName.c_str()))
			m_GraphicThingInstance.ChangeMaterial(strFileName.c_str());
	}

#ifdef ENABLE_GM_EYEOFSAURON
	if (IsAffect(AFFECT_INVISIBILITY) && __GMCanSeeEverything())
		m_GraphicThingInstance.BlendAlphaValue(0.5f, 0.5f);
#endif

	return true;
}

 

Procurar por:

bool CInstanceBase::CanPickInstance()

Editar para:

bool CInstanceBase::CanPickInstance()
{
	if (!__IsInViewFrustum())
		return false;

	if (IsDoor())
	{
		if (IsDead())
			return false;
	}

	if (IsPC())
	{
		if (IsAffect(AFFECT_EUNHYEONG))
		{
			if (!__GMCanSeeEverything())
				return false;
		}
#ifdef ENABLE_GM_EYEOFSAURON
		if (IsAffect(AFFECT_REVIVE_INVISIBILITY) && !__GMCanSeeEverything())
			return false;
#else
		if (IsAffect(AFFECT_REVIVE_INVISIBILITY))
			return false;
#endif
#ifdef ENABLE_GM_EYEOFSAURON
		if (IsAffect(AFFECT_INVISIBILITY) && !__GMCanSeeEverything())
			return false;
#else
		if (IsAffect(AFFECT_INVISIBILITY))
			return false;
#endif

	}

	if (IsDead())
		return false;

	return true;
}

Procurar por:

bool CInstanceBase::__CanRender()

Editar para:

bool CInstanceBase::__CanRender()
{
	if (!__IsInViewFrustum())
		return false;

#ifdef ENABLE_GM_EYEOFSAURON
	if (IsAffect(AFFECT_INVISIBILITY) && !__GMCanSeeEverything())
		return false;
#else
	if (IsAffect(AFFECT_INVISIBILITY))
		return false;
#endif

	return true;
}

 

Ir até ao ficheiro UserInterface/InstanceBaseEffect.cpp:

Procurar por:

void CInstanceBase::__Assassin_SetEunhyeongAffect(bool isVisible)

Editar para:

void CInstanceBase::__Assassin_SetEunhyeongAffect(bool isVisible)
{
	if (isVisible)
	{
		if (IsWearingDress())
			return;

		if (__IsMainInstance() || __GMCanSeeEverything())
		{
			m_GraphicThingInstance.BlendAlphaValue(0.5f, 1.0f);
		}
		else
		{
			m_GraphicThingInstance.BlendAlphaValue(0.0f, 1.0f);
			m_GraphicThingInstance.HideAllAttachingEffect();
		}
	}
	else
	{
#ifdef ENABLE_GM_EYEOFSAURON
		if (IsAffect(AFFECT_INVISIBILITY) && __GMCanSeeEverything())
			return;
#endif
		m_GraphicThingInstance.BlendAlphaValue(1.0f, 1.0f);
		m_GraphicThingInstance.ShowAllAttachingEffect();
	}
}

Na função:

void CInstanceBase::__SetAffect(UINT eAffect, bool isVisible)

Procurar por:

	switch (eAffect)
	{
		case AFFECT_YMIR:
			if (IsAffect(AFFECT_INVISIBILITY))
				return;
			break;

Editar para:

	switch (eAffect)
	{
		case AFFECT_YMIR:
#ifdef ENABLE_GM_EYEOFSAURON
			if (IsAffect(AFFECT_INVISIBILITY) && !__GMCanSeeEverything())
				return;
#else
			if (IsAffect(AFFECT_INVISIBILITY))
				return;
#endif
			break;

Procurar por:

		case AFFECT_INVISIBILITY:
			if (isVisible)
			{
				m_GraphicThingInstance.ClearAttachingEffect();
				__EffectContainer_Destroy();
				DetachTextTail();
			}
			else
			{
				m_GraphicThingInstance.BlendAlphaValue(1.0f, 1.0f);
				AttachTextTail();
				RefreshTextTail();
			}
			return;
			break;

Editar para:

		case AFFECT_INVISIBILITY:
#ifdef ENABLE_GM_EYEOFSAURON
			if (__GMCanSeeEverything())
			{
				if (isVisible)
					m_GraphicThingInstance.BlendAlphaValue(0.5f, 1.0f);
				else
					m_GraphicThingInstance.BlendAlphaValue(1.0f, 1.0f);
				break;
			}
#endif
			if (isVisible)
			{
				m_GraphicThingInstance.ClearAttachingEffect();
				__EffectContainer_Destroy();
				DetachTextTail();
			}
			else
			{
				m_GraphicThingInstance.BlendAlphaValue(1.0f, 1.0f);
				AttachTextTail();
				RefreshTextTail();
			}
			return;
			break;

Na função:

DWORD CInstanceBase::__AttachEffect(UINT eEftType)

Procurar por:

	if (IsAffect(AFFECT_INVISIBILITY))
		return 0;

Editar para:

#ifdef ENABLE_GM_EYEOFSAURON
	if (IsAffect(AFFECT_INVISIBILITY) && !__GMCanSeeEverything())
		return 0;
#else
	if (IsAffect(AFFECT_INVISIBILITY))
		return 0;
#endif

Ir até ao ficheiro UserInterface/InstanceBase.h

Procurar por:

bool __IsMainInstance();

Adicionar debaixo:

bool __GMCanSeeEverything();

Ir até ao ficheiro UserInterface/Locale_inc.h

Procurar por:

#define ENABLE_DRAGON_SOUL_SYSTEM

Adicionar debaixo:

#define ENABLE_GM_EYEOFSAURON

 

Compilar:KappaRoss:

 

Cumprimentos,

Tierri Lopes:HeyGuys:

  • Thanks 1
Link to comment
Share on other sites

18 horas atrás, Tierri Lopes disse:

Permite aos GMs ver personagens invisíveis. :VoteYea:

Útil para detectar ghost mode hack. :Keepo:

 

Ir até ao ficheiro UserInterface/InstanceBase.cpp:

Procurar por:


BOOL CInstanceBase::IsMovieMode()

Editar para:


BOOL CInstanceBase::IsMovieMode()
{
#ifdef ENABLE_GM_EYEOFSAURON
	if (IsAffect(AFFECT_INVISIBILITY) && !__GMCanSeeEverything())
		return true;
#else
	if (IsAffect(AFFECT_INVISIBILITY))
		return true;
#endif

	return false;
}

 

Procurar por:


BOOL CInstanceBase::IsInvisibility()

Editar para:


BOOL CInstanceBase::IsInvisibility()
{
#ifdef ENABLE_GM_EYEOFSAURON
	if (IsAffect(AFFECT_INVISIBILITY) && !__GMCanSeeEverything())
		return true;
#else
	if (IsAffect(AFFECT_INVISIBILITY))
		return true;
#endif

	return false;
}

 

Procurar por:


bool CInstanceBase::__IsExistMainInstance()
{
	if(__GetMainInstancePtr())
		return true;
	else
		return false;
}

 

Adicionar debaixo:


bool CInstanceBase::__GMCanSeeEverything()
{
#ifdef ENABLE_GM_EYEOFSAURON
	CInstanceBase * pInstance = __GetMainInstancePtr();
	return (pInstance) ? TRUE == pInstance->IsGameMaster() : false;
#else
	return false;
#endif
}

Procurar por:


bool CInstanceBase::Create(const SCreateData& c_rkCreateData)

No final da função, procurar por:


	const int c_iGuildSymbolRace = 14200;
	if (c_iGuildSymbolRace == GetRace())
	{
		std::string strFileName = GetGuildSymbolFileName(m_dwGuildID);
		if (IsFile(strFileName.c_str()))
			m_GraphicThingInstance.ChangeMaterial(strFileName.c_str());
	}

	return true;
}

Editar para:


	const int c_iGuildSymbolRace = 14200;
	if (c_iGuildSymbolRace == GetRace())
	{
		std::string strFileName = GetGuildSymbolFileName(m_dwGuildID);
		if (IsFile(strFileName.c_str()))
			m_GraphicThingInstance.ChangeMaterial(strFileName.c_str());
	}

#ifdef ENABLE_GM_EYEOFSAURON
	if (IsAffect(AFFECT_INVISIBILITY) && __GMCanSeeEverything())
		m_GraphicThingInstance.BlendAlphaValue(0.5f, 0.5f);
#endif

	return true;
}

 

Procurar por:


bool CInstanceBase::CanPickInstance()

Editar para:


bool CInstanceBase::CanPickInstance()
{
	if (!__IsInViewFrustum())
		return false;

	if (IsDoor())
	{
		if (IsDead())
			return false;
	}

	if (IsPC())
	{
		if (IsAffect(AFFECT_EUNHYEONG))
		{
			if (!__GMCanSeeEverything())
				return false;
		}
#ifdef ENABLE_GM_EYEOFSAURON
		if (IsAffect(AFFECT_REVIVE_INVISIBILITY) && !__GMCanSeeEverything())
			return false;
#else
		if (IsAffect(AFFECT_REVIVE_INVISIBILITY))
			return false;
#endif
#ifdef ENABLE_GM_EYEOFSAURON
		if (IsAffect(AFFECT_INVISIBILITY) && !__GMCanSeeEverything())
			return false;
#else
		if (IsAffect(AFFECT_INVISIBILITY))
			return false;
#endif

	}

	if (IsDead())
		return false;

	return true;
}

Procurar por:


bool CInstanceBase::__CanRender()

Editar para:


bool CInstanceBase::__CanRender()
{
	if (!__IsInViewFrustum())
		return false;

#ifdef ENABLE_GM_EYEOFSAURON
	if (IsAffect(AFFECT_INVISIBILITY) && !__GMCanSeeEverything())
		return false;
#else
	if (IsAffect(AFFECT_INVISIBILITY))
		return false;
#endif

	return true;
}

 

Ir até ao ficheiro UserInterface/InstanceBaseEffect.cpp:

Procurar por:


void CInstanceBase::__Assassin_SetEunhyeongAffect(bool isVisible)

Editar para:


void CInstanceBase::__Assassin_SetEunhyeongAffect(bool isVisible)
{
	if (isVisible)
	{
		if (IsWearingDress())
			return;

		if (__IsMainInstance() || __GMCanSeeEverything())
		{
			m_GraphicThingInstance.BlendAlphaValue(0.5f, 1.0f);
		}
		else
		{
			m_GraphicThingInstance.BlendAlphaValue(0.0f, 1.0f);
			m_GraphicThingInstance.HideAllAttachingEffect();
		}
	}
	else
	{
#ifdef ENABLE_GM_EYEOFSAURON
		if (IsAffect(AFFECT_INVISIBILITY) && __GMCanSeeEverything())
			return;
#endif
		m_GraphicThingInstance.BlendAlphaValue(1.0f, 1.0f);
		m_GraphicThingInstance.ShowAllAttachingEffect();
	}
}

Na função:


void CInstanceBase::__SetAffect(UINT eAffect, bool isVisible)

Procurar por:


	switch (eAffect)
	{
		case AFFECT_YMIR:
			if (IsAffect(AFFECT_INVISIBILITY))
				return;
			break;

Editar para:


	switch (eAffect)
	{
		case AFFECT_YMIR:
#ifdef ENABLE_GM_EYEOFSAURON
			if (IsAffect(AFFECT_INVISIBILITY) && !__GMCanSeeEverything())
				return;
#else
			if (IsAffect(AFFECT_INVISIBILITY))
				return;
#endif
			break;

Procurar por:


		case AFFECT_INVISIBILITY:
			if (isVisible)
			{
				m_GraphicThingInstance.ClearAttachingEffect();
				__EffectContainer_Destroy();
				DetachTextTail();
			}
			else
			{
				m_GraphicThingInstance.BlendAlphaValue(1.0f, 1.0f);
				AttachTextTail();
				RefreshTextTail();
			}
			return;
			break;

Editar para:


		case AFFECT_INVISIBILITY:
#ifdef ENABLE_GM_EYEOFSAURON
			if (__GMCanSeeEverything())
			{
				if (isVisible)
					m_GraphicThingInstance.BlendAlphaValue(0.5f, 1.0f);
				else
					m_GraphicThingInstance.BlendAlphaValue(1.0f, 1.0f);
				break;
			}
#endif
			if (isVisible)
			{
				m_GraphicThingInstance.ClearAttachingEffect();
				__EffectContainer_Destroy();
				DetachTextTail();
			}
			else
			{
				m_GraphicThingInstance.BlendAlphaValue(1.0f, 1.0f);
				AttachTextTail();
				RefreshTextTail();
			}
			return;
			break;

Na função:


DWORD CInstanceBase::__AttachEffect(UINT eEftType)

Procurar por:


	if (IsAffect(AFFECT_INVISIBILITY))
		return 0;

Editar para:


#ifdef ENABLE_GM_EYEOFSAURON
	if (IsAffect(AFFECT_INVISIBILITY) && !__GMCanSeeEverything())
		return 0;
#else
	if (IsAffect(AFFECT_INVISIBILITY))
		return 0;
#endif

 

Ir até ao ficheiro UserInterface/Locale_inc.h

Procurar por:


#define ENABLE_DRAGON_SOUL_SYSTEM

Adicionar debaixo:


#define ENABLE_GM_EYEOFSAURON

 

Compilar:KappaRoss:

 

Cumprimentos,

Tierri Lopes:HeyGuys:

Faltou-te identificar __GMCanSeeEverything em InstanceBase.h penso eu.
Cumprimentos

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...