View Full Version : [SHARE] NPCDATA Drop Quantities Editor
I just finished writing this utility not to long ago, it's purpose is to increase the drop quantities of basic crafting components to allow a crafting community to actually exist.
The formulas the program uses are explained in the readme.
I have not tested this on a production server as I do not run one, but I have downloaded 2 different NPCDATA.TXT files that claim to be C4 official and the tool has performed flawlessly on them. This was written for the admins of a server I play on so that they could solve lack of materials issues on a 7x server.
A side note, this was written quick and dirty so if you try to break it, you probably will (i.e. by entering text instead of a number in the modification factor boxes).
The source code is included, which has the makings of a pretty decent NPC class in it.
This utility could do alot more if I have the time/motivation to update it.
The source code is included.
You do need .Net Framework 2.0 (http://msdn2.microsoft.com/en-us/netframework/aa731542.aspx)
You are free to use/distribute/modify this program as long as the source code is included or made available on the same download page as the modified program.
Enjoy! Comments welcome!
****Updated****
-v0.5
Forced Program to use English (United States) Regional Settings.
This should clear miscellaneous reports of errors interpreting stings.
The problem is that .Net tries to use local settings and in some
areas ',' and '.' mean very different things.
-v0.4
Added Progress Bar
Added Multiply Formula
-v0.3
Added Ignore formula option.
Prevented input of text into Modification Factor boxes.
Increased error message verbosity to help end user check for properly formatted
NPCDATA. Error message should display the NPC where the error occurred.
Started come minor code cleanup & commenting.
Included EULA in package.
-v0.2
Fixed issue in normalize option that would allow a quantity of 0 to be written.
Вложения из исходного сообщения (сами файлы в копии отсутствуют):
NPCData QE v0.5.zip — 96261 байт
l2serverfull
16.12.2006, 11:10
is possible dell all Mats in npcdata ? ... help me
l2serverfull
16.12.2006, 11:15
OMG thxxxx lot :D
i did a bit more testing and found an issue w/ normailize option.
It was a logic error on my part, I guess not enough caffine while coding ;p
DevilsAssociate
16.12.2006, 19:19
nice job
thanks for the share
Excellent! Thanks a lot.
Good work!
scrap512
17.12.2006, 22:02
thank you very much !
It creates a 2kb file, I changed NPCdata to text because it errors in ANSI what am I doing wrong?
Sorry, but last pack no good.
Components file in unknown regional code, and Main.vb empty 0 kb.
It creates a 2kb file, I changed NPCdata to text because it errors in ANSI what am I doing wrong?
Keep it unicode, no need to convert it.
Additionally, if that does not solve your issue examine the NPC that it spits out the error for. Chances are it's improperly formatted. TABS between values, not spaces.
Sorry, but last pack no good.
Components file in unknown regional code, and Main.vb empty 0 kb.
main.vb is 0kb.
main.designer.vb has the code in it.
you must have edited the components file. it hasn't changed since v0.1 if you do edit it be sure to save it as unicode.
hmm IM getting this errors.. tried all formulas.. my npcdata is c4 retail 1x
.. no tabs.. no spaces.. only 2kb file created..
btw this error only when its in default L2 format (larger filesize) ..
when I convert to smaller filesize (unicode to ansi ?? ) im getting no error but program freeze.
latest version work OK - Im glad to help you to find where was problems :-)
Between [gremlin] and level=1, is that a space or a tab?
I just tested the rar you posted and it processed fine.
Maybe you need to be more patient?
It did take almost a full 10 seconds on my Athlon FX 60 w/ 4 GB Ram....
All i did was extract your file, load it in and pick an output file and ran it w/ default settings.
Keep in mind that it is parsing through an 18 meg file.
When the hour glass is there, it's working on your file.
I plan on adding a progress bar eventually, but I haven't had the time yet.
Maybe after the New Year
Ok I worked w/ rodier a bit last night.
He's getting his error on 2 different boxes w/ different CPUs and Operating Systems.
However his language settings are not English - US, I have not tested this on anything other than English - US, but he was going to change the settings and reboot and get back to me on the results.
Updated v0.4!
Merry Christmas!
Osito2Dancer
25.12.2006, 14:12
Very good share, thanks for it. Its really good, but i think i found a bug: for anyone who used this, please check the "adquire_exp_rate" of the new NPCDATA.txt. I ran this program on the PP-IRC C4 Release, and got the adquire_exp_rate modified by this standard:
Original: adquire_exp_rate = xx.xx (for a lvl 1 gremlin, the 1ºst mob)
Parsed One: adquire_exp_rate = 2939 (the same mob, got the "." on "xx.xx" deleted)
I used "Multiply" option, but just tested it out with Default one. Be careful about this.
Atte
Oso
Please post the original NPC data so i can test.
I tested several versions with the new multiply formula with no descrepancy.
Thanks.
Very good share, thanks for it. Its really good, but i think i found a bug: for anyone who used this, please check the "adquire_exp_rate" of the new NPCDATA.txt. I ran this program on the PP-IRC C4 Release, and got the adquire_exp_rate modified by this standard:
Original: adquire_exp_rate = xx.xx (for a lvl 1 gremlin, the 1ºst mob)
Parsed One: adquire_exp_rate = 2939 (the same mob, got the "." on "xx.xx" deleted)
I used "Multiply" option, but just tested it out with Default one. Be careful about this.
Atte
Oso
Both you and Rodier seem to have an issue with the same value. I really think this might be a localization issue. In your country do they use . for a decimal point or , ?
Thanks.
Ok, for those of you that are having trouble and you NPC data is good, it is your Regional Settings. If you set your Regional settings to English - US you should be fine.
I think I have fixed this in the next release, However I'm far to tired to publish it right now.
I'll post it later.
I'd really like someone that was having problems to message me though so it could be tested a bit further.
I did some testing myself with my regional settings set to places that do not use . to denote fractional numbers and I'm no longer getting errors, but I'd feel better about releasing if it actually field tests ok for someone.
-Thanks.
Updated v0.5
Should fix errors caused by regional settings.
So has anyone found this thing useful?
Can you think of any other features to add?
Please post feedback. Thanks!
nice work khelben,i tried it out but unfortunately it bugged my npcdata.
it made all mobs do very high damage like 15000 damage and u couldnt kill them.
nice work khelben,i tried it out but unfortunately it bugged my npcdata.
it made all mobs do very high damage like 15000 damage and u couldnt kill them.
Thanks for the response.
A couple questions for you.
1. Were you using the latest version, v0.5?
2. What are your regional settings in windows?
3. If you change your regional settings to English - US do you still experience the issue?
latest version v0.5 work perfect with regional english - cz settings :-)
Thanks for the response.
A couple questions for you.
1. Were you using the latest version, v0.5?
2. What are your regional settings in windows?
3. If you change your regional settings to English - US do you still experience the issue?
World standart is "." for decimal point.
Actually in some countries they use "," case in point, Greece and Czechoslovakia
It should not rely on functions using regional settings (most Delphi ones) or should replace ',' to '.' before string-to-float conversion.
P.S. We (in Poland) use , as decimal point.
Actually in some countries they use "," case in point, Greece and Czechoslovakia
Russia use it too as default, but all code developers must use "." in regional settings. Or... you need made additional code for compatible. .NET support regional checking and converations.
Or easy - do replace "," to "." for drop before working.
Yeah, .net by default uses the end users regional settings. I have never really made anything that was used internationally before so I did not know of this issue. The current v0.5 release uses .net to force US English settings within itself.
This appears to have taken care of the issues international "," users were having.
JamesDean
03.01.2007, 05:32
Nice share! Thanks, our server really needed this.
Nice share! Thanks, our server really needed this.
Glad this could help!
Osito2Dancer
03.01.2007, 21:03
All is now good. Thanks for the share, you deserve a A++ :3.
Oso