GUI syntax error

hgkjfhfdsj

Active Member
Reaction score
55
SOLVED
Trigger:
  • Shape
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to Channel
    • Actions
      • Custom script: set udg_xCentre = GetUnitX(GetTriggerUnit())
      • Custom script: set udg_yCentre = GetUnitY(GetTriggerUnit())
      • For each (Integer A) from 1 to 36, do (Actions)
        • Loop - Actions
          • Set X = (((2.00 / 3.00) x ((Cos((Real((Integer A))))) x 10.00)) - ((1.00 / 3.00) x (Cos((2.00 x ((Real((Integer A))) x 10.00))))))
          • Set X = ((X x 400.00) + xCentre)
          • Set Y = (((2.00 / 3.00) x ((Sin((Real((Integer A))))) x 10.00)) - ((1.00 / 3.00) x (Sin((2.00 + ((Real((Integer A))) x 10.00))))))
          • Set Y = ((Y x 400.00) + yCentre)
          • Unit - Create 1 Missile for (Owner of (Triggering unit)) at (Point(X, Y)) facing Default building facing degrees

for some reason why i get a syntax error when i compile this trigger in the line
Trigger:
  • Unit - Create 1 Missile for (Owner of (Triggering unit)) at (Point(X, Y)) facing Default building facing degrees


error
missing ')'
cannot convert real to location

without this line, it compiles ..

i tried
Trigger:
  • Custom script: set udg_Temp_Point = Location(udg_X , udg_Y)

then later putting it back into the Point..but to no avail

any ideas? :p

edit
however when i did
Trigger:
  • custom script: call CreateUnit(GetOwningPlayer(GetTriggerUnit()), 'u001', udg_X, udg_Y, 270)

it compiled....
 

Never_Quit

New Member
Reaction score
16
I have never had this issue with GUI.

I know that in java, when you try to compile a variable that is created in a for loop, it will error out.

Are the X and Y variables initialized inside your variable GUI box?
 

hgkjfhfdsj

Active Member
Reaction score
55
Are the X and Y variables initialized inside your variable GUI box?
im pretty sure
i figured the problem lies in Point(X, Y) & Location(udg_X , udg_Y) since createunit with global X & Y works.. but dw about now, i think its just my editor..
 
General chit-chat
Help Users
  • No one is chatting at the moment.

      The Helper Discord

      Staff online

      Members online

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top