Post Reply 
 
Thread Rating:
  • 0 Votes - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
How WS's Upgrade Weapon calculation works ?
Author Message
gianluca280395 Offline
Starved from coding
***

Posts: 183
Joined: Apr 2015
Post: #4
RE: How WS's Upgrade Weapon calculation works ?

The hercules files are free for anyone to download. I can upload the skill files if you want.

Code:
            per = status->get_refine_chance(ditem->wlv, (int)item->refine) * 10;

            // Aegis leaked formula. [malufett]
            if( sd->status.class_ == JOB_MECHANIC_T )
                per += 100;
            else
                per += 5 * ((signed int)sd->status.job_level - 50);

            pc->delitem(sd, i, 1, 0, DELITEM_NORMAL, LOG_TYPE_OTHER); // FIXME: is this the correct reason flag?
            if (per > rnd() % 1000) {

I won't copy the whole code here because its too long, but if your per value (which is the base success rate for this weapon level/refine plus your bonus based on job) is greater than a random value between 0 and 999, then you have success

chars:
Crazy Bandit - Stalker
Nurelion - Creator
(with his amistr Gobball :3)
Sarcedos Signat - High Priest
Rulindil - Star Gladiator
[Image: code_monkey_coffee_mug-ref73810428c94d21...pe=content]
04-01-2017 08:58 AM
Find all posts by this user Quote this message in a reply
Post Reply 


Messages In This Thread
RE: How WS's Upgrade Weapon calculation works ? - gianluca280395 - 04-01-2017 08:58 AM

Forum Jump: