Informations
Jump to content

Lorem Ipsum...

Click to Dismiss this Notification
Ładowanie danych...

Recommended Posts

This guide will walk you through the process of configuring your database to support the NoTXT feature, which allows you to switch between using text files and SQL for your game asset management. Follow these steps carefully to ensure a smooth implementation.

Step-by-Step Configuration

Step 1: Modify Main.cpp

First, you need to edit the Main.cpp file located in the "db/src" directory. Add the following code snippet beneath your existing includes at the top of the file:

 
This is the hidden content, please

Step 2: Update the Disable Hot Backup

Next, locate the declaration for int iDisableHotBackup; and add the following lines directly underneath:

 
This is the hidden content, please

Step 3: Adjust ClientManager.h

Open the ClientManager.h file within the "db/src" directory. Replace these lines:


    
This is the hidden content, please

Step 4: Update ClientManagerBoot.cpp

In the ClientManagerBoot.cpp file, insert the following line at the top:

 
This is the hidden content, please

Step 5: Modify InitializeMobTable

 

This is the hidden content, please

    

Apply the same replacement for the InitializeItemTable method as well.

Step 6: Update InitializeTables Logic

 

This is the hidden content, please

    

Step 7: Implement SQL Functions

Finally, add the following functions to your file to facilitate SQL initialization:

 
This is the hidden content, please

Step 8: Create the SQL Table

Next, you need to create the item_proto_table.sql file with the following SQL commands:

 
This is the hidden content, please

You can alternatively use the "Design table" feature in Navicat to adjust your item_proto, just remember to rearrange the vnum_range column to be the second column after vnum.

Step 9: Update Configuration

Lastly, ensure that your configuration file (conf.txt) has the following line added:

 
This is the hidden content, please

This line sets the system to use SQL instead of text files. A value of 0 would switch back to the TXT format.

Acknowledgments

Special thanks to the contributors for sharing invaluable code snippets.

Change Log

  • Implemented NoTXT feature by switching from TXT file reading to SQL.
Link to comment
Share on other sites


Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.

spacer.png

Disable AdBlock
The popup will be closed in 5 seconds...