Customlog – editable player logbook (v1.0.2)
The Customlog – editable player logbook adds a new player logbook to the game that allows the player to write, delete and manage messages in certain categories. It also provide a means for other scripters to write messages from their scripts to the Customlog.
Index
Information for players: installation, function, compatibility
Download and Changelog
Information for scripters
1. The installation
Download the script archive and extract it to your game directory.
For X3: Terran Conflict, by default this will be either
C:\Program Files\Egosoft\X3 Terran Conflict or
C:\Program Files\Steam\steamapps\common\X3 Terran Conflict
For X3: Albion Prelude, by default this will be
C:\Program Files\Steam\steamapps\common\X3 Terran Conflict\addon
Afterwards all files of the archive - they are listed below - should be placed in their respective folders in the X3TC directory or its "addon"-folder.
Note: Just to be on the safe side you should also make a backup of your savegames before installing the script. The standard directory for the saves is
C:\Users\[USERNAME]\Documents\Egosoft\X3TC\save for X3TC or
C:\Users\[USERNAME]\Documents\Egosoft\X3AP\save for X3AP
(C: is the letter for your OS partition.)
2. The function
You can open the Customlog over the command console of any ship or station by selecting the Customlog entry from the Additional Ship Commands section. If you do so, the Customlog main menu will be opened.
Customlog main menu
The main menu displays all of the available categories in your Customlog as well as options to manage these.
(Click to enlarge.)
- Add new message
Selecting this option, you are asked to enter a message into a text field. Afterwards you have to select a category from the available categories, which your message will be added to. If you want to add the message to a new category press 'Esc' in the menu to select a category and you're asked for a new name. - Add new category
Selecting this option, you are asked to enter a name for your new category. If a category with the same name already exists, you are asked, whether you still want to use that name. If so, the category is created. A new category will always be added to the end of the category list. - Change Position of category
With this option you can change the position of the category in the category list. Select this option and you're first asked to select the category you want to move and secondly for its new position within the category list. - Delete category
Selecting this option, you are asked to select a category from the category list, which will then be deleted. Before the deletion is executed, you will be asked for confirmation again. Please note that deleting a category will delete all messages in it too. - Options
Here you can set certain options, which are then applied to the main menu and the different sub menus. Simply click on one option to trigger the input fields or, in case of Yes/No-fields, to switch to the other available option.
(Click to enlarge.)
(Please Note: A detailed explanation of the different options can be found in the Customlog_Readme.pdf file, which is located in the Documents folder.) - Close
This closes the Customlog. (The same is achieved by pressing 'Esc'.)
Category menu
The category menu displays all of the messages of the selected category and provides options to manage a number of these messages.
(Click to enlarge.)
- Add new message
Selecting this option, you are asked to enter a message into a text field. This message will be added to the currently selected category then. - Change category
This allows you to easily switch to another category without going back to the main menu. - Rename category
Selecting this option, you are asked to enter a new name for your category. If there is already a category with this name, your asked whether you still want to use it. - Write all messages to logfile
This will write all messages of the current category to the logfile with the id specified in the Main menu options. Before this command is executed, you will be asked whether you want to append the messages to the existing file. If you click ‘Yes’, and a logfile wih the respective id already exists, the messages will be added to the existing messages in the file. If you click ‘No’, all messages that are already in the logfile will be deleted and replaced with the messages from the current category. In both cases if a file with the respective id doesn’t exist already, it will be created. You will also be asked, whether you want to delete all messages from the Customlog category, once they have been written to the logfile.
The logfile can then be found under
C:\Users\[USERNAME]\Documents\Egosoft\X3TC or
C:\Users\[USERNAME]\Documents\Egosoft\X3AP
(C: is the letter of your OS partition.) - Delete all messages from this category
This will delete all messages from the current category. Before this command is executed, you will be asked for a confirmation. - Delete <amount> of newest messages
This will delete the stated amount of newest messages (i.e. those that were added recently to the category). The amount can be changed in the Main menu options. Before this command is executed, you will be asked for a confirmation. - Delete <amount> of oldest messages
This will delete the stated amount of oldest messages (i.e. those that were added at first to the category). The amount can be changed in the Main menu options. Before this command is executed, you will be asked for a confirmation. - Back to Main menu
This brings you back to the Main menu. (The same is achieved by pressing ‘Esc’.)
In the message list each message is displayed together with the time it was written to the logbook infront. If the message is too long to be fully displayed in one line, only the first part of it will be displayed. You can read the whole message in the Message menu, which you reach when clicking on the message entry.
Message menu
The message menu displays the whole message and provides options referring to it.
(Click to enlarge.)
- Edit message
This will open the Edit message menu, which lets you edit the message.
(Click to enlarge.)
First select the line from the original message you want to edit. Afterwards you can enter the changed line. Meanwhile, the original message is displayed as a subtitle. If you’re happy with your changes, select the ‘Apply changes’ option to save your changes and return to the Message menu.
Please note: Due to the size limitation of custom menus, long messages will be separated into several lines. You cannot edit those long messages as a whole, but enter the changes per line instead. There’s also no possiblity to have the text already entered in the text input field, so you basically have to retype the whole line, even if you just want to correct a typo or the like. - Move message to other category
This lets you move the message to another category. Therefore you will have to select the destination category from the list of available categories. If you press ‘Esc’ or select the current category the message is stored in, the message will stay where it is. - 3.Write message to logfile
This will write the message to the logfile with the id specified in the Main menu options. Before this command is executed, you will be asked, whether you want to append the messages to the existing file. If you click ‘Yes’, and a logfile wih the respective id already exists, the message will be added to the existing messages in the file. If you click ‘No’, all messages that are already in the logfile will be deleted and replaced with the current message. In both cases if a file with the respective id doesn’t exist already, it will be created. The logfile can then be found under
C:\Users\[USERNAME]\Documents\Egosoft\X3TC or
C:\Users\[USERNAME]\Documents\Egosoft\X3AP
(C: is the letter of your OS partition.) - Delete message
This will delete the message. Before this command is executed, you are asked for a confirmation. - Back to category menu.
This brings you back to the Category menu. (The same is achieved by pressing ‘Esc’.)
Further Information
Coloring Texts
When adding or editing messages single words or even the whole message can be coloured. Therefore there are a number of tags available, which are similar to HTML or BB-Code tags. The color tags consists of an opening and a closing color tag and a color code: <c=F></c>. The following color codes and colors are supported:
(Click to enlarge.)
The color tags can be used on different ways:
1. Coloring a single word
The word, which should be colored, is placed between the opening and the closing color tag.
(Click to enlarge.)
(Click to enlarge.)
2. Coloring several words or a whole line.
All words between the opening color tag and the next closing or opening tag or the end of the line will be colored in the specificed color.
(Click to enlarge.)
(Click to enlarge.)
(Click to enlarge.)
(Click to enlarge.)
3. (In)compatibilies and Limits
This script is compatible to all X3: Terran Conflict versions equal or greater than 2.5 and to all X3: Albion Prelude versions equal or greater than 1.0. It is also compatible to all scripts and mods that do not use the same command slot (COMMAND_TYPE_SHIP_53) and the same text file / page id (7330).
Since the Customlog uses custom menus to provide its functions, there are several limitations – especially with regards to the display and input of text. I will try to improve the functions, where possible. However there are also some things, like the input of text, which are simply limited by the script engine and cannot be further improved. Apart from that, I tried to keep the amount of menus – and this way also the amount of clicks to reach a certain function – relative low, while still providing more functions than the normal logbook.
What this script won’t do is redirecting all messages that are written to the normal player logbook to the Customlog. Only messages from scripts that support the Customlog and of course your own messages that you add over the Customlog interface will be written to the Customlog.
I know that there is a (driver related) bug with AMD graphics cards, which causes slow downs in menus with lots of entries. Since I do not have a current AMD graphics card, I cannot test, in which way this bug also applies to this script. If you experience slow downs, I suggest to reduce the number of displayed messages in a menu. (Please see the Customlog main menu options section for more info about this.)
4. Known bugs
- - None at this point (v1.0)
- - Add function to move all messages from one category to another
- Add function to sort messages
- Improve display of messages
- Improve edit message function
- Clean-up work
Open the language specific text file of the Customlog for the language you are playing 7330-L0xx.xml (xx is representing the specific language code, 49 = German, 44 = English) with any text or xml editor. The file can be found in the t folder of your game directory.
For X3: Terran Conflict, by default this will be either
C:\Program Files\Egosoft\X3 Terran Conflict\t or
C:\Program Files\Steam\steamapps\common\X3 Terran Conflict\t
For X3: Albion Prelude, by default this will be
C:\Program Files\Steam\steamapps\common\X3 Terran Conflict\addon\t
Change the ‘uninstallation variable’ from 0 to 1 and save the file. Afterwards start/load the game.
The script will ask you, whether you really want to uninstall the Customlog. You’re also asked, whether you want to backup the messages from the Customlog or not (i.e. write them into the specified logfile). Afterwards the Customlog will be deleted and you receive an incoming message about it.
Now go to the scripts.uninstall folder in your X3TC directory or its addon folder (for X3AP) and double click on the uninstall.X2I.customlog.bat. This will remove all Customlog files from the folders Documents, scripts and t. Now you can delete the uninstall.X2I.customlog.bat and if it is the only file in the scripts.uninstall folder, you can delete this folder too.
7. Credits
- EGOSOFT for the X-Series and the Script Editor
SS_T for a reliable hosting place on xdownloads