Gem 9

A forum for reporting bugs NOT related to custom plugins.

Moderator: MacroQuest Developers

No_Idea_At_All
a lesser mummy
a lesser mummy
Posts: 49
Joined: Sat Aug 07, 2004 11:28 pm

Gem 9

Post by No_Idea_At_All » Wed Sep 15, 2004 8:11 am

It appears that Gem 9 returns NULL. ${Me.Gem[9]}

Amadeus
The Maestro
The Maestro
Posts: 2036
Joined: Sat Jun 29, 2002 3:51 pm

Post by Amadeus » Wed Sep 15, 2004 10:13 am

In MQ2DataTypes.cpp -- line 1551, change the line to read:

Code: Select all

			if (nGem<9)
...tell me if that fixes it.

User avatar
Cr4zyb4rd
Plugins Czar
Posts: 1449
Joined: Tue Jul 20, 2004 11:46 am

Post by Cr4zyb4rd » Wed Sep 15, 2004 11:21 am

8 needs to be changed to 9 at other various places in MQ2DataTypes
(lines 1563, 1965, 1974 in my source, might be one or two lines off from release source)

also in MQ2Commands in functions MemSpell, LoadSpells, and Cast

lastly EQUIStructs.h in EQCASTSPELLWINDOW (0x8 to 0x9)

That's what I found in my full sweep of the source, but I only looked for things that were checking 0-based arrays.

Amadeus
The Maestro
The Maestro
Posts: 2036
Joined: Sat Jun 29, 2002 3:51 pm

Post by Amadeus » Wed Sep 15, 2004 11:28 am

Not all the functions handle it the same. I had thought I went through most of them before, but I will double-check tonight.

Remember, Gem[0x8] is actually the ninth gem slot :) ...it's just that the code is sometimes altered to take arguments 1-9 instead of 0-8. So, it's just inconsistant throughout and I need to doublecheck them all.

The fix I gave should fix the one error that was reported by No_Idea_At_All.

User avatar
Cr4zyb4rd
Plugins Czar
Posts: 1449
Joined: Tue Jul 20, 2004 11:46 am

Post by Cr4zyb4rd » Wed Sep 15, 2004 11:35 am

Remember, Gem[0x8] is actually the ninth gem slot :)
When I'm allocating the space for it...?

Perhaps you missed the last line of my post...or chose to ignore it...

edit: FWIW a define for MAX_SPELL_GEMS wouldn't be terribly out of line