https://github.com/Baaleos/NWNDotNetI've started a github project which is focused on bringing nwnx capabilities to the C# table.
C# is considered one of the more easier of languages to learn and there is alot more support for it from Microsoft with regards to tutorials etc than c++.
I've managed to demonstrate in the code provided
1. Ways to call methods within nwserver via C# - See the creature class in the entities subfolder.
2. Hooking methods / subroutines within the Server process - See hooks : I demonstrate hooking the MainLoop
This project is dependent on WhiteMagic - library from the web that is specifically designed for this.
There is also a memory class which is my own contribution which brings methods such as read pointer etc
Ways this can be used.
If you are in the position to inject your own c++ bootstrapper dll, then you can just tell that dll to then load this .Net dll
At which point you can carry out whatever functionality you want :
Note - I havent done any hooking for the Set/Get local's yet, so there is no mechanism for passing arguments or calling methods in a maintained fashion yet.
Alternatively, you wont need to inject this dll if you use nwnx_dotnet
And then load this library as a child library/
Once that is done, you can then call public methods from inside this library, which can then use the delegates for the internal nwserver methods.
I've tested the hooks with the MainLoop
Tested the Methods for
GetGameObject
GetIsBlind
Can confirm they appear to be functional.
C# May not be as quick as C++ performance wise, but its always nice to have the option to use C# if you want to.