[Solved] Syntax Error by creating a group

Status
Not open for further replies.
Level 16
Joined
May 1, 2008
Messages
1,605
Moin moin =)

After longer time ago, I try myself again in vJass, everything works but one thing not. For my spell I need 2 unit groups and I create them in the globals section like this:

JASS:
        private constant group GROUP_ONE = CreateGroup()
        private constant group GROUP_TWO = CreateGroup()

As I said, when I want save the map, I get a syntax error in both lines. I don't know but I created many groups like this for other spells, but here I get an error. Can someone think of why? Both names aren't used before and I can't see any typo. ARE I'M BLIND? =O =S

Greetings and Peace
Dr. Boom
 
Level 16
Joined
May 1, 2008
Messages
1,605
Click Clack Boom

JASS:
        private group GROUP_ONE = CreateGroup()
        private group GROUP_TWO = CreateGroup()

Now I got this, but he still gives those syntax errors, so I guess it must be something else =O

This is the full globals section for non configurable globals:
JASS:
    globals
        private constant real LOOP_TIME = 0.04
        private constant integer TEMP
        private group GROUP_ONE = CreateGroup()
        private group GROUP_TWO = CreateGroup()
        private unit array THUNDER_BALL
        private real array THUNDER_BALL_SCALE
        private real array TB_X
        private real array TB_Y
    endglobals

Where is this f**king error =(
 
Level 22
Joined
Sep 24, 2005
Messages
4,821
you sure your declaring those variables inside a scope or a library? You can't make variables private if it's not inside a scope or library.

Could you post the entire script? It's hard to guess what's wrong if you just show us a small part of it.
 
Level 16
Joined
May 1, 2008
Messages
1,605
Rofl, that was the mistake, actually I never use constant for this TEMP Integer, don't know why I did it here. I removes the constant and now it works.

But why isn't JassHelper so smart and mark the correct line where the error is -_-

Anyway, thank you for helping =)

Greetings and Peace
Dr. Boom
 
Status
Not open for further replies.
Top