BioWare Atari
BioWare Info BioWare Games Support Forums Visit the BioWare Store
Neverwinter Nights Home
Neverwinter Nights Home

Profile: Neverwinter Nights Extender v2

Profile by Jay Watamaniuk

Profile: Neverwinter Nights Extender v2Exploring a persistent world has grown to be one of the favorite ways fans can enjoy playing a multiplayer game with friends. The original boxed version of NWN had very little support for the creation and operation of a persistent world, but the industrious community would not be daunted in their pursuit of massive areas to explore, robust cities to visit, and intriguing characters to meet. The second edition of a ground-breaking program was recently released that addresses the community's desire for a true persistent world in which your actions and character are remembered. We spoke with Papillon who was instrumental in the creation of Neverwinter Nights Extender (NWNX):

Where can we go to read more about NWNX?

http://www.nwnx.org/

What is your involvement with the NWN community?

I have been active in the NWN community since the game first came out and spent most of the time developing for the persistent world of Avlis. As the NWNX team leader, I'm coordinating the further development of the program, and last but not least, I am also the one who invented NWNX.

Can you explain what NWNX is?

Image 6 - Neverwinter Nights Extender v2The Neverwinter Nights Extender (NWNX) is basically a program running on Windows or Linux that takes information from inside the NWN server and gets it outside the NWN server. This is used to extend the functionality of Neverwinter Nights in all kinds of different directions. The first and most famous use for NWNX is the database functionality, which is really only one of the various plug-ins that have been written for NWNX.

Other plug-ins implement shared server vaults (VaultSTER), print out live performance information from the running module (Profiler), offer enhanced data structures (HashSet, SortSet, Array), or add some scripting functions for item manipulation (Functions). Another cool example would be the "Shadow Door" plug-in by Robert Zubek that allows for control of an NWN character from an external AI program written in Lisp.

In addition to these extensions, NWNX also offers server reliability and availability. Through periodic checks, NWNX makes sure that the Neverwinter Nights server is still running. In the event of a server failure a new instance of the server will be launched resulting in maximum uptime and reliability.

NWNX is a program created by serious persistent world developers for other serious persistent world developers, and as such, it is a powerful product that adds some complexity to setting up your server, but also rewards you plenty once everything works. The extensive documentation and the community will help you when you get stuck somewhere.

What limitations in the original NWN engine made you want to make these changes? What issues remain?

Image 1 - Neverwinter Nights Extender v2When I first came up with the concept of database access while working on the persistent world of Avlis in late 2002, Neverwinter Nights offered no practical usable way to store information about the state of the world or characters. The BioWare database did not exist at that point in time and some of the workarounds that people used to store quest information, for example, were kind of clumsy. As NWNX celebrates its second birthday, it has become the premier way to efficiently store information in SQL database servers like MySQL, or other commercial products that offer an ODBC driver.

People use it to offer persistent quests (NPCs remember forever that you talked to them and act accordingly), persistent chests (players can store items there permanently), in-game bulletin boards, and countless of other features.

The VaultSTER plugin could be described as character transfer software, which makes it easy to link several persistent worlds together. Jeroen came up with it when we realized that the traditional way of sharing server vaults using distributed file systems can be very unreliable. This software, based on the TPC/IP network protocol, enables persistent world owners to easily and reliably link up multiple worlds from all over the world. Via compression, this module is very fast and an encryption algorithm takes care of the security of the system. This module forms the basis of the CoPaP organization (see below).

The NWNX Profiler is kind of a pet project for me. I've been constantly hunting the lag monster on Avlis, summoned by scripts running wild, NPCs trying to walk were they really should not (or cannot), and players triggering certain actions. Since the Neverwinter Nights Server offers no way to see where all the CPU cycles are going into, I attached hooks to certain functions in the server that are used to monitor script execution times and time needed for NPC pathfinding. This NWNX plug-in is really not only for persistent worlds--any module developer will benefit from it. Just drop the profiler extension into your NWN directory and see what your module is doing internally. No coding is necessary to get it to work.

Image 2 - Neverwinter Nights Extender v2These are just the plug-ins that I would consider the most important ones, while others might find some of the advanced data structures equally important. There is really not enough space here to describe all that NWNX and its modules have to offer. Check out the nwnx.org web site to find out about the other plug-ins in greater detail.

There are also some issues that have not been tackled yet, such as a way for external programs to trigger events in the server. Another issue people were having with the database part of NWNX is that you cannot store objects to the database--but we might have a little surprise there coming soon.

What has changed from the first version of NWNX?

Originally, NWNX used a different method to get information in and out from the server, which was improved in the second generation of NWNX shortly after the initial release, That is the reason why it is called NWNX2 now.

An important change was introduced in version 2.5 by our programmer Jeroen: the concept of plug-ins. It soon became apparent that NWNX could do much more than just offer database access, and people started to modify the main program. Plug-ins offer a clean way to implement new ideas without running into conflicts with other modifications, and they also make it easy for the end user to choose among a certain subset of functionality that they want to use on their server. For example, you may want to use the database and the profiler functionality. All you need to do is copy the corresponding plug-ins to your NWN directory and they are automatically extending the server's functionality from then on.

Our most recent effort is centered on the nwnx.org web site, which will become the central place for people to get the latest versions, ask questions on the forum, and get help from the documentation section that will be constantly improved over time.

Did the persistent world of Avlis spring from NWNX or was it the other way around?

Image 3 - Neverwinter Nights Extender v2The NWN adaptation of the unique campaign world Avlis was started by Orleron and Silk shortly after the game was released. NWNX came into existence when I realized how many more features I would like to get into the world, but simply could not because NWN would not allow me to. After running into numerous walls surrounding persistency problems, I finally decided to get my hands dirty and came up with a solution. So NWNX clearly is a child of Avlis.

Today, since NWNX has been released as open source software under the GNU Public License (GPL), both Avlis and a large part of the other persistent worlds benefit from NWNX.

Do you think persistent worlds are the future of NWN?

Image 4 - Neverwinter Nights Extender v2We do in fact think so. Most people tend to play a game for a couple of months and then move on to something new, with prettier graphics and even higher system requirements. On the other hand, the focus of people playing persistent worlds seems to be on the community and on character development, which involves deeper dedication compared to playing a game in single player mode.

Another important point is that huge worlds like Avlis, with its 3500+ areas on several servers, require a big, dedicated team in order to get things done on such a scale. This means that persistent worlds are always a team effort, and even as people join and leave the team, the world itself continues to exist.

On an even larger scale, Orleron set up the unique Confederation of Planes and Planets (CoPaP) organization within the Neverwinter Nights community. CoPaP is a group of autonomous persistent worlds united by Jeroen's NWNX VaultSTER plugin and a set of guidelines. Currently CoPaP already contains numerous worlds all linked together, and is still expanding to create a "super multiverse" of servers. There is an endless range of things to do, people to see, etc. See their web site for more information: www.copap.org.

Where does a beginner go to learn about setting up a persistent world?

Image 5 - Neverwinter Nights Extender v2Setting up persistent worlds involves a number of different skills, including imagination, communication skills, scripting knowledge, handling the toolset, running Internet servers, setting up web sites, and so on. There is probably no single person that does everything equally well, and there is also probably no single web site that explains everything. Therefore my suggestion would be to gather a dedicated team and assign people to certain tasks. There are numerous resources on NWN on the web, e.g. my personal favorite on scripting is the NWN Lexicon. Builders will also find valuable information on the "The Builders Project" guild.

As far as setting up NWNX is concerned, our brand new web site on www.nwnx.org is a good start for learning how coders can push the limits with NWNX. The site is meant to give the community a place to gather, ask questions, help others, and publish information about NWNX, such as tutorials.

~


Want to comment on this article or read what others have to say about it? Join the official discussion!

 

 

BioWare Blog
Neverwinter Nights 2 Forums
Hide/Show

English
Deutsch
Français
Español
Italiano

Hide/Show

View Latest Screenshots 

View Latest Screenshots
Hide/Show

Multiplayer Games at Neverwinter Connections

Today
Schedule a Game...



Current time is: (set time)
Sat, 11 June 2011 11:11AM

Hide/Show

Buy Premium Modules

Top NWN: HotU Modules:
1. TORTURED HEARTS II. v1.2
2. More...

Top NWN: SoU Modules:
1. TORTURED HEARTS II. v1.2
2. More...

Top CEP Modules:
1. The Lord of Terror The Diablo Campa...
2. More...

Top Modules - NWVault:
1. Hall of Fame
2. More...

Total Modules: 4423

Hide/Show

6,398,954 BioWare Users:
  5 Logged In
  1 Hidden
  76 Guests

629 Playing Online
  100% NWN
  98% NWN: SoU
  100% NWN: HotU

305 Registered Guilds

9,051,514 posts in forums

Newest Forum Topics:
1. These forums are now closed (NWN 1: Scripting)

2. These forums are now closed (NWN2: Guilds and Registry)

3. These forums are now closed (BioWare News Discussion)

4. Can you level items? (NWN 1: Scripting)

5. Thank you! (NWN 1: Scripting)