nvault to fvault
Hi guys, is it possible to convert nvault file to fvault(txt) file, because u have some levels from users in that file! And reason is fvault making txt file easy to edit! Thanks in advance
|
Re: nvault to fvault
Nop.
|
Re: nvault to fvault
Well, you can use the nVault editor who bugsy upload to edit the .vault file and you will not have to use fvault
https://forums.alliedmods.net/showth...81917?p=581917 |
Re: nvault to fvault
Of course you can.
I don't know the official format of the file, but you can definitely find it out by looking at the source of the module. I just took the file in Bugsy's post and read it in a hex edit plugin for NP++. Here's what I got from that... Some starting values: 54 4c 56 6e 00 02 (Empty file) 54 4c 56 6e 00 02 05 00 00 00 (Bugsy's file with 5 entries) Don't know the meaning of the first six bytes. Some sort of header or perhaps version code. The 7th byte is obviously the number of entries. Most likely it's a long value, so the last 4 of those bytes. 51 bf a8 47 07 1d 00 This is the index for the first entry. Starts of with a long containing the timestamp in UNIX time format. Then it is most likely a byte that tells you the length of the key string. After that either a byte or a short telling you the length of the value. To find out which just try storing a string longer than 255 characters. I'm putting my money on short. This translates into: 47a8bf51: 1*202*241*361 (2008-02-05, 20:56:01 in european format) 07: 7 1d (or 001d): 29 Then the data... 45 6e 74 72 79 20 31 54 68 69 73 20 69 73 20 74 68 65 20 76 61 6c 75 65 20 66 6f 72 20 65 6e 74 72 79 20 31 This translates into: "Entry1This is the value for entry 1" "Entry1" contains 7 characters. "This is the value for entry 1" contains 29 characters. By using the values from the index you know exactly where to split this string and where to end it. Then the pattern starts over with a new index. 53 bf a8 47 07 1d 00 and so on... So basically, you can read it like any file. Interpret these values using some basic code and just save them in the new fvault. 100% doable directly in PAWN if not familiar with other programming languages. And it's not even that hard. If someone doesn't beat me to it, I'll definitely write a code for you this weekend. (Perhaps it has already been made?) |
Re: nvault to fvault
Quote:
|
Re: nvault to fvault
@Black Rose, can't you just use nvault_util and loop through all entries?
|
Re: nvault to fvault
Never used it. Didn't think of it.
Yes you can. |
Re: nvault to fvault
Here ya go. It would need some time to convert, so the server will hang for some time depending on your vault size. It's normal.
Code:
|
Re: nvault to fvault
Lol this working perfect thx a lot guys :D!
|
Re: nvault to fvault
Note that this will not transfer the timestamp.
|
| All times are GMT -4. The time now is 18:30. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.