• This is a read only backup of the old Emudevs forum. If you want to have anything removed, please message me on Discord: KittyKaev

How to enable "Your In Combat"

Status
Not open for further replies.

OMGhixD

Sexy Member
Code:
		if (player->IsInCombat())
		 {
			player->PlayerTalkClass->SendCloseGossip();
			creature->MonsterSay("You are in combat!", LANG_UNIVERSAL, NULL);
			 return true;
		}

Where would i exactly place this? i'll try myself tho. But i want it kinda confirmed aswell :3
 

frost

Banned
I thought this is c++ dont use what i said. you want lua example srry
 
Last edited:
yah because using send msg to player , if you want to make creature say use : creature:SendUnitSay("You're in combat.",0)
 

OMGhixD

Sexy Member
yah because using send msg to player , if you want to make creature say use : creature:SendUnitSay("You're in combat.",0)

Well i want it to say that ofcourse, but i also want it to DENY any kind of service, or menu opening during the time the player is in combat :)
 

slp13at420

Mad Scientist
I did not test this just mod'd it from the hip. I just moved the if/else from the OnGossipSelect to the OnGossipHello function so it should check if the player is in combat first when they click the npc . if they are in combat then it will respond 'you are in combat' . if player is not in combat then the gossip window should open.



--tested-- perfection
 
Last edited:
Status
Not open for further replies.
Top