• 🏆 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!

JNGP error!...

Status
Not open for further replies.
Level 29
Joined
Mar 10, 2009
Messages
5,016
I made a spell and I used JNGP and I entered something like this...

JASS:
 private integer CASTERU          = S2I("Caster")
 private integer TARGETU          = S2I("Target")
 private integer DAMAGER          = S2I("Damage")

and this error keeps on going everytime I save the map...

so I've decided to make a new map and import all stuffs, unit, ability & trigger and no more error...

this is the error btw...


167625-albums4053-picture45667.jpg



so Im asking, why is it like this?...
 
Level 29
Joined
Mar 10, 2009
Messages
5,016
For one, you want to use StringHash not S2I

For two, those should be constant variables

For three, did you try closing & re-opening Jass NewGen Pack and the error still repeated itself?

1. Tnx for the fast reply, Im just experimenting with S2I if it can be done :)...

2. you mean private constant?...

3. Yes, I've tried so many times, still the error appears...I even donloaded the one in your signature but that's not working...
 
Level 37
Joined
Mar 6, 2006
Messages
9,240
S2I i think is just for converting integer strings into integers... like for when you use substrings... meaning the string you feed it should only have integers...

Nope, the string doesn't need to be "integers" :)

I'm not sure why that is happening. I've also had some weird stuff sometimes, like needing to add a comment line for things to work.

Example:

JASS:
call SetUnitX(u)
call SetUnitY(u)
//
call UnitDamageTarget(...)

And it just didn't go past the SetUnitX/Y if there was no // inbetween.
 
Level 29
Joined
Mar 10, 2009
Messages
5,016
first I dont use UMSWE models or 'things'...
second, its just as simple as 'changing' the code, then the error never stopped...
third, now the error strikes again...I worked on a new spell last night, then I changed the filename, the the error came...I changed the filename back, still has error...

this is so bloody annoying!...
 
Status
Not open for further replies.
Top