ESOUI

ESOUI (https://www.esoui.com/forums/index.php)
-   General Authoring Discussion (https://www.esoui.com/forums/forumdisplay.php?f=174)
-   -   function: loadSkillInfo (https://www.esoui.com/forums/showthread.php?t=10769)

Mr_Negative 12/31/23 12:23 PM

function: loadSkillInfo
 
I'm trying to get the info needed to make this use the Vampire skill (Mesmerize) but can't get it to work, can someone help, where do I find all the info reguarding the skill. like skillType = 3, skillLine = 2 or ability_vampire_001.


Lua Code:
  1. l.loadSkillInfo = function()
  2.   if not IsPlayerActivated() then return end
  3.   l.rmSkillInfo = nil
  4.   l.progressionIndexToSkillInfo = {}
  5.  
  6.   for skillType = 3, GetNumSkillTypes() do
  7.     for skillLine = 2, GetNumSkillLines(skillType) do
  8.       for abilityIndex = 3, math.min(7, GetNumAbilities(skillType, skillLine)) do
  9.         local abilityId = GetSkillAbilityId(skillType, skillLine, abilityIndex, false)
  10.         local abilityName, texture, earnedRank, passive, ultimate, purchased, progressionIndex, rankIndex =
  11.             GetSkillAbilityInfo(skillType, skillLine, abilityIndex)
  12.        
  13.         local info = {
  14.           skillType = skillType,
  15.           skillLine = skillLine,
  16.           abilityIndex = abilityIndex,
  17.           abilityId = abilityId,
  18.           abilityName = abilityName,
  19.           progressionIndex = progressionIndex,
  20.         }
  21.  
  22.         if string.find(texture, 'ability_vampire_001', 1, true) then
  23.           l.rmSkillInfo = info
  24.         elseif progressionIndex then
  25.           l.progressionIndexToSkillInfo[progressionIndex] = info
  26.         end
  27.       end
  28.     end
  29.   end
  30. end




Trying to make stage 4 vampirism a little less of a hastle.

Baertram 12/31/23 01:58 PM

Moved the thread to the proper forum.
Please encapsulate code blocks with the [ code ][ /code ] or [ highlight="Lua" ][ /highlight ] (no spaces!) so one can better read it.
Simply mark the text you want to have as code/lua highlight and then press the button "#" or "(small blue ball with lua)" in the editor icon row above the text edit field.

Mr_Negative 12/31/23 02:30 PM

Sorry
 
Quote:

Originally Posted by Baertram (Post 49106)
Moved the thread to the proper forum.
Please encapsulate code blocks with the [ code ][ /code ] or [ highlight="Lua" ][ /highlight ] (no spaces!) so one can better read it.
Simply mark the text you want to have as code/lua highlight and then press the button "#" or "(small blue ball with lua)" in the editor icon row above the text edit field.

I'm a total novice sorry about all the edits.

Mr_Negative 12/31/23 02:38 PM

When like this I get caltrops if I change the ability_ava_001 back to the origonal ability_ava_002 I get rapid maneuver, I'm still messing with it here hoping I can work it out

Lua Code:
  1. l.loadSkillInfo -- #()->()
  2. = function()
  3.   if not IsPlayerActivated() then return end
  4.   l.rmSkillInfo = nil
  5.   l.progressionIndexToSkillInfo = {}
  6.   for skillType = 1, GetNumSkillTypes() do
  7.     for skillLine = 1, GetNumSkillLines(skillType) do
  8.       for abilityIndex = 1, math.min(7, GetNumAbilities(skillType, skillLine)) do
  9.         local abilityId = GetSkillAbilityId(skillType, skillLine, abilityIndex, false)
  10.         local abilityName,texture,earnedRank,passive,ultimate,purchased,progressionIndex,rankIndex =
  11.           GetSkillAbilityInfo(skillType, skillLine, abilityIndex)
  12.         local info = {
  13.           skillType = skillType,
  14.           skillLine = skillLine,
  15.           abilityIndex = abilityIndex,
  16.           abilityId = abilityId,
  17.           abilityName = abilityName,
  18.           progressionIndex = progressionIndex,
  19.         }--#SkillInfo
  20.         if string.find(texture,'ability_ava_001',1,true) then
  21.           l.rmSkillInfo = info
  22.         elseif progressionIndex then
  23.           l.progressionIndexToSkillInfo[progressionIndex] = info
  24.         end
  25.       end
  26.     end
  27.   end
  28. end

I have been searching for some time as to what the skillType, skillLine and abilityIndex would be for vampire but had no luck.

Mr_Negative 12/31/23 03:39 PM

Got it! :)

Lua Code:
  1. l.loadSkillInfo -- #()->()
  2. = function()
  3.   if not IsPlayerActivated() then return end
  4.   l.rmSkillInfo = nil
  5.   l.progressionIndexToSkillInfo = {}
  6.   for skillType = 1, GetNumSkillTypes() do
  7.     for skillLine = 1, GetNumSkillLines(skillType) do
  8.       for abilityIndex = 1, math.min(7, GetNumAbilities(skillType, skillLine)) do
  9.         local abilityId = GetSkillAbilityId(skillType, skillLine, abilityIndex, false)
  10.         local abilityName,texture,earnedRank,passive,ultimate,purchased,progressionIndex,rankIndex =
  11.           GetSkillAbilityInfo(skillType, skillLine, abilityIndex)
  12.         local info = {
  13.           skillType = skillType,
  14.           skillLine = skillLine,
  15.           abilityIndex = abilityIndex,
  16.           abilityId = abilityId,
  17.           abilityName = abilityName,
  18.           progressionIndex = progressionIndex,
  19.         }--#SkillInfo
  20.         if string.find(texture,'ability_u26_vampire_04',1,true) then
  21.           l.rmSkillInfo = info
  22.         elseif progressionIndex then
  23.           l.progressionIndexToSkillInfo[progressionIndex] = info
  24.         end
  25.       end
  26.     end
  27.   end
  28. end


All times are GMT -6. The time now is 03:26 PM.

vBulletin © 2024, Jelsoft Enterprises Ltd
© 2014 - 2022 MMOUI