• 🏆 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!
  • It's time for the first HD Modeling Contest of 2024. Join the theme discussion for Hive's HD Modeling Contest #6! Click here to post your idea!

What does the colored text in JASSNewGen mean?

Status
Not open for further replies.
Level 6
Joined
Jan 15, 2005
Messages
188
This is more of a curiosity than a true problem. I'm wondering what it means when a function is colored purple or red in Jass NewGen, even though they basically do the same thing. For example:

GroupAddUnit - Purple
GroupAddUnitSimple - Red

What does this difference mean? Is red less safe than purple? I don't understand.
 

Rui

Rui

Level 41
Joined
Jan 7, 2005
Messages
7,550
Non-BJ calls are better because they are natives. You'd have to know JASS to understand this though.
Some BJ calls do nothing else other than call their native counterpart, that's why they are useless. They just run functions in a useless way.
 
Level 8
Joined
Nov 25, 2003
Messages
208
Well, if you're going for JASS they're useless.
In GUI they make a lot of sense in two ways:

1. They ofter re-order the arguments so in the GUI the description can actually be a valid English sentence and not just gibberish.

2. They add another level of abstraction. If one of the functions was broken they could add additional code in the bj-wrapper to fix it, without having to invent a new function. This also ensures that older maps are still compatible with newer/fixed editor versions.
 
Level 19
Joined
Aug 24, 2007
Messages
2,888
Look
each time you run a function it uses CPU
more functions more CPU usage more lag
all BJs contain functions inside them so you call BJs and functions inside it
when you call a native you call a native
when you call a BJ you call BJ and natives inside it
 
Level 19
Joined
Aug 24, 2007
Messages
2,888
Umm btw what Ive said is only for bj functions
bj globals are awsome
examples: bj_DEGTORAD, bj_PI
 
Status
Not open for further replies.
Top