Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.
/*
Plugin: MQ2Faerune originally written by Fossil on Kenetixeq.
Updated by Czarman/Wickedmofo
Desc: Gives you faerune in the bottom slot on your character's client.
Faerune (see invis/ultravision/enduring breath)
*/
#include "../MQ2Plugin.h"
PreSetup("MQ2Faerune");
// Called once, when the plugin is to initialize
PLUGIN_API VOID InitializePlugin(VOID)
{
DebugSpewAlways("Initializing MQ2Faerune");
}
// Called once, when the plugin is to shutdown
PLUGIN_API VOID ShutdownPlugin(VOID)
{
DebugSpewAlways("Shutting down MQ2Faerune");
}
// Called once directly after initialization, and then every time the gamestate changes
PLUGIN_API VOID SetGameState(DWORD GameState)
{
int Slot;
if (GameState==GAMESTATE_INGAME) {
if ((ppCharData) && (pCharData)) {
//Faerune (see invis/ultravision/enduring breath)
Slot = 30;
PSPELL pSpell = GetSpellByName("Faerune");
GetCharInfo2()->Buff[Slot].Unknown0x00 = (BYTE)2;
GetCharInfo2()->Buff[Slot].Level = (BYTE)65;
GetCharInfo2()->Buff[Slot].Modifier = (CHAR)100;
GetCharInfo2()->Buff[Slot].DamageShield = (CHAR)0;
GetCharInfo2()->Buff[Slot].SpellID = (DWORD)pSpell->ID;
GetCharInfo2()->Buff[Slot].Duration = (DWORD)9990;
GetCharInfo2()->Buff[Slot].DamageAbsorbRemaining = (DWORD)0;
}
}
}
Slot = 29; PSPELL pSpell2 = GetSpellByName("Selo`s Song of Travel");
GetCharInfo2()->Buff[Slot].Unknown0x00 = (BYTE)2;
GetCharInfo2()->Buff[Slot].Level = (BYTE)65;
GetCharInfo2()->Buff[Slot].Modifier = (CHAR)100;
GetCharInfo2()->Buff[Slot].DamageShield = (CHAR)0;
GetCharInfo2()->Buff[Slot].SpellID = (DWORD)pSpell2->ID;
GetCharInfo2()->Buff[Slot].Duration = (DWORD)9990;
GetCharInfo2()->Buff[Slot].DamageAbsorbRemaining = (DWORD)0;
Cheesymac said:lets say you wanted to add "Selo`s Song of Travel" , just add this code right below the other (just below (DWORD)0;:
INI:Slot = 29; PSPELL pSpell2 = GetSpellByName("Selo`s Song of Travel"); GetCharInfo2()->Buff[Slot].Unknown0x00 = (BYTE)2; GetCharInfo2()->Buff[Slot].Level = (BYTE)65; GetCharInfo2()->Buff[Slot].Modifier = (CHAR)100; GetCharInfo2()->Buff[Slot].DamageShield = (CHAR)0; GetCharInfo2()->Buff[Slot].SpellID = (DWORD)pSpell2->ID; GetCharInfo2()->Buff[Slot].Duration = (DWORD)9990; GetCharInfo2()->Buff[Slot].DamageAbsorbRemaining = (DWORD)0;