• 🏆 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!
  • 🏆 Hive's 6th HD Modeling Contest: Mechanical is now open! Design and model a mechanical creature, mechanized animal, a futuristic robotic being, or anything else your imagination can tinker with! 📅 Submissions close on June 30, 2024. Don't miss this opportunity to let your creativity shine! Enter now and show us your mechanical masterpiece! 🔗 Click here to enter!

[vJASS] Syntax error on this.deallocate()?

Status
Not open for further replies.
Level 14
Joined
Apr 20, 2009
Messages
1,543
So basically I created some code which works entirely fine in my JNGP.
It uses a public destroy method inside a struct and at the end I put: this.deallocate().

Now when I send this code to a friend of mine who has the exact same version of JNGP (latest) it seems that he's getting the following syntax error:

s__GrappleChain_deallocate(this)

I have no idea why this happens nor does he.


EDIT:
Again, sorry for wasting your time I fixed it already :/

It seems like I forgot to call the deallocation.
For some reason this.deallocate() worked for me but for my friend it had to be call this.deallocate()
 
Level 23
Joined
Apr 16, 2012
Messages
4,041
just a little hint: You dont need to use object/this.method/variable inside struct, writing just .deallocate() or even deallocate() works the same way as you are using it in struct, this goes for all variables/methods as long as they are in the same struct
 
Level 14
Joined
Apr 20, 2009
Messages
1,543
just a little hint: You dont need to use object/this.method/variable inside struct, writing just .deallocate() or even deallocate() works the same way as you are using it in struct, this goes for all variables/methods as long as they are in the same struct

I know but for some reason it's easyer to read for me ;)
I can overview things easier when the this. keyword is used.
 
Status
Not open for further replies.
Top