• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!

[JASS] Question about JASS

Status
Not open for further replies.
Level 8
Joined
Oct 31, 2010
Messages
238
So , I have been reading other people's scripts.

I've got a few questions

I know
JASS:
// ~~~
means Comment

But what about
JASS:
//! ~~
, which often follow
JASS:
//! runtextmacro ~~~
? What's that? It has a gray highlight, compared to comment which has a green highlight.
 
Level 31
Joined
Jul 10, 2007
Messages
6,306
Lua Script
http://www.hiveworkshop.com/forums/jass-functions-413/snippet-lua_jass_io-177419/

Text Macro
JASS:
//! textmacro HELLO takes BOO, ADD1, ADD2
    function $BOO$ takes nothing returns integer
        return $ADD1$ + $ADD2$
    endfunction
//! endtextmacro

//! runtextmacro HELLO("AddFunc11", "5", "6")
//! runtextmacro HELLO("AddFunc15", "11", "4")
//! runtextmacro HELLO("AddFunc22", "11", "11")

That macro example is a really stupid one I know...

Text macros cannot run other text macros unless you are using cjass, which is riddled with 3 hardcore bugs.

Similar to a text macro is a module, but that has its own bugs ...

edit
Keep in mind that Lua is an entirely different language; only related to wc3 because Grimoire uses it for customization.
 
Status
Not open for further replies.
Top