Note: LucasForums Archive Project
The content here was reconstructed by scraping the Wayback Machine in an effort to restore some of what was lost when LF went down. The LucasForums Archive Project claims no ownership over the content or assets that were archived on archive.org.

This project is meant for research purposes only.

Scripts won't open in KotOR Tool

Page: 1 of 1
 Miltiades
11-15-2006, 11:22 AM
#1
When I double-click a .ncs file in Kotor Tool, it says that it's got an error leading nwnnsscomp and asks if it is installed in the same directory as Kotor Tool. But nwnnsscomp is installed in that directory.

Help, please.
 Kaspian
11-15-2006, 12:06 PM
#2
Do you want to decompile that *.ncs or just look into some *.nss?

Edit: It's strange - my version of KT is 1.0.2210.16738, Hazard's nwnnsscomp.exe is copied in KT's directory and everything works when I double-click any *.ncs file.
 tk102
11-15-2006, 12:27 PM
#3
If you're unable to get KT to decompile the script for you, you can do it manually also. Extract the .ncs file to a folder and run the command line nwnnsscomp.exe utility to decompile the source code to .pcode. I believe the syntax is simply
nwnnsscomp -d my_ncs_file.ncs


As Kaspian intimated, you might be able to find the .nss file within the scripts.bif, or failing that, you could download the DeNCS utility (http://www.lucasforums.com/showthread.php?t=149198) so that you don't have to interpret the .pcode yourself.

Sorry I can't provide direct KT assistance.
 Miltiades
11-16-2006, 1:01 PM
#4
Yeah, I know how to do it manually, I just thought it was possible with Kotor Tool.

@Kaspian: I have Fred Tetra's version of nwnnsscomp, not Hazard's. I've read that Hazard's only works with K1 scripts. Still, Fred's version should work properly, don't know why it doesn't.
 tk102
11-16-2006, 1:12 PM
#5
Hazard's version works with both (it's what I normally use), you just need to have TSL's nwscript.nss in the same folder as nwnsscomp.exe.

Are you working on a computer in which TSL is installed or on an offline machine?
 Kaspian
11-16-2006, 5:39 PM
#6
Miltiades > What is your version of Kotor Tool? I'll test Fred's compiler tomorrow (still at work)
 Miltiades
11-16-2006, 7:09 PM
#7
Same as yours, 1.0.2210.16738.

@tk102: TSL is installed.
 tk102
11-16-2006, 9:51 PM
#8
Well, hmm... have you tried reinstalling KotOR Tool?
:giveup:
 Miltiades
11-17-2006, 11:46 AM
#9
Didn't work. I'll try Hazard's version of nwnnsscomp, see what that gives.
 Kaspian
11-17-2006, 12:32 PM
#10
I tried Fred's compiler and it works. Next I created an empty file, put "ABCDEFGH" text in it, saved as nwnnsscomp.exe in KT's directory and guess what ... it worked :) No "Error launching nwnnsscomp" - scripts will not compile (tried it, system hung up).

I got the error only once when my file's name wasn't nwnnsscomp.exe
 tk102
11-17-2006, 2:12 PM
#11
Just thought of something. Do you have a non-US version of TSL installed? There was a syntax error in nwscript.nss that was distributed to non-US version of the game (details here (http://www.lucasforums.com/showthread.php?p=1767073#post1767073)). If you have this syntax error, then nwnnsscomp will fail. Now if you correct the syntax error in nwscript.nss and place nwscript.nss into the same folder as the nwnnsscomp.exe, you should be in business.
 Miltiades
11-17-2006, 5:01 PM
#12
Yep, I have a non-US version, but I've edited the nwscript.nss a long time ago, so that can't be the problem.

@Kaspian: The filename is correct. There was something weird though. When doubleclicking the nwnnsscomp.exe in the KT map, it opens and closes very quickly. When opening it in the original map, it opens and a whole bunch of lines come up in the window, very fast and non-stop. They're both the same file, so I don't have a clue what this could be.
Page: 1 of 1