Thread Tools Display Modes
03-07-11, 10:25 AM   #1
perlsyntax
A Deviate Faerie Dragon
Join Date: Mar 2011
Posts: 15
world of warcraft programming

I start out to program in world of worldcraft and not sure what tools i need to use without worry about virus.

Is there a IDE i can use with all the tools i need for windows 7?


How do i install Lua in windows?

Last edited by perlsyntax : 03-07-11 at 10:29 AM.
  Reply With Quote
03-07-11, 10:52 AM   #2
Aprikot
A Frostmaul Preserver
 
Aprikot's Avatar
AddOn Author - Click to view addons
Join Date: Feb 2010
Posts: 284
I use LuaWoW with Notepad++ which is discussed in this thread (a few down from yours ).

You don't need Lua installed on your system to write WoW AddOns, but if you want it anyway lua.org is where to start.
  Reply With Quote
03-07-11, 10:55 AM   #3
perlsyntax
A Deviate Faerie Dragon
Join Date: Mar 2011
Posts: 15
Originally Posted by Aprikot View Post
I use LuaWoW with Notepad++ which is discussed in this thread (a few down from yours ).

You don't need Lua installed on your system to write WoW AddOns, but if you want it anyway lua.org is where to start.
That good to hear.

what this tool call WowLua do?I reading the WoW programming book and tell me i need Lua install but i guest that not true then.

Last edited by perlsyntax : 03-07-11 at 10:58 AM.
  Reply With Quote
03-07-11, 11:18 AM   #4
Aprikot
A Frostmaul Preserver
 
Aprikot's Avatar
AddOn Author - Click to view addons
Join Date: Feb 2010
Posts: 284
To test Lua code outside of WoW, yes you would need a Lua interpreter, but if you're testing your code in WoW itself, you don't. Having said that, if you're learning from scratch via the book, I'd do what it says.

WowLua is a WoW-specific syntax highlighting plugin for your text editor. It highlight elements of the WoW API in addition to normal Lua syntax highlighting.

I have mine currently set like the Lua highlighting on these forums:
Attached Thumbnails
Click image for larger version

Name:	289d7xh.png
Views:	820
Size:	74.5 KB
ID:	5828  
  Reply With Quote
03-07-11, 11:23 AM   #5
perlsyntax
A Deviate Faerie Dragon
Join Date: Mar 2011
Posts: 15
[quote=Aprikot;231232]To test Lua code outside of WoW, yes you would need a Lua interpreter, but if you're testing your code in WoW itself, you don't. Having said that, if you're learning from scratch via the book, I'd do what it says.

WowLua is a WoW-specific syntax highlighting plugin for your text editor. It highlight elements of the WoW API in addition to normal Lua syntax highlighting.


I unzip it where all the files go then?

Last edited by perlsyntax : 03-07-11 at 11:54 AM.
  Reply With Quote
03-07-11, 11:56 AM   #6
Aprikot
A Frostmaul Preserver
 
Aprikot's Avatar
AddOn Author - Click to view addons
Join Date: Feb 2010
Posts: 284
The Lua for Windows installer is at http://code.google.com/p/luaforwindows/downloads/list. It will install like a normal Windows app (C:\Program Files\, etc.) and will associate .lua files with lua.exe.

This installer also includes SciTE which is a decent text editor that will get you through the book's examples and such. You don't need Notepad++...it's a matter preference.
  Reply With Quote
03-07-11, 11:59 AM   #7
perlsyntax
A Deviate Faerie Dragon
Join Date: Mar 2011
Posts: 15
Originally Posted by Aprikot View Post
The Lua for Windows installer is at http://code.google.com/p/luaforwindows/downloads/list. It will install like a normal Windows app (C:\Program Files\, etc.) and will associate .lua files with lua.exe.

This installer also includes SciTE which is a decent text editor that will get you through the book's examples and such. You don't need Notepad++...it's a matter preference.
How you get that editor to open up?

Last edited by perlsyntax : 03-07-11 at 12:13 PM.
  Reply With Quote
03-07-11, 01:38 PM   #8
Aprikot
A Frostmaul Preserver
 
Aprikot's Avatar
AddOn Author - Click to view addons
Join Date: Feb 2010
Posts: 284
If you ran the Lua for Windows installer it should be at C:\Program Files\Lua\5.1\SciTE\...double click SciTE.exe.
  Reply With Quote
03-07-11, 01:40 PM   #9
perlsyntax
A Deviate Faerie Dragon
Join Date: Mar 2011
Posts: 15
Originally Posted by Aprikot View Post
If you ran the Lua for Windows installer it should be at C:\Program Files\Lua\5.1\SciTE\...double click SciTE.exe.
I think i just use notepad++ how would i write out a wowaddon?
  Reply With Quote
03-07-11, 01:45 PM   #10
Aprikot
A Frostmaul Preserver
 
Aprikot's Avatar
AddOn Author - Click to view addons
Join Date: Feb 2010
Posts: 284
Originally Posted by perlsyntax View Post
how would i write out a wowaddon?
For that, I'll refer you to http://www.google.com/search?sourcei...ng+a+wow+addon and the site which accompanies your book: http://wowprogramming.com/.

Good luck!
  Reply With Quote
03-08-11, 09:52 AM   #11
perlsyntax
A Deviate Faerie Dragon
Join Date: Mar 2011
Posts: 15
Originally Posted by Aprikot View Post
If you ran the Lua for Windows installer it should be at C:\Program Files\Lua\5.1\SciTE\...double click SciTE.exe.
i found it now nice editor

When you stat out your programs in lua do you need a bang sign like you do in perl?
  Reply With Quote
03-08-11, 10:23 AM   #12
Xrystal
nUI Maintainer
 
Xrystal's Avatar
Premium Member
AddOn Author - Click to view addons
Join Date: Feb 2006
Posts: 5,934
Looking at the various addons available will help you see what lua and xml files look like.
__________________


Characters:
Gwynedda - 70 - Demon Warlock
Galaviel - 65 - Resto Druid
Gamaliel - 61 - Disc Priest
Gwynytha - 60 - Survival Hunter
Lienae - 60 - Resto Shaman
Plus several others below level 60

Info Panel IDs : http://www.wowinterface.com/forums/s...818#post136818
  Reply With Quote
03-08-11, 10:25 AM   #13
Mischback
A Cobalt Mageweaver
 
Mischback's Avatar
AddOn Author - Click to view addons
Join Date: Aug 2009
Posts: 221
You should really consider reading your book...

WoW uses Lua as the scripting engine to bring addons "to life", every addon will consist of Lua-code. You don't have to use a bang, 'cause there's no other interpreter working...

When starting an addon, simply create a folder in your "Interface\AddOns", name it "MyFirstAddon", create a file inside named "MyFirstAddon.toc", fill the toc with life (see wowpedia.org for this), create a script file "whatever.lua", reference it in the toc and there you go with your Lua-code.

The HowTos on wowpedia may be a good starting point, the site helped me through a lot of trouble while starting: http://www.wowpedia.org/HOWTOs

Don't forget about the API-documentation there, it's as helpful as the CPAN for Perl. Many code examples, many good hints.
__________________
  Reply With Quote
03-09-11, 09:48 AM   #15
zynix
A Cliff Giant
AddOn Author - Click to view addons
Join Date: May 2008
Posts: 70
Originally Posted by Aprikot View Post
I have mine currently set like the Lua highlighting on these forums:
Aprikot, I really like the way you have set it up, is there any way, that you can upload, or otherwise distribute the settings?
Or maybe a guide to make it look awesome
Thanks
  Reply With Quote
03-09-11, 02:22 PM   #16
Aprikot
A Frostmaul Preserver
 
Aprikot's Avatar
AddOn Author - Click to view addons
Join Date: Feb 2010
Posts: 284
Originally Posted by zynix View Post
Aprikot, I really like the way you have set it up, is there any way, that you can upload, or otherwise distribute the settings?
Or maybe a guide to make it look awesome
Thanks
Sure . The color settings are in "LuaWoW.xml" which I tried to attach, but exceeds the 200 KB cap for XML attachments . Here's the relevant part of that file:

xml Code:
  1. <LexerStyles>
  2.         <!-- ext is the "user defined" one that you set within Notepad++. -->
  3.         <LexerType name="LuaWoW" desc="WoW Gmod Lua" excluded="no" ext="lua">
  4.             <WordsStyle name="DEFAULT" styleID="0" fgColor="E5E5E5" bgColor="202020" fontName="" fontStyle="0" fontSize="" />
  5.             <WordsStyle name="LUA COMMENT BLOCKS" styleID="1" fgColor="808080" bgColor="202020" fontName="" fontStyle="2" fontSize="" />
  6.             <WordsStyle name="CPP COMMENT BLOCKS" styleID="2" fgColor="00A000" bgColor="202020" fontName="" fontStyle="0" fontSize="" />
  7.             <WordsStyle name="LUA COMMENT LINES" styleID="3" fgColor="808080" bgColor="202020" fontName="" fontStyle="2" fontSize="" />
  8.             <WordsStyle name="CPP COMMENT LINES" styleID="4" fgColor="008000" bgColor="202020" fontName="" fontStyle="0" fontSize="" />
  9.             <WordsStyle name="NUMBERS" styleID="5" fgColor="CC66CC" bgColor="202020" fontName="" fontStyle="0" fontSize="">if else for while</WordsStyle>
  10.             <WordsStyle name="OPERATORS" styleID="6" fgColor="66CC66" bgColor="202020" fontName="" fontStyle="0" fontSize="">bool long int char</WordsStyle>
  11.             <WordsStyle name="STRINGS" styleID="8" fgColor="FF0000" bgColor="202020" fontName="" fontStyle="0" fontSize="" />
  12.             <WordsStyle name="CHARACTERS" styleID="9" fgColor="FF0000" bgColor="202020" fontName="" fontStyle="2" fontSize="" />
  13.             <WordsStyle name="LITERAL STRINGS" styleID="11" fgColor="009090" bgColor="202020" fontName="" fontStyle="0" fontSize="" />
  14.             <!-- name is what shows up in the styler config for that style. -->
  15.             <!-- styleID must be 20 through 29 and must be 20 plus the value of the keywordClass. -->
  16.             <!-- keywordClass can be a number between 0 and 8 and corresponds with the group of Keywords above. -->
  17.             <WordsStyle name="LUA INSTRUCTIONS" styleID="20" fgColor="B1B100" bgColor="202020" fontName="" fontStyle="0" fontSize="" keywordClass="0" />
  18.             <WordsStyle name="LUA CONSTANTS" styleID="21" fgColor="0066CC" bgColor="202020" fontName="" fontStyle="0" fontSize="" keywordClass="1" />
  19.             <WordsStyle name="WOW GLOBAL FUNCTIONS" styleID="22" fgColor="CC6600" bgColor="202020" fontName="" fontStyle="0" fontSize="" keywordClass="2" />
  20.             <WordsStyle name="WOW UIOBJECT FUNCTIONS" styleID="23" fgColor="468C46" bgColor="202020" fontName="" fontStyle="0" fontSize="" keywordClass="3" />
  21.             <WordsStyle name="ACE2 FUNCTIONS/CONSTANTS" styleID="24" fgColor="D682FF" bgColor="000000" fontName="" fontStyle="0" fontSize="" keywordClass="4" />
  22.             <WordsStyle name="ACE3 FUNCTIONS/CONSTANTS" styleID="25" fgColor="8000FF" bgColor="000000" fontName="" fontStyle="0" fontSize="" keywordClass="5" />
  23.             <WordsStyle name="WOW GLOBAL TABLES" styleID="26" fgColor="006666" bgColor="202020" fontName="" fontStyle="0" fontSize="" keywordClass="6" />
  24.             <WordsStyle name="UNUSED" styleID="27" fgColor="804040" bgColor="FFFFFF" fontName="" fontStyle="1" fontSize="" keywordClass="7" />
  25.             <WordsStyle name="UNUSED" styleID="28" fgColor="804040" bgColor="FFFFFF" fontName="" fontStyle="1" fontSize="" keywordClass="8" />
  26.         </LexerType>
  27.     </LexerStyles>

This file will be in Notepad++'s plugins config dir after you install the LuaWoW plug (C:\Users\%me%\AppData\Roaming\Notepad++\plugins\config\ on Windows 7).

Install intstructions for LuaWoW itself are at http://code.google.com/p/luawow/wiki/InstallNotepad.

You'd just need to open LuaWoW.xml and replace the existing <LexerStyles> code with the above.
  Reply With Quote
03-11-11, 10:10 AM   #17
zynix
A Cliff Giant
AddOn Author - Click to view addons
Join Date: May 2008
Posts: 70
Originally Posted by Aprikot View Post
Sure

This file will be in Notepad++'s plugins config dir after you install the LuaWoW plug (C:\Users\%me%\AppData\Roaming\Notepad++\plugins\config\ on Windows 7).

You'd just need to open LuaWoW.xml and replace the existing <LexerStyles> code with the above.
Thanks mate, but one question:

So I need to have LuaWoW installed?
Isn't there another way?
Because, I don't really feel the need for it
  Reply With Quote
03-11-11, 11:23 AM   #18
Aprikot
A Frostmaul Preserver
 
Aprikot's Avatar
AddOn Author - Click to view addons
Join Date: Feb 2010
Posts: 284
Originally Posted by zynix View Post
Thanks mate, but one question:

So I need to have LuaWoW installed?
Isn't there another way?
Because, I don't really feel the need for it
No, LuaWoW isn't needed (it's API highlighting). These are the main colors:
  • Background
    • R 32
    • G 32
    • B 32
  • Comment
    • R 128
    • G 128
    • B 128
  • Intruction word
    • R 177
    • G 177
    • B 0
  • Number
    • R 204
    • G 102
    • B 204
  • String
    • R 255
    • G 0
    • B 0
  • Operator
    • R 102
    • G 204
    • B 102
  Reply With Quote
03-11-11, 04:38 PM   #19
zynix
A Cliff Giant
AddOn Author - Click to view addons
Join Date: May 2008
Posts: 70
Originally Posted by Aprikot View Post
No, LuaWoW isn't needed (it's API highlighting). These are the main colors:
  • Background
    • R 32
    • G 32
    • B 32
  • Comment
    • R 128
    • G 128
    • B 128
  • Intruction word
    • R 177
    • G 177
    • B 0
  • Number
    • R 204
    • G 102
    • B 204
  • String
    • R 255
    • G 0
    • B 0
  • Operator
    • R 102
    • G 204
    • B 102
Awesome, thanks mate
  Reply With Quote
03-12-11, 09:47 AM   #20
Aprikot
A Frostmaul Preserver
 
Aprikot's Avatar
AddOn Author - Click to view addons
Join Date: Feb 2010
Posts: 284
Np. I forgot to include that the default foreground color isn't white but rather 229, 229, 229..nice & ez on tha eyez.
  Reply With Quote

WoWInterface » Developer Discussions » General Authoring Discussion » world of warcraft programming


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off