• Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.

[Trigger] Freaking triggering

Status
Not open for further replies.
Level 9
Joined
Apr 4, 2004
Messages
519
This is a problem that constantly comes up when I've done a little triggering.

When I save my map after triggering let's say a short cinematic sequence there's always some error coming up regarding something. I just recently triggered a short cinematic sequence and the error says there's 73 compile errors. "Invalid number of arguments" "Expected a code statement" "Expected a function name".

I can't really say I'm a pro at triggering, but I doubt I did so many mistakes on my triggering. This error had this text marked after saving the map.

call CreateItem( 'lhst', -2179,3, -3965,4 )

Any ideas of why this kind of things happen? (If you need a picture of my trigger function just let me know and I'll post a picture.)
 
Level 15
Joined
Nov 1, 2004
Messages
1,058
According to the API, CreateItem only takes 3 arguments:
Code:
CreateItem      takes integer itemid, real x, real y returns item

But you are calling it with 5 arguments. Maybe you wanted to call it like this?
Code:
call CreateItem( 'lhst', -2179.3, -3965.4 )

Hint: use a period "." as your decimal separator instead of a comma ",". :wink:
 
Level 9
Joined
Apr 4, 2004
Messages
519
Yes, I use periods "." and not commas"," but it seems to change by itself.

**EDIT**

I got a reply on another forum where I was asking the same question and they told me to go into Control Panel -> Regional Options -> Numbers -> Decimal Symbol and change it to a '.'. I'll let ya know if it worked out. :) Thanks for the replies anyways.
 
Last edited:
Status
Not open for further replies.
Top