Learning Lua/Wow addons

Learning Lua/Wow addons

by Shaylin » Sat Nov 12, 2016 11:21 pm

So I have dabbled a little bit in coding over the years. Enough to be one of those that gets themselves in trouble but can pull myself out eventually.

I want to learn Lua and learn how to make addons and create things to further myself and keep teaching myself new things.

Is there anyone or anyplace that's active where I can ask questions or resources on where to go and learn to my hearts content?

I know about wowprogramming but it doesn't seem to be too active anymore.
Shaylin
Tester
 

Re: Learning Lua/Wow addons

by Renew » Sun Nov 13, 2016 8:21 pm

well, wowprogramming is my main ressource for examples and api informations :D

there is no real forums for vanilla devs - but we have a lot of them now and they are all glad to help :)

just make thread or write PMs with your question (if you dont ask stupid things like rdrmdr)

you can also look into other addons to see how problems can be solved :)
my Addons:
- Vanilla Healing Assignments - /viewtopic.php?f=63&t=23326
- Vanilla Storyline -
User avatar
Renew
Senior Sergeant
Senior Sergeant
 

Re: Learning Lua/Wow addons

by Shaylin » Sun Nov 13, 2016 8:56 pm

Haha, yeah for sure. I have always wanted to make something or update an addon. One of the questions I had and maybe you can answer it renew, is there any way to show the counter on a debuff, like rend for instance, and have the time shown based on the rank used?

Right now, EnemyBuffTimersVanilla uses 21 seconds for Rend, but that's at rank 7, as a level 14 warrior, it won't be that long. I could potentially just post it on their thread as well, but I'd like to build one of my own and see how far I could take it.
Shaylin
Tester
 

Re: Learning Lua/Wow addons

by Renew » Sun Nov 13, 2016 9:51 pm

well, such things are not that simpel to answer :)

at first you have to know that the API is huge, you will google/wowprogramming a lot for the functions and events ...

i would recommend you to do these steps to understand more about how wow api works:

- take a look (and understand) at the FrameXML (thats where all the code for the default UI is) and understand how the default buff/debuff systems work, i use this program for that: http://i.imgur.com/Wm3VDde.png

- take a look (and understand) at schakas addon and see why its 21 seconds :)
https://github.com/Schaka/EnemyBuffTime ... anilla.lua

- think about if its it possible to change this 21 seconds to a correct value and how you could achive this

- edit or make an addon

making addons and learn through trial and error is imo the best way to learn :) - its not hard, just do it
my Addons:
- Vanilla Healing Assignments - /viewtopic.php?f=63&t=23326
- Vanilla Storyline -
User avatar
Renew
Senior Sergeant
Senior Sergeant
 

Re: Learning Lua/Wow addons

by Shaylin » Sun Nov 13, 2016 10:16 pm

Ah, I remember that program, yes, I'll have to go back and find it again. I'm a tinkerer at heart, and I'm going to go through trial and error for sure as I believe that's the best way to learn. Find what works from others, understand why it works then build upon that and go from there.

In regard to Schakas addon, I looked in the code of the addon and found that its just set to the timers of the max rank, there's no if then arguments to discern which rank of the spell you are using. Changing the value in the code to 12, definitely reflects in game as well and provides with an albeit, hack around way to get it to work (Obviously I'm going to figure out how to get it to go based off rank, just have to figure out how =D)

FrameXML is where I'm going to head to try and understand what that is and grab the program you showed. I also picked up the book(s) from wowprogramming and will be reading over those when I get a chance as well to understand how things tick.

Thanks for the tips! =)
Shaylin
Tester
 


Return to Addons & macros