• You've discovered RedGuides, an EverQuest multi-boxing and scripting community 🧙‍♀️⚙️. We want you to play several EQ characters at once, come join us and say hello! 👋

  • A TLP without truebox has thawed (Very Vanilla ready)
    Frostreaver

Simple Gift of Mana plugin

randomguy_01

Well-known member
Joined
Jul 13, 2005
RedCents
54¢
I wrote this cause I didn't want to use MQ2ChatEvents to avoid thinking hard and such.

This plugin will simply popup and echo a notification when the AA 'Gift of Mana' becomes active.

Usage:
Rich (BB code):
 /showgom (disables or enables the announcing of Gift of Mana procs)



Rich (BB code):
#include "../MQ2Plugin.h"


PreSetup("MQ2ShowGoM");

bool bShowGoM = false;

VOID GoM(PSPAWNINFO pChar, PCHAR szLine)
{
	if (bShowGoM) {
		bShowGoM = false;
		WriteChatColor("No longer announcing Gift of Mana",CONCOLOR_RED);
	}
	else {
		bShowGoM = true;
		WriteChatColor("Now Announcing Gift of Mana",CONCOLOR_GREEN);
	}
}

// Called once, when the plugin is to initialize
PLUGIN_API VOID InitializePlugin(VOID)
{
	AddCommand("/showgom",GoM);
}

// Called once, when the plugin is to shutdown
PLUGIN_API VOID ShutdownPlugin(VOID)
{
	RemoveCommand("/showgom");
}

PLUGIN_API DWORD OnIncomingChat(PCHAR Line, DWORD Color)
{
	DebugSpewAlways("MQ2ShowGoM::OnIncomingChat(%s)",Line);
	if (bShowGoM) {
		if (strstr(Line, " granted a gift of "))
		{
			CHAR szOverlay[MAX_STRING] = "GIFT OF MANA TRIGGERED";
			DisplayOverlayText(szOverlay,CONCOLOR_RED,100,500,500,6000);
			WriteChatf("Gift of Mana triggered");
		}
	}
	return 0;
}
 
Doesn't it say in your window already when you get gom? Also, I get a little icon in my songs window, plus a sound.
 
BadPuss said:
Doesn't it say in your window already when you get gom? Also, I get a little icon in my songs window, plus a sound.

It does, I am not exactly sure what this accomplishes, I guess if your MQ2 window is moving slow and your regular window is moving too fast and your sound is off and your bard songs window is off then this could come in handy.
 
why not make the plugin use the /popup command?
 
siddin said:
why not make the plugin use the /popup command?

/popup uses the same function- DisplayOverlayText. I wanted it to popup red colored text instead of the default light blue so its easier to see, it also stays on the screen longer than regular /popup.
 
Simple Gift of Mana plugin

Users who are viewing this thread

Back
Top
Cart