Jump to content
Maintenance : Final step ×

[Fix] GM Character's Effect Fix After /inv Command


blaxis

Recommended Posts

  • Active+ Member

You all know the famous problem that comes up from time to time.

Let me explain it briefly for those who don't know; After being invisible with the /inv command and becoming visible again, the effects of the GM character are not visible. The ENABLE_CANSEEHIDDENTHING_FOR_GM macro edit found in the Martysama files is an edit that is only valid for your screen. In other words, the effects continue to be invisible for other players.

I didn't care about this problem until now, but since I had to solve this problem in order to make some edits. I took a look at the codes a little and discovered a very small, harmless manipulation method to solve this problem. And as a result, I wanted to solve the problem and share it with you.

The only edit you need to make is as follows.

Open the InstanceBaseEffect.cpp file and edit it as I showed:

This is the hidden content, please

That's all. You can watch the proof video below.

This is the hidden content, please

 

Edited by blaxis
  • Metin2 Dev 51
  • Good 4
  • Love 19
Link to comment
Share on other sites

  • Active+ Member
2 hours ago, MysteriousDev said:

There is still issue with insert packet - cheaters can see if you're there. Also /observer is broken on warp, cause it sends insert packet before the observer mode is turned on (which trigger is sent by client).

The only thing I'm talking about here is that the GM character's effects disappear when you come out of stealth mode. (visual bug)

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

  • Premium
2 hours ago, blaxis said:

The only thing I'm talking about here is that the GM character's effects disappear when you come out of stealth mode. (visual bug)

Nothing wrong with the fix. Just saying about another bug (or should I say bad design) which is somehow related to the /inv command.

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

  • 2 weeks later...
On 11/23/2024 at 5:50 PM, blaxis said:

You all know the famous problem that comes up from time to time.

Let me explain it briefly for those who don't know; After being invisible with the /inv command and becoming visible again, the effects of the GM character are not visible. The ENABLE_CANSEEHIDDENTHING_FOR_GM macro edit found in the Martysama files is an edit that is only valid for your screen. In other words, the effects continue to be invisible for other players.

I didn't care about this problem until now, but since I had to solve this problem in order to make some edits. I took a look at the codes a little and discovered a very small, harmless manipulation method to solve this problem. And as a result, I wanted to solve the problem and share it with you.

The only edit you need to make is as follows.

Open the InstanceBaseEffect.cpp file and edit it as I showed:

Hidden Content

 

		case AFFECT_INVISIBILITY:
#ifdef ENABLE_CANSEEHIDDENTHING_FOR_GM // You may not have this. We have nothing to do with it.
			if (__MainCanSeeHiddenThing())
			{
				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);
				if (IsGameMaster() && !__IsMainInstance()) // Add!!
				{
					ChangeArmor(0);
				}
				else
				{
					// enclose these two in an "else" block.
					AttachTextTail();
					RefreshTextTail();
				}
					
			}

Note: Some of you may think that there is no need to use the "__IsMainInstance()" condition when the "IsGameMaster()" condition is present, but do not remove it. It is very important.

 

 

That's all. You can watch the proof video below.

This is the hidden content, please

 

When I disable invisibility the character will see me without armor

Link to comment
Share on other sites

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