metin2united
Ikarus_

[RELEASE] Setting Drop via Mysql Tables (instead of buggy txt)

31 posts in this topic

14 hours ago, OtherChoice said:

Oh I see, thank you for your time and collaboration.

Regards

And about cache sharing, we could make that but then we need to use method of unconcurrency to make sure the cores access to memory one for time. To make this caching system is useless if done just for this system. it make sense only if you want a big shared cache to use for every game stuff.

When ymir coded this game, the cache sharing wasn't a standard method, so they decided to use the socket between cores to send "cache part" to other cores, and to make a different cache for every core. When i say cache i mean a method to store info, so about your last question, yeah the best way is to allocate the cache in the heap because there is enoght memory space.The stack relative to heap can allocate directly when the compiler compile the program but the stack size is very limited, the heap can allocate a lot of memory without problem but the allocation is a dynamic allocation so the performaces during the allocation will be smaller.

 

Share this post


Link to post
Share on other sites

Yeah after looking deeply into the code it was pretty clear.

I think the best way to achieve what I want, have every core read (only) a said memory region without refactoring everything is to use db to broadcasts pointer to vector of pointers to game binary instances.

1 hour ago, Ikarus_ said:

And about cache sharing, we could make that but then we need to use method of unconcurrency to make sure the cores access to memory one for time. To make this caching system is useless if done just for this system. it make sense only if you want a big shared cache to use for every game stuff.

When ymir coded this game, the cache sharing wasn't a standard method, so they decided to use the socket between cores to send "cache part" to other cores, and to make a different cache for every core. When i say cache i mean a method to store info, so about your last question, yeah the best way is to allocate the cache in the heap because there is enoght memory space.The stack relative to heap can allocate directly when the compiler compile the program but the stack size is very limited, the heap can allocate a lot of memory without problem but the allocation is a dynamic allocation so the performaces during the allocation will be smaller.

 

 

Share this post


Link to post
Share on other sites

Hey @Ikarus_  thank you for the release Buddy im using it but

you cant place in probability Point numbers. e.g.: prob: 1.5 (This is very important :S)

 

Share this post


Link to post
Share on other sites
22 minutes ago, Syriza said:

Hey @Ikarus_  thank you for the release Buddy im using it but

you cant place in probability Point numbers. e.g.: prob: 1.5 (This is very important :S)

 

the drop tables takes by default chance on 1/1000 (so to make chance 0.1% just add 1 as number)
you can change the scale to make chance on 1/10.000 or 1/100.000 by changing the number in length.h DROP_SCALE_TABLE

so you can for example make the drop scale on 10.000 and to make 0.01% chance you need to insert in table 1 as number
if you need 0.001% chance , you can change drop scale on 100.000 and then you need to insert in table 1 as number

warning
max drop scale is 1.000.000 (if you put number > the game automatically reduce it)  because ymir using milions as scale to make drop random numbers.

 

  • Thanks 1

Share this post


Link to post
Share on other sites
vor 48 Minuten schrieb Ikarus_:

the drop tables takes by default chance on 1/1000 (so to make chance 0.1% just add 1 as number)
you can change the scale to make chance on 1/10.000 or 1/100.000 by changing the number in length.h DROP_SCALE_TABLE

so you can for example make the drop scale on 10.000 and to make 0.01% chance you need to insert in table 1 as number
if you need 0.001% chance , you can change drop scale on 100.000 and then you need to insert in table 1 as number

warning
max drop scale is 1.000.000 (if you put number > the game automatically reduce it)  because ymir using milions as scale to make drop random numbers.

 

 

ahhh thank you! indeed it is thousand times better then working on those shitty text files. :)

 

 

Would be sick if we can get mob_drop_item & Special_drop_item converter 

 

edit: i have a improvement, how About a map_index column at the tables? example: Sword+9 is only dropable in map_index 41

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

  • Recently Browsing   0 members

    No registered users viewing this page.