| 12-29-2007, 01:27 PM | #1 |
Do BJs leak? Do calls leak? That is all. Thanks for the future answer. |
| 12-29-2007, 01:48 PM | #2 |
some BJs are leaky, most are useless and i don't quite understand what do you mean by leaking a calls.. |
| 12-29-2007, 01:52 PM | #3 |
Yeah, I ask if calls leak because I heard that they make a leak when you try to call a native with 2 calls as opposed to 1. I don't understand this 100%, but as far as I know, calls do not leak. |
| 12-29-2007, 01:55 PM | #4 |
well i understand that you use GUI, but I guess you really should switch to jass now, as you want to improve your triggers and code |
| 12-29-2007, 01:58 PM | #5 |
I can't use vJass due to my OS, but I would like to know (Vexorian's tutorial is an entrance point but it doesn't seem to do what I need it to) a good way of manipulating object data as opposed to strings.... |
| 12-29-2007, 02:05 PM | #6 |
im not asking you to use vjass... just normal jass, as normal editors will be able to support those for good |
| 12-29-2007, 02:11 PM | #7 |
I'm very sorry if I made it seem like I was asking... but all I was requesting was a tutorial on object manipulation as well as how to work loops... that'd get me on my way for Jass. |
| 12-29-2007, 02:57 PM | #8 |
If you are curious how BJ's work, go to http://www.wc3jass.com/index.php?scr...e8feb0f85c82d0 and look around in blizzard.j scripts (which is where the BJ's are). BJ's are just functions that reference other functions. Some where made to unify a couple of lines of code (like opening/closing gates) and others I don't know (some BJ's reference a function that does the exact same thing but the variables are in different order) There are plenty of tutorials here if you want to learn JASS, that's how I llearned. |
| 12-29-2007, 05:40 PM | #9 |
Blizzard.j Common.j Common.ai The 3 most used script files in the game. Common.j holds natives (functions defined in the game engine itself). Blizzard.j holds JASS-written functions, mostly used for the GUI. Common.ai holds ai related natives. A leak is caused by something being created, loosing all references, and then never being destroyed. WC3's reference counter for handles is broken, thus even if the garbagecleaner did anything useful, it wouldn't clean most handles anyway. (Thus why we null locals, as the "set" statement properly decreases and increases reference counts) You must manually remove any handles you create. (with the exception of things like "player", where they will exist for the whole game and automagically stop existing when the game ends. Units also clean themselves from memory after decay.) Eg: JASS:function ABC takes nothing returns nothing local location l = Location(0,0) call RemoveLocation(l) // remove what you create set l = null // You must null local variables. globals will eventually have their values changed anyway, so they don't mater in that aspect. endfunction loops are easy... JASS:loop exitwhen a == b == c endloop |
| 12-30-2007, 06:01 AM | #10 |
It's good and all that there are tutorials about strings but I REALLY want object data... Does anyone have any object editor tutorials? On side note, this is mostly unrelated, but what happens if I set a unit/doodad's transparency in a GetLocalPlayer() loop? Will it make that object transparent or will it desync that player? |
| 12-30-2007, 06:34 AM | #11 | |
Quote:
Wait don't you mean as TRUE? Like "exitwhen a = b" so if it's false then a =/= b so therefore it repeats itself right? |
| 12-30-2007, 06:56 AM | #12 | |
Quote:
|
| 12-30-2007, 06:58 AM | #13 |
Why would it desync, though? It's not affecting the physical gameplay, is it? |
| 12-30-2007, 11:52 AM | #14 |
Changing an object's transparency in a LocalPlayer block should not cause a desync. |
| 12-30-2007, 12:09 PM | #15 |
Hm... kay... This may seem like I'm jumping around the topic yet again but, are there any tutorials on object manipulation? I've not seen one yet. |
