Author Topic: Noob question  (Read 709 times)

Legacy_Deerber

  • Newbie
  • *
  • Posts: 6
  • Karma: +0/-0
Noob question
« on: November 21, 2014, 03:25:02 am »


               

Hi all.


 


I apologize in advance, as this is no doubt a very silly question, but I've never really modded NWN and I can't find an aswer to what I have in mind. Also, this might not be the right subforum for this - let me know if that's the case


 


So, I'm playing with the Player Resource Compendium PrC pack 3.5, and I'm going through the Original Campaign.


 


I would like to know if it's possible to alter a script in the Original Campaign modules. How do you do that? I don't wanna create other modules or anything - just a little alteration to a script.


 


Thanks in advance for the help!



               
               

               
            

Legacy_Shadooow

  • Hero Member
  • *****
  • Posts: 7698
  • Karma: +0/-0
Noob question
« Reply #1 on: November 21, 2014, 07:29:18 am »


               


Hi all.


 


I apologize in advance, as this is no doubt a very silly question, but I've never really modded NWN and I can't find an aswer to what I have in mind. Also, this might not be the right subforum for this - let me know if that's the case


 


So, I'm playing with the Player Resource Compendium PrC pack 3.5, and I'm going through the Original Campaign.


 


I would like to know if it's possible to alter a script in the Original Campaign modules. How do you do that? I don't wanna create other modules or anything - just a little alteration to a script.


 


Thanks in advance for the help!




possible, you need to know name of the script, then open campaign in toolset, modify script, compile then externalize via modules/temp0 folder (ncs/nss files) and put into override. If the script is from PRC then you must put it into prc_2das hak. (Though, Im not so sure now about override possibly you will have to put it into hak anyway, long time I did this, someone will surely clarify this).


               
               

               
            

Legacy_Proleric

  • Hero Member
  • *****
  • Posts: 1750
  • Karma: +0/-0
Noob question
« Reply #2 on: November 21, 2014, 10:10:54 am »


               

Some scripts are global, others are campaign-specific.


 


If the script is global, you can simply edit it in a new module.


 


If it's campaign-specific, you need to copy the campaign from the nwm folder to the modules folder, renaming it from .nwm to .mod, then edit the copy module. Alternatively, since it's just one script, use the nwnexplorer tool to export the script to a new module.


 


In all cases, as Shadooow says, change and compile the script, then, without closing the toolset, copy the .ncs file from modules/temp0 to override.



               
               

               
            

Baaleos

  • Administrator
  • Hero Member
  • *****
  • Posts: 1916
  • Karma: +0/-0
Noob question
« Reply #3 on: November 21, 2014, 02:15:48 pm »


               

compile then externalize via modules/temp0 folder (ncs/nss files) and put into override

 


 


What Shadooow says is correct, however it sounds alot more technical than it actually is.


Open the campaign you want to modify in toolset, and when you open script editor - click 'open' and then choose Module Resources / Scripts from the radio button / selection.


 


The open script dialog will now show module scripts, and you can edit as needed.


It will warn you when saving that if you save, it will overwrite the module resource - thats ok, let it do so.


If you ever need to revert to the base module script, you need to delete the nss and ncs from the temp0 folder / module.


 


Make sure you build your scripts to ensure that the compiled versions are created and overwrite the internal scripts used by the campaign.



               
               

               
            

Legacy_WhiteTiger

  • Hero Member
  • *****
  • Posts: 889
  • Karma: +0/-0
Noob question
« Reply #4 on: November 21, 2014, 03:03:22 pm »


               


What Shadooow says is correct, however it sounds alot more technical than it actually is.


Open the campaign you want to modify in toolset, and when you open script editor - click 'open' and then choose Module Resources / Scripts from the radio button / selection.


 


The open script dialog will now show module scripts, and you can edit as needed.


It will warn you when saving that if you save, it will overwrite the module resource - thats ok, let it do so.


If you ever need to revert to the base module script, you need to delete the nss and ncs from the temp0 folder / module.


 


Make sure you build your scripts to ensure that the compiled versions are created and overwrite the internal scripts used by the campaign.




 


Not all campaigns are in the module folder, then you can not open them with aurora toolset.


To make a modified script works in any original campaign, you must paste the modified script in override folder.


1. Open Aurora Toolset and start any module.


2. Open script editor and edit the script you want.


3. Save and compile.


4. Go to temp0 folder and copy your script file.nss.


5. Paste to override.


All campaigns will run the modified script.


 


PS: If the campaign you're playing is available in Aurora Toolset, the procedure of Baaleos should work as well.



               
               

               


                     Modifié par WhiteTiger, 21 novembre 2014 - 09:21 .
                     
                  


            

Legacy_Deerber

  • Newbie
  • *
  • Posts: 6
  • Karma: +0/-0
Noob question
« Reply #5 on: November 21, 2014, 09:55:33 pm »


               

Thanks guys! With your help, I managed to make it work '<img'>

 


The script was a global one, so I didn't even have to copy the module, but it didn't work until I plugged the new scripts from the temp0 folder into the PRC hak. It's not a PRC-specific script, but I guess it gets modified by it in some way.


 


Anyway, now it works. Thanks! ':wizard:'



               
               

               
            

Legacy_Deerber

  • Newbie
  • *
  • Posts: 6
  • Karma: +0/-0
Noob question
« Reply #6 on: November 22, 2014, 07:14:33 pm »


               

Alright guys, since you've been so helpful last time, I'm asking for your knowledge once again '<img'>


 


This time I'm trying to alter a PrC script. But, clearly, I need to find a way to compile it.


 


What I've done is downloading the prc compiler, put it in a folder, then extract all the contents of prc_include.hak in a subdirectory called "include" and I'm using the following line to try and compile the script (which is "prc_onmodload"):


 


nwnnsscomp -g -i ..\include prc_onmodload.nss


 


However, whenever I do that, I get this error:


 


Compiling: prc_onmodload.nss

prc_alterations.nss(43): Error: Unable to open the include file "inc_abil_damage"

Compilation aborted with errors

Errors occurred in compiling "prc_onmodload.nss"

 

 

 

... And I cannot figure out what is wrong. I've checked the "include" directory and both prc_alterations and inc_abil_damage are there...

 

Any help?