Character Modifier version 0.5 - Plugin for the Abyss 404 Server Log Command System ----------------------------------------------------------------------------------- 1. AUTHOR: ----------- Andreas Fugl (aka Cirrus) (Visit the Nordock Custom Server boards for contact: http://p211.ezboard.com/bnordockcustome ) 2. CREDITS: ------------ This plugin uses code and functions from the "Character Deleter Demo Plugin" and "Abyss 404 Subrace System" written by Andrew Wang (aka Red Golem). Without his examples and well-written code, this plugin surely wouldn't have existed. Make sure to visit the original home of these magnificent systems on http://abyss404.d2g.com Credits also go to Zakaron for bringing up the original idea for a Head Modifier, and Tomoko for invaluable testing. 3. INTRODUCTION: ---------------- The Character Modifier Plugin is a collection of internal NWScript's and external Java functionality for letting a player modify a Player Character in a server vault without the need for direct access. The plugin uses the Abyss 404 Server Log Command System and parts of the Subrace System, so WITHOUT THE ABYSS 404 SERVER LOG COMMAND SYSTEM, THIS WILL NOT WORK! As of version 0.5 the following properties on a PC can be changed: - Change of head model - Change of hair color - Change of skin color - Change of tattoo colors - Change of voice set - Change of description These changes can be made by the player speaking to different NPC's, to which the modification dialogs are associated. It's important to keep in mind, that a player cannot in realtime see what they pick, due to the somewhat external nature of this plugin. It does NOT work like ingame armor crafting. The player must know which specific headmodel, color or voice set to choose and then the changes are carried out. This is most easily explained by outlining the modification process: 1. A player talks to the Modifier NPC 2. The player chooses whether he wants to increase, decrease, reset or speak the number directly 3. The player is now booted from the server - This forces the server to save the character 4. The NWN server now sends a command through the server log. This command includes the name of the player and the choice of the player. 5. The Abyss 404 Logwatcher picks this up, and interprets the passed values 6. The relevant external Java class is called and the modifications are done to the character. The player can now login again and the changes should be carried out. Consideration must be taken when putting this functionality in use on larger PW's. Everytime a player does a modification, he will be booted for the process to work. If this is repeated many times, the logs will literally be flooded... 4. EXTERNAL INSTALLATION: -------------------------- a. Dependencies ---------------- Make sure you have a working Abyss 404 Server Log Command System installation (at least version b8 or b9) (Reference this manual http://web.mit.edu/andyman/Public/l404_installation.html) b. Needed files ---------------- Copy the Java archive "modifier.jar" to the root of your NWN installation. c. Startup script ------------------ The Java archive "modifier.jar" needs to be included in the classpath when running the Watcher. This is done by editing the shortcut (or on *nix, probably a shellscript) for starting the watcher. Here are examples of both Linux and Windows usage which starts the console version of the Log Watcher: Linux: java -classpath /home/cirrus/nwn/l404_sr.jar:/home/cirrus/nwn/modifier.jar l404.watcher.LogCheckerThread /home/cirrus/nwn/watcher.properties /home/cirrus/nwn/logs.0/nwserverLog1.txt Windows: java -classpath c:\games\nwn\l404_sr.jar;c:\games\nwn\modifier.jar l404.watcher.LogCheckerThread c:\games\nwn\watcher.properties NOTE: Depending on the Java VM installed, the way of defining classpaths might be different. The VM I use on Linux, is the Blackdown-1.4.1. d. Setting up watcher.properties --------------------------------- Open up watcher.properties in any text editor and add the following lines to enable the new commands: #Character Modifier plugin command_headmodifier=cirrus.modifier.HeadModifier command_skinmodifier=cirrus.modifier.SkinColorModifier command_hairmodifier=cirrus.modifier.HairColorModifier command_tatoomodifier=cirrus.modifier.TatooColorModifier command_voicesetmodifier=cirrus.modifier.VoicesetModifier command_descriptionmodifier=cirrus.modifier.DescriptionModifier 5. INTERNAL INSTALLATION ------------------------- a. Import scripts and dialog files ----------------------------------- 1. Import modifier_0_5.erf into your module (There's no need to overwrite string_include, if it asks to) 2. Assign the dialogs "l404_**_mod.dlg" to NPC's. 3. Recompile your module b. Configuration ----------------- Depending on cpu and disk load, the time for the server to save a character upon boot might vary. If the character isn't saved properly before the character is booted, the java plugin might not modify the correct character. The delay can be edited by modifying the constant "TIME_NEEDED_TO_SAVE_CHAR" in the script l404_char_inc. Default is 3 seconds. c. Demo module --------------- Included in this package is a demo module, which will let you do all of the character modifications. 6. USING THE MODIFIERS IN-GAME ------------------------------- a. Head Modifier ----------------- The Head Modifier will let you either increase, decrease or reset the current index of your head number or speak the number directly through the chat. If you specify a head number that you (or others) don't have the model for, you will show up without any head. The character file format has a limit of 128 heads. The index of the head goes from 0 to 127 (both included). The scripts and Java plugins will enforce that limit. b. Hair Color Modifier ----------------------- The Hair Color Modifier will let you either increase, decrease or reset the current index of your hair color number or speak the number directly through the chat. There are 56 different colors, indexed from 0 to 55 (both included). Included with this package in the "extras" folder, is a color map which shows the colors and their associated index. c. Skin Color Modifier ----------------------- The Skin Color Modifier will let you either increase, decrease or reset the current index of your skin color number or speak the number directly through the chat. There are 56 different colors, indexed from 0 to 55 (both included). Included with this package in the "extras" folder, is a color map which shows the colors and their associated index. d. Tattoo Color Modifier ------------------------ The Tattoo Color Modifier will let you either increase, decrease or reset the the current index of either Tattoo 1 or Tattoo 2. It is also possible to speak the number directly through the chat. There are 56 different colors, indexed from 0 to 55 (both included). Included with this package in the "extras" folder, is a color map which shows the colors and their associated index. e. Voice set Modifier --------------------- The voice set modififer will let you pick a new voice set for your character. The voice set is indexed with a number into the "soundset.2da" (included with this package for viewing purposes). The player is able to pick all sounds available in the game, both "real" player soundsets and critter sounds. The amounts of soundsets varies depending on HAK's (The author has about 450 soundsets), and thus there is no fixed limit. Nonetheless, have I set a limit of 1000. This is easily changeable through the NWScript. d. Description Modifier ------------------------ The description modifier will let you provide a new description for your character, which is spoken through that normal chat. Following considerations must be taken however: 1. Spoken description should be below 450 characters. 2. Spoken description should not contain the character "-". Descriptions larger than the 450 char size will be brutally cut off, and "-" will be replaced by whitespace (" ").