Code changes, see commit description
Combat Objects which has been discarded due to any reason will have the boolean member: __destroyed set to true. With this change, 3rd party code can see if the data cached is up to date or obsolete. - Removed several deprecated code from March 2023 and earlier. - Large amount of code cleanup and refactoring, some functions got renamed, they are listed below: * TravarTempos renamed to LockActivityTime. * ClearTempTables renamed to ClearCacheTables. * SpellIsDot renamed to SetAsDotSpell. * FlagCurrentCombat remamed to FlagNewCombat_PVPState. * UpdateContainerCombatentes renamed to UpdatePetCache. * segmentClass:AddCombat(combatObject) renamed to Details222.Combat.AddCombat(combatToBeAdded) - CurrentCombat.verifica_combate timer is now obsolete. - Details.last_closed_combat is now obsolete. - Details.EstaEmCombate is now obsolete. - Details.options is now obsolete. - Added: Details:RemoveSegmentByCombatObject(combatObject) - Spec Guess Timers are now stored within Details222.GuessSpecSchedules.Schedules, all timers are killed at the end of the combat or at a data reset. - Initial time to send startup signal reduced from 5 to 4 seconds. - Fixed some division by zero on ptr 10.1.5. - Fixed DETAILS_STARTED event not triggering in some cases due to 'event not registered'.
This commit is contained in:
@@ -278,7 +278,7 @@ do
|
||||
local savedSpellData = Details.savedCustomSpells[index]
|
||||
if (savedSpellData) then
|
||||
savedSpellData[2], savedSpellData[3] = spellName or savedSpellData[2], spellIcon or savedSpellData[3]
|
||||
return rawset (Details.spellcache, savedSpellData[1], {savedSpellData[2], 1, savedSpellData[3]})
|
||||
return rawset(Details.spellcache, savedSpellData[1], {savedSpellData[2], 1, savedSpellData[3]})
|
||||
else
|
||||
return false
|
||||
end
|
||||
@@ -382,12 +382,12 @@ do
|
||||
|
||||
--overwrite for API GetSpellInfo function
|
||||
Details.getspellinfo = function(spellId)
|
||||
return unpack(Details.spellcache[spellId])
|
||||
return unpack(Details.spellcache[spellId]) --won't be nil due to the __index metatable in the spellcache table
|
||||
end
|
||||
Details.GetSpellInfo = Details.getspellinfo
|
||||
|
||||
--overwrite SpellInfo if the spell is a DoT, so Details.GetSpellInfo will return the name modified
|
||||
function Details:SpellIsDot(spellId)
|
||||
function Details:SetAsDotSpell(spellId)
|
||||
--do nothing if this spell already has a customization
|
||||
if (defaultSpellCustomization[spellId]) then
|
||||
return
|
||||
|
||||
Reference in New Issue
Block a user