Aller au contenu

Photo

Has anyone been able to mod Toolset?


  • Veuillez vous connecter pour répondre
195 réponses à ce sujet

#76
Shadooow

Shadooow
  • Members
  • 4 469 messages
where to download newest version please?

#77
virusman

virusman
  • Members
  • 282 messages
http://social.biowar...45830/3#7735403

Modifié par virusman, 18 juillet 2011 - 08:49 .


#78
Shadooow

Shadooow
  • Members
  • 4 469 messages
Well i thought that this version used a bugged compiler which was later updated?

#79
virusman

virusman
  • Members
  • 282 messages
Critical bugs have been fixed long time ago.
You can replace the compiler DLL with a newer version for performance, though.

#80
Thayan

Thayan
  • Members
  • 244 messages

virusman wrote...

All warnings go to logs/nwntx_compiler.txt


That log does read this for the problem includes now that I look at that: 
Warning: End of file reached while processing comment
So now that I know what to look for, this tip helps alot. But just as a comment, I do have several packages from the vault, like the tailor models and stuff from Olander's systems, that have a /* at the end of the include which were essentially not recompiling changes using this system because of the includes ending this way. So i would assume that anyone else using them and this compiler would encounter the same issue at the moment.

The PrC compiler provides a similiar warning but actually compiles scripts that had this issue, while this system does not (at the moment). While it would be nice if this could be fixed since I muddled thought this it shouldn't be an issue for anyone reading this thread...hopefully. Just make sure your includes do not have a /* with no */ at the end of them.

#81
Sylrae

Sylrae
  • Members
  • 39 messages
I'm still having a hard time getting this program to run. (Windows 7 Pro, x86)

"MSVCR100.dll is either not designed to run on Windows or it contains an error. Try installing the program again using the original installation media or contact your system administrator or the software vendor for support."

Modifié par Sylrae, 20 juillet 2011 - 09:32 .


#82
virusman

virusman
  • Members
  • 282 messages
My system is x64, so the dll may differ. Remove MSVCR100.dll from the NWN folder and install Visual C++ 2010 Redistributable package.

#83
Sylrae

Sylrae
  • Members
  • 39 messages
Yep. That's what it was, thanks!

Installing the newest version of the x86 dll and copying *That version* into the nwn dir instead made the program run great. Now to test it out.

But first, sleep.

Modifié par Sylrae, 20 juillet 2011 - 09:34 .


#84
zunath

zunath
  • Members
  • 83 messages
Even more amazing additions. Thanks so much!

#85
Sylrae

Sylrae
  • Members
  • 39 messages
Hmm.

Virusman; I'd like to attempt to alter nwmain.exe (either in memory like you did here, or by altering the actual exe like some of the other modifications to nwn I've seen have done, for the pathfinder project.

I have experience with C/C++/C#, ASM, and Java, (and VB.net if it will be in any way useful), but I only have experience with starting a project from scratch, no real exe hacking stuff (some kiddie stuff with a hex editor and snes roms when I was like 13 to change sprites or text). Stuff like changing how combat maneuvers are calculated, and calculating level 1 skill points, and a few other things like that, mostly.
Do you have any advice on what I should read that would explain the basics of how you go about of this type of project?

Modifié par Sylrae, 24 juillet 2011 - 10:58 .


#86
FunkySwerve

FunkySwerve
  • Members
  • 1 308 messages
Hopefully vman will be able to provide a more thorough answer, but this is where he linked me when I asked this:
Click Here

You need a disassembler of some kind, as well. IDA offers their old 5.0 as freeware:
Click Here

Funky

Modifié par FunkySwerve, 24 juillet 2011 - 05:58 .


#87
Sylrae

Sylrae
  • Members
  • 39 messages
Thanks Funky. I'll give that a read, and I downloaded the decompiler.

#88
pkpeachykeen

pkpeachykeen
  • Members
  • 77 messages

Sylrae wrote...

Hmm.

Virusman; I'd like to attempt to alter nwmain.exe (either in memory like you did here, or by altering the actual exe like some of the other modifications to nwn I've seen have done, for the pathfinder project.

I have experience with C/C++/C#, ASM, and Java, (and VB.net if it will be in any way useful), but I only have experience with starting a project from scratch, no real exe hacking stuff (some kiddie stuff with a hex editor and snes roms when I was like 13 to change sprites or text). Stuff like changing how combat maneuvers are calculated, and calculating level 1 skill points, and a few other things like that, mostly.
Do you have any advice on what I should read that would explain the basics of how you go about of this type of project?


Assembly and C/C++ are going to be the two skills that'll apply here. 

There aren't many good resources on how to edit an EXE, at least not in a non-destructive way (editing the actual file is a bad idea, not to mention potentially violating the EULA). The documentation on how Microsoft Research's Detours library works is one of the better sources (EasyHook as well). 

You need to know the names/purposes, location and parameters for the various functions in the engine (varies by version) and you need some idea of the data structures used. At that point, you just intercept functions as needed and run your own code before or after or instead of the original function.

#89
Baaleos

Baaleos
  • Members
  • 1 330 messages
Is there any source code available for the toolset extender and the compiler mod?

I'd like to try and experiment with making it faster via threading - for paralelle nss processing
(It might mess the progress bar up, but who cares)

#90
virusman

virusman
  • Members
  • 282 messages
http://nwn.virusman.ru/svn/nwntx/
Keep in mind, though, that it doesn't take a list of scripts and just compiles it. The plugin hooks the "compile file" function, so you'll probably need to rewrite the Toolset function that calls the compiler.

Modifié par virusman, 09 août 2011 - 12:47 .


#91
Ilerien

Ilerien
  • Members
  • 2 messages
I noticed odd compiler behavior with custom nwscript.nss. The compiler doesn't recognize custom constants from it if they don't start with underline character.
Here is an example module with modified nwscript.nss.
I enabled optimizations in .ini file.

#92
SkywingvL

SkywingvL
  • Members
  • 351 messages
Investigating (sorry, was delayed for a bit with other things). If this is a bug, I'll shoehorn a fix for it into the upcoming release.

#93
SkywingvL

SkywingvL
  • Members
  • 351 messages
This appears to work locally for me - either it's an already fixed bug (I don't recognize it as one offhand), or there may be something else going on (are you trying to compile nwscript.nss itself?):

NWNScriptCompiler.exe -1aceov1.69 -r . x3_mod_def_enter.nss
NWNScriptCompiler - built Sep 4 2011 11:01:15
Copyright © 2008-2011 Skywing.
Portions copyright © 2003-2003, Edward T. Smith.
Portions copyright © 2003, The Open Knights Consortium.
Compiling: x3_mod_def_enter.NSS
Total Execution time = 31ms

This directory contains:

09/07/2011 09:31 PM 2,345 area001.are
09/07/2011 09:31 PM 392 area001.gic
09/07/2011 09:31 PM 724 area001.git
09/07/2011 09:31 PM 3,064 creaturepalcus.itp
09/07/2011 09:31 PM 732 doorpalcus.itp
09/07/2011 09:31 PM 680 encounterpalcus.itp
09/07/2011 09:31 PM 3,948 itempalcus.itp
09/07/2011 09:31 PM 1,978 module.ifo
09/03/2011 01:28 PM 550,247 nwntx_test.mod
09/03/2011 03:31 AM 100,491 nwntx_test.rar
09/07/2011 09:31 PM 499,802 nwscript.nss
09/07/2011 09:31 PM 1,324 placeablepalcus.itp
09/07/2011 09:31 PM 1,889 repute.fac
09/07/2011 09:31 PM 728 soundpalcus.itp
09/07/2011 09:31 PM 488 storepalcus.itp
09/07/2011 09:31 PM 876 triggerpalcus.itp
09/07/2011 09:31 PM 488 waypointpalcus.itp
09/07/2011 09:34 PM 82 x3_mod_def_enter.ncs
09/07/2011 09:34 PM 337 x3_mod_def_enter.ndb
09/07/2011 09:31 PM 232 x3_mod_def_enter.nss

#94
Ilerien

Ilerien
  • Members
  • 2 messages
Forget all I said  :)
Sorry for taking your time, Skywing, I dug deeplier into this problem and noticed that nwscript.nss wasn't reloaded while toolset opened a new module. E.g. I opened a module containing custom nwscript.nss, compiled it successfully, then opened another module containing another custom nwscript.nss with different constants and got compilation errors. So it's much less important problem than I thought.
Thank you for your response.:)
P. S. English isn't native language for me, sorry for possible mistakes...

Modifié par Ilerien, 08 septembre 2011 - 12:46 .


#95
SkywingvL

SkywingvL
  • Members
  • 351 messages
virusman: The toolset plugin could recreate its compiler context on module reload to dump the precompiled information gathered from nwscript.nss here, if you want to fix this.

#96
virusman

virusman
  • Members
  • 282 messages
New plugin - NWNTX Optimizations

One day I got fed up with Toolset hangs, so I decided to optimize some of the ugliest pieces of Toolset code to handle areas with large number of objects and custom content.

* Toolset will use 256 MB of resource cache
* Implemented 2DA caching - areas will load faster
* Toolset no longer hangs (really!) when you select an object in a complex area. The object will not be highlighted in the left panel tree.

Note: this is a pre-release beta version. Although I've tested it on basic tasks, it may crash, hang or corrupt your module. So use at your own risk and back up your module before testing this plugin.
Any feedback and testing is greatly appreciated.

Complete NWNTX package with the new plugin:
http://data.virusman...-full-1.0.3.rar

Modifié par virusman, 14 novembre 2011 - 07:44 .


#97
virusman

virusman
  • Members
  • 282 messages

Modifié par virusman, 13 novembre 2011 - 11:08 .


#98
FunkySwerve

FunkySwerve
  • Members
  • 1 308 messages
Sweet, thank you! Downloading now.

Funky

#99
OldTimeRadio

OldTimeRadio
  • Members
  • 1 400 messages
Wow, very cool!

#100
SkywingvL

SkywingvL
  • Members
  • 351 messages
Release 7 of the NWNScriptCompiler is available, including an updated NWNScriptCompilerDll.ndl module that plugs in to NWNTX. You can grab the updated compiler module here: http://nwvault.ign.c...ns.Detail&id=99

---

Changelog:

Release 7:
----------

- Script programs that contain duplicate definitions for a function, and which
supply empty bodies for such duplicate definitions now correctly trigger a
function redefinition error (NSC1062). Previously, these were incorrectly
permitted (the standard compiler does not permit such constructs).

- Error and warning diagnostic messages that relate to duplicate identifier
definitions now contain a source location pointer to the first definition of
the conflicting identifier.

- Fixed a bug where the command line compiler did not report the number of
errors across all scripts correctly in some circumstances. The error
message listing the total error count was showing an incorrect error count.