Il semble que les cookies ne soient pas activés dans votre navigateur. Veuillez activer les cookies pour garantir une expérience du site optimale.
Affichage des résultats 1 à 8 sur 8

Discussion: RoR Lua additions

  1. #1
    Date d'inscription
    juin 2011
    Localisation
    Lancaster, England
    Messages
    81

    RoR Lua additions

    There seem to be quite a few changes to LUA code in RoR.

    Specifially the following are likely to be important for coders;
    • When Mounted all the buffs on the player, stances too, are cleared.
    • player:GetMount() returns either a Mount or CombatMount object that can be polled for information.
    • ActiveSkill
    • SkillList
    • Skill
    • SkillInfo
    • SkillType
    • UntrainedSkill
    • GambitSkill (Just logged out, so not sure of syntax there, sorry!)
    The skill items I haven't played with but include descriptions and cooldowns. I think this could open the door to timers on quickslot bars - something I have wanted to do for a while. HOWEVER, I go back to work tomorrow and have no time to work on it. Dammit!

    If anyone else has played with the LUA in Beta and has some interesting info, indeed ANY info, I would love to hear it!

  2. #2
    Date d'inscription
    janvier 2008
    Messages
    909
    Turbine.Gameplay.SkillList
    GetCount() - gets the count
    GetItem(i) - gets the ith item
    event: SkillAdded(object, args) - args.Index (index), args.Skill (skill object)
    event: SkillRemoved(object, args) - args.Index (index), args.Skill (skill object)

    Turbine.Gameplay.SkillInfo
    GetName() - gets the name
    GetDescription() - gets part of the tooltip
    GetType() - one of Turbine.Gameplay.SkilType (Normal, Mount, Gambit)
    GetIconImageID() - presumably the image ID of the skill

    Turbine.Gameplay.Skill
    GetSkillInfo() - gets the SkillInfo of the skill.

    Turbine.Gameplay.ActiveSkill (child of Turbine.Gameplay.Skill)
    GetResetTime() - returns -1 or the time when the current skill cooldown will end
    GetCooldown() - returns the skill's cooldown
    GetBaseCooldown() - returns -1
    IsUsable() - returns if the skill is usable
    event: ResetTimeChanged(obj) - no arguments, fires when the skill is used if there is a cooldown. Probably fires any time the current cooldown changes.

    There does not appear to be a UsableChanged() event for Turbine.Gameplay.ActiveSkill.
    I have not determined if there is a CooldownChanged() event for Turbine.Gameplay.ActiveSkill.

    Turbine.Gameplay.GambitSkill (probably a child of Turbine.Gameplay.Skill)
    (no functions)

    Turbine.Gameplay.GambitSkillIn fo (probably a child of Turbine.Gameplay.SkillInfo)
    GetGambit(i?) - probably returns the ith gambit builder of the gambit
    GetGambitCount() - probably returns the number of gambit builders

    Looks like I can finally replace SkillInfo. Apparently that particular library was horrible enough that I was the only person using it. Well, mostly replace it. There's a couple things that SkillInfo appears to do that the current implementation doesn't. Fortunately, I wasn't using that functionality.
    Dernière modification par moebius92 ; 02/09/2012 à 08h39.

  3. #3
    Date d'inscription
    juin 2011
    Localisation
    Lancaster, England
    Messages
    81
    Just been playing with this and would really like to get a hold of the shortcut from the skillinfo table.

    I can't make this work currently - can anyone out there?

  4. #4
    Date d'inscription
    janvier 2008
    Messages
    909
    SkillData has a table which maps shortcut data strings to skill names that you can use to search the Active and Untrained skills.

  5. #5
    Date d'inscription
    juin 2009
    Localisation
    UK
    Messages
    1 461
    Citation Envoyé par Dvarlin Voir le message
    Just been playing with this and would really like to get a hold of the shortcut from the skillinfo table.

    I can't make this work currently - can anyone out there?
    Been toying around with this for an hour or so but can't get anything directly from the skill or skill info.. I've even tried assigning it to itemcontrols and iteminfocontrols to see if they would take the skill but unfortunately not.

    The only way that seems to work for setting a shortcut is to use the hex ID for the skill..
    Quickslot:SetShortcut(Turbine. UI.Lotro.Shortcut(Turbine.UI.L otro.ShortcutType.Skill, "0x70003E8A"))

    Citation Envoyé par moebius92 Voir le message
    SkillData has a table which maps shortcut data strings to skill names that you can use to search the Active and Untrained skills.
    Exactly this.. You can use the :GetName() function to cross-reference within a skills database such as the one mentioned above.

    Again another case of where being able to access the hex IDs would make things ten times easier.
    [CENTER][SIZE=3][B]Galuhad | Narvelan[/B]
    Lore Breakers of Eldar[/SIZE]

    [URL="http://www.lotrointerface.com/list.php?skinnerid=3762"]Plugins[/URL] | [URL="https://www.lotro.com/forums/showthread.php?538975-Accounts-for-New-Players"]New Player Guide[/URL] | [URL="http://www.twitch.tv/galuhad"]Twitch[/URL]
    [/CENTER]

  6. #6
    Date d'inscription
    juin 2009
    Localisation
    UK
    Messages
    1 461
    Citation Envoyé par moebius92 Voir le message
    Turbine.Gameplay.SkillList
    GetCount() - gets the count
    GetItem(i) - gets the ith item
    event: SkillAdded(object, args) - args.Index (index), args.Skill (skill object)
    event: SkillRemoved(object, args) - args.Index (index), args.Skill (skill object)

    Turbine.Gameplay.SkillInfo
    GetName() - gets the name
    GetDescription() - gets part of the tooltip
    GetType() - one of Turbine.Gameplay.SkilType (Normal, Mount, Gambit)
    GetIconImageID() - presumably the image ID of the skill

    Turbine.Gameplay.Skill
    GetSkillInfo() - gets the SkillInfo of the skill.

    Turbine.Gameplay.ActiveSkill (child of Turbine.Gameplay.Skill)
    GetResetTime() - returns -1 or the time when the current skill cooldown will end
    GetCooldown() - returns the skill's cooldown
    GetBaseCooldown() - returns -1
    IsUsable() - returns if the skill is usable
    event: ResetTimeChanged(obj) - no arguments, fires when the skill is used if there is a cooldown. Probably fires any time the current cooldown changes.

    There does not appear to be a UsableChanged() event for Turbine.Gameplay.ActiveSkill.
    I have not determined if there is a CooldownChanged() event for Turbine.Gameplay.ActiveSkill.

    Turbine.Gameplay.GambitSkill (probably a child of Turbine.Gameplay.Skill)
    (no functions)

    Turbine.Gameplay.GambitSkillIn fo (probably a child of Turbine.Gameplay.SkillInfo)
    GetGambit(i?) - probably returns the ith gambit builder of the gambit
    GetGambitCount() - probably returns the number of gambit builders

    Looks like I can finally replace SkillInfo. Apparently that particular library was horrible enough that I was the only person using it. Well, mostly replace it. There's a couple things that SkillInfo appears to do that the current implementation doesn't. Fortunately, I wasn't using that functionality.
    Trying to get access to the active skills part of the API but I can't for the life of me work out which event calls this..
    [CENTER][SIZE=3][B]Galuhad | Narvelan[/B]
    Lore Breakers of Eldar[/SIZE]

    [URL="http://www.lotrointerface.com/list.php?skinnerid=3762"]Plugins[/URL] | [URL="https://www.lotro.com/forums/showthread.php?538975-Accounts-for-New-Players"]New Player Guide[/URL] | [URL="http://www.twitch.tv/galuhad"]Twitch[/URL]
    [/CENTER]

  7. #7
    Date d'inscription
    janvier 2008
    Messages
    909
    Citation Envoyé par Galuhad Voir le message
    Trying to get access to the active skills part of the API but I can't for the life of me work out which event calls this..
    Turbine.Gameplay.LocalPlayer:G etInstance():GetTrainedSkills( ), Turbine.Gameplay.LocalPlayer:G etInstance():GetUntrainedSkill s(), Turbine.Gameplay.LocalPlayer:G etInstance():GetClassAttribute s():GetTrainedGambits(), and
    Turbine.Gameplay.LocalPlayer:G etInstance():GetClassAttribute s():GetUntrainedGambits() return a Turbine.Gameplay.SkillList object. (The last two only work for Wardens, of course.)

    Turbine.Gameplay.SkillList.Get Item(x) returns a Turbine.Gameplay.ActiveSkill (GetTrainedSkills), Turbine.Gameplay.Gambit (GetTrainedGambits), or Turbine.Gameplay.Skill (GetUntrainedSkills and GetUntrainedGambits). Oddly enough GetUntrainedGambits returns a Turbine.Gameplay.Skill instead of a Turbine.Gameplay.Gambit.

    If you want some undocumented code examples, Response Timer and CC Timer both use ActiveSkills in order to track skill cooldowns. It's pretty basic, but it didn't need to be complex.

  8. #8
    Date d'inscription
    juin 2009
    Localisation
    UK
    Messages
    1 461
    Citation Envoyé par moebius92 Voir le message
    Turbine.Gameplay.LocalPlayer:G etInstance():GetTrainedSkills( ), Turbine.Gameplay.LocalPlayer:G etInstance():GetUntrainedSkill s(), Turbine.Gameplay.LocalPlayer:G etInstance():GetClassAttribute s():GetTrainedGambits(), and
    Turbine.Gameplay.LocalPlayer:G etInstance():GetClassAttribute s():GetUntrainedGambits() return a Turbine.Gameplay.SkillList object. (The last two only work for Wardens, of course.)

    Turbine.Gameplay.SkillList.Get Item(x) returns a Turbine.Gameplay.ActiveSkill (GetTrainedSkills), Turbine.Gameplay.Gambit (GetTrainedGambits), or Turbine.Gameplay.Skill (GetUntrainedSkills and GetUntrainedGambits). Oddly enough GetUntrainedGambits returns a Turbine.Gameplay.Skill instead of a Turbine.Gameplay.Gambit.

    If you want some undocumented code examples, Response Timer and CC Timer both use ActiveSkills in order to track skill cooldowns. It's pretty basic, but it didn't need to be complex.
    Thank you
    [CENTER][SIZE=3][B]Galuhad | Narvelan[/B]
    Lore Breakers of Eldar[/SIZE]

    [URL="http://www.lotrointerface.com/list.php?skinnerid=3762"]Plugins[/URL] | [URL="https://www.lotro.com/forums/showthread.php?538975-Accounts-for-New-Players"]New Player Guide[/URL] | [URL="http://www.twitch.tv/galuhad"]Twitch[/URL]
    [/CENTER]

 

 

Règles de messages

  • Vous ne pouvez pas créer de nouvelles discussions
  • Vous ne pouvez pas envoyer des réponses
  • Vous ne pouvez pas envoyer des pièces jointes
  • Vous ne pouvez pas modifier vos messages
  •  

La session de ce formulaire a expiré. Vous devez recharger la page.

Recharger