Jump to content

Recommended Posts

Hei everybody. I try to disable the polymorph in PVP. 

 

I make this in char_battle.cpp:

Spoiler

 

if (IsPolymorphed() == true && IsPC())

   RemoveAffect(AFFECT_POLYMORPH);

   ChatPacket(CHAT_TYPE_INFO, "Transformarea in modul PVP este interzisa!");

 

 

 

But this is work for all atack :)) (monster/player) So now if i atack a monster/player the polymorph effect are remove :)), i want only to players

Link to comment
https://metin2.dev/topic/15267-help-simple-function-in-c/
Share on other sites

11 minutes ago, Tasho said:

if (IsPC() && IsPolymorphed() && pkVictim->IsPC())

 

Thx you for reply , already test this , is working but if i kill a mob (don`t remove the polymorph) but i receive in chat the message: " Transformarea in modul PVP este interzisa! " and i dont understand why :)))

Link to comment
https://metin2.dev/topic/15267-help-simple-function-in-c/#findComment-85848
Share on other sites

Is same code.

//char_skill.cpp
bool CHARACTER::UseSkill(DWORD dwVnum, LPCHARACTER pkVictim, bool bUseGrandMaster)
{
	if (IsPC() && IsPolymorphed() && pkVictim->IsPC())
	{
		RemoveAffect(AFFECT_POLYMORPH);
		ChatPacket(CHAT_TYPE_INFO, "Transformarea in modul PVP este interzisa!");
	}

	[..........................................]
}
  • Love 1
Link to comment
https://metin2.dev/topic/15267-help-simple-function-in-c/#findComment-85863
Share on other sites

Don't use any images from : imgur, turkmmop, freakgamers, inforge, hizliresim... Or your content will be deleted without notice...
Use : https://metin2.download/media/add/

Please use https://metin2.download/ when uploading files smaller than 100MB, otherwise the approval will take longer due to manual upload.

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
×
×
  • 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.