A hotspot is apparently already defined in _AutoGenerated.ash.
How can I fix that? What is _AutoGenerated.ash and where can I find/edit it?
thanks
"hotspot" is a global array of hotspots in the room, it is made for accessing hotspots by index. _AutoGenerated.ash is a built-in header created by AGS, you cannot modify it.
So how do I get rid of this error? The game won't save anymore.
Quote from: HandsFree on Wed 23/11/2016 20:26:04
So how do I get rid of this error? The game won't save anymore.
There is probably a variable or object called "hotspot" in your game; you need to rename it to something else, because it conflicts with built-in AGS declaration.
The variable is called hCrashSite and there's only one of it.
I can rename to something else I suppose, but why does the game not accept it?
Quote from: HandsFree on Wed 23/11/2016 21:56:30
The variable is called hCrashSite and there's only one of it.
Wait, what is the actual error message you are getting, and what line in your script does it refer to?
Error (line 410): Variable 'hCrashSite' is already defined.
File: _AutoGenerated.ash.
Have you done an editor search for hCrashSite to see if more than one entry?
Oh, first I thought that "hotspot" word is causing this issue.
I made some tests and I found that it is easy to reproduce this bug: all you have to do is to create two objects, hotspots etc and give them the same name. For some reason AGS does not prevent this until you try to save the room or compile the game.
I suggest searching all your room elements to see if you created second hCrashSite somewhere.
Yeah, sorry, there was another one. I was sure there wasn't but it appears I created one ages ago. :confused: