Author Topic: Syntax Error after exec. What the actual forget?  (Read 904 times)


The last 2 lines... What the forget? I didn't type that. What did I do wrong

Post your code here, unless you're trolling..(?)


function AzjRadioBeaconImage::onDone(%this,%obj,%slot)
{
   %obj.unMountImage(%slot);
}

Does executing the file directly with it outside of a zip file work?

Make sure you do setmodpaths(getmodpaths()); before executing manually.

The error isn't even on that function, post the correct one.

Solution: Don't put your add-on into a zip archive until it's ready for release.

Does executing the file directly with it outside of a zip file work?
I moved the file out of the zip and it worked perfectly.
I guess it was just something with the zip

Changing your code while it's in a zip can forget with the evaluator. Either setModPaths(getModPaths()); or just use a folder.

discoverFile("Add-Ons/Whatever_The_Zip_Is.zip");
exec("Add-Ons/Whatever_The_Zip_Is/whatever.cs");

Use folders when you're developing things though, a lot easier in the long run. Just package everything into a .zip when you're completely done making your add-on.

discoverFile("Add-Ons/Whatever_The_Zip_Is.zip");
exec("Add-Ons/Whatever_The_Zip_Is/whatever.cs");

Use folders when you're developing things though, a lot easier in the long run. Just package everything into a .zip when you're completely done making your add-on.
Had to package the item due to some spawning errors (why? I dont even know)

When you modify something in a .zip folder, you must use setModPaths(getModPaths()); or discoverfile("add-ons/FileZip.zip"); before exec("add-ons/FileZip/server.cs"); (or client.cs or whatever) because the zip file isn't updated while making a folder with a description.txt and a server.cs is always updated, I believe. I have had this problem many times until I learned it was this that was causing it.
« Last Edit: April 08, 2014, 07:27:05 AM by Advanced Bot »