Test movie with PrimalScript
2 01 2004I’ve been playing around with PrimalScript for the last two days and I’m really starting to like it. Looks like this editor is going to be my best friend in 2004, its absolutely packed with useful features!
Those of you familiar with SciTE|Flash will probably have heard of Flush which automatically triggers Flash to test your movie. If you do any coding outside the Flash IDE you realize what a timesaver that is, no more switching between programs to test your work.
Now I’m using PrimalScript obviously one of the first things I wanted to do is get something similar in place. I came across a post by Chafic Kazoun that suggested using JSFL to trigger test movie and setting it up as an external program in the debug and release configuration for your project.
Lazy as I am, I didn’t really look forward to the idea of having to set these properties for every single project. A little while later I came across a solution that does the trick for me, in the options window you can specify a “Compile/Syntax check” executable for each supported language. If you choose ActionScript and point this to a JSFL file that triggers test movie you’re all set!
Here is a quick runthrough of how to set this up:
- download compile.jsfl and drop it in your PrimalScript install folder
- go to Tools > Options > Environment > Languages
- choose ActionScript
- from the dropdown menu on the right select Compile/Syntax check
- just under that dropdown menu browse to your install folder
- type “compile.jsfl” and click Open (only .exe’s are shown when browsing)
- press OK
That’s it! Now if you’re editing your ActionScript simply use CTRL+F7 or the compile button to test your code. Just like with Flush you’ll have to have a document open with an #include statement to the ActionScript file you’re editing.
Feel free to leave your comments on this or any other PrimalScript pointers you might have!
[update] I forgot to mention that you’ll also need to specify the JSFL file as the “Script Interpreter” for ActionScript in order for this to work.






some errors occured while I press Ctrl + F7 to debug a simple AS file.
The below message is showed at output panel.
I need u help.:):P
Unable to start D:\Program Files\SAPIEN\PrimalScript\compile.jsfl\compile.jsfl
Strange, I’ve got it running just fine in PrimalScript 3.0 … do you have Flash MX 2004 installed and is the JSFL filetype registered to open with Flash MX 2004?
Thank u for u replied.
I just work with primayScript3.1 and FlashMX2004 is well installed.
Below is my settings of PrimalScript with JSFL debug:
URL:http://www.nblogistics.com/test/blog/aa.html
Thanks for that, I can see you’ve got the path wrong there (or did you create a folder with a dot character?). It looks as though the path should simply be “D:\Program Files\SAPIEN\PrimalScript\compile.jsfl”.
:):)
I think u r so warm-hearted man!!
The path error I’ve corrected befor submit this question.
But the occured the same error :~~~~(
When I off the Capture From Output(use flashMX debug.),this error message showed:
In file “”D:\Program Files\SAPIEN\PrimalScript\compile.jsfl”":
TypeError: fl.getDocumentDOM() has no properties
PS:I’m from China.now is January 3rd 0:04
:):)
Hey Peter, good to see you enjoying PrimalScript like I am. I thought I would make a suggestions, if you edit the project template for ActionScript you can actually add that functionality to all new ActionScript projects. The template is located at C:\Program Files\SAPIEN\PrimalScript\Templates\Project Templates\ActionScript\Empty Project\Project1.pws and is plain xml.
Thanks Chafic, that’s great … didn’t even realize
BlueEmotion: I think you might not have a document open in your Flash IDE. You need to have a document open in Flash that has an #include statement for the ActionScript file you’re working with. The only thing the JSFL file really does is trigger Flash to test the movie.
Thanks for the tip. I’ve been using PrimalScript for awhile, and always did the toggle flash ide/ctrl+enter approach. I figured something like this was out there, just never bothered looking for it.. thanks, hehe.
problem is solved in this moring.
Thank u Peter Elst!
PrimalScript rules! Btw you can set F7 to test and Shift + F7 to publish. Just set one testMovie.jsfl as interpreter and publish.jsfl as compiler. If only I could get publish to run in the background I would be all set!
hi everibody
PrimalScript3.1.440 on my computer doesn’t recognize the methods and properties for predefined AS Classes(no syntax coloring, no parameter hints), however the Classes themselves are recognized.
(for example:
…= new Date();//works fine
but
mc.attachMovie(…//remains gray and no hints)
If anyone could help me I would be grateful
no tips?
i have to manually add the FlashMX2004 Classes library to my project in order to get PrimalSense working
help
problem solved (registry settings)