![]() |
¿Program for NPCData Management?
Hi. I need an NPCData.txt manager program, that can import that data to an excel file (or such) and back, for easier debugging of the last mentioned file. I've failed to find such program, and i recurr to your knowledge.
If someone has one, please share it :p. Oso |
You can open it in Excell already, if you got your "tabs" right... Save it as ANSI for easier access...
|
Ok, my 2º question then: how do i tabularize a TXT? I have it kinda mixed up (tabs and spaces), and want it to make it "all tabs", for excel reading :p. I tried using the "spaces to tabs" of UltraEdit32, but it didnt affect all spaces (kinda left it "half with tabs, half with spaces" xD). And doing it by hand isnt something that appeals to me either.
Oso |
Now here''s something interesting... You can save it tab delimited, if you got your spaces right.
You can also do a find and replace, check the web on that... (me thinks, find: " {2,}" and replace: "^t") Note: there's a <space> between the " and {... |
Other problem: When i save from tabs to spaces, it counts the tab not as 1 space, but rather like 2-3 spaces (depends). So i end up with a file separated by spaces, but not "uniform spacing" xD.
Well, ill work something around. If someone knows, im here all week xD. Oso |
Yeah, you can use the texteditor (ex: C++ sdk) to replace tabs to spaces and the other way around in the advanced menu from find/replace...
Or.. Someone can figure it out in php... ;) |
Quote:
Oso |
Generally speaking, trying to use a TAB key in the replace dialog simply makes your cursor go onto the next field (or button) of the dialog. So you can't just type in a tab...however, you can copy and paste a tab in there ;)
It's simple to use notepad or wordpad (wordpad is a little faster when dealing with large files) and do a replace, type in a space on the find field and paste a tab in the replace field. It should work ;) I do it all the time. However, if you had manually typed more than one space and now you wish to merge consecutive spaces in 1 tab, you have to do something a bit differently. Here is what I suggest: Run MS Excel Choose File->Open and open the npcdata.txt file in the text import wizard that will open, check the following boxes: 1) space delimited 2) tab delimited 3) Treat consecutive delimiters as one. Now you will be able to view things nicely ;) Once done, you can save it as a tab delimited text-file (I'd recommend you make a backup of the original first...just in case). The game server will still be able to read the resulting file and you will have automatically fixed all your spacing problems for your fields ;) BTW, I plan to make an import program to pput this file into SQL server and back. SQL server is great for searching and quickly finding info (if you know some SQL), and it provides a table-like interface for the results, similar to excel, but with filtering ;) Personally, I find editting the SQL much easier than editting the txt files! I will do the same for some of the other files, but for none of the patch-files. I'm quite busy nowadays, but I'll let you know when I have it ready ;) |
| All times are GMT. The time now is 21:46. |