Jump to content

Emotion use notification


Recommended Posts

  • Active Member

Hello guys,

is here someone who know how can I do things below?

First thing:

I want to use this for notify myself to see for which player I allowed use of emotions with me:

ch->ChatPacket(CHAT_TYPE_INFO, LC_TEXT("Interactive emotions from %s was successfully allowed."), victim->GetName());

This ChatPacket above must be shown only one time when player click on allow emotions button until he will be teleported or logged out. (Until the allow function isn't destroyed.)

If the victim (player for which I allowed use of emotions with me) allow use of emotions for me too I must recieve chat packet like:

ch->ChatPacket(CHAT_TYPE_INFO, LC_TEXT("%s allowed use of interactive emotions for you."), victim->GetName());

This ChatPacket above must be shown only one time when the victim (player for which I allowed use of emotions with me) allow use of emotions for me too by clicking on allow emotions button.

And the second thing is:

To victim must be sent a whisper message that will notify victim when player click on allow emotions button (player is who want to use emotions with the victim) to use emotions with the victim.

This whisper message must be sent only to a victim with which we want to share emotions if victim click on allow emotions button too, the player which requested allow of emotions first won't recieve this whisper message like victim.

So victim will recieve whisper message like:

If someone have a some time and can help me with this, I will be really glad! :)

Thanks for answers!

Sincerely,

ReFresh

Edited by ReFresh

I'll be always helpful! 👊 

Link to comment
Share on other sites

  • Replies 6
  • Created
  • Last Reply

Top Posters In This Topic

  • Active Member

@Chyu ^^ Yeah, I could be inspired by duel functions but here are some things which I don't know.

For example I added the notice phrase to cmd_emotion.cpp file at ACMD(do_emotion_allow) function:

	char arg2[256];
	one_argument(argument, arg2, sizeof(arg2));

	DWORD vid = 0;
	str_to_number(vid, arg2);
	LPCHARACTER pkVictim = CHARACTER_MANAGER::instance().Find(vid);
	
	ch->ChatPacket(CHAT_TYPE_INFO, LC_TEXT("Interactive emotions from %s was successfully allowed"), pkVictim->GetName());

It works fine, but the ChatPacket is shown every time when I click on allow emotions button. This should be shown only once and I have no idea how to do it.

I'll be always helpful! 👊 

Link to comment
Share on other sites

  • 2 weeks later...

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.