Thread: Mercenaries
View Single Post
  #237  
Old 04-06-2013, 01:41 PM
Armm
Sarnak
 
Join Date: Feb 2013
Posts: 70
Default

One bug and a few things i dont understand.

I buy a level 50 J2 tank merc, has base stats like DB using #showstats. If i buff him with "Swift like the wind" spell number 172 which to my knowledge has no stat or resist buffs in it, then the merc has around 20 added to str,dex,40 to sta, 20 to agi, and resists are bumped up 60? When you suspend and restore the merc MOST of the time the stats return back to normal. Picture is below demonstrating me buying the merc, #showstats, buffing-showstats, suspending and bringing him back - showstats. I totally don't understand this.

Why do the mercs have so much attack? The values in the database don't match up with stats shown in game, and the ATK stats in the database are SKY high.

If i am understanding the code in attack.cpp right below then its looking for merc ATK which doesn't seem to be the same as in the database(which is even higher) Is it using CalcATK() from merc.cpp?? If so does then CalcATK also adds strength and skill to come up with its number?? If CalcATK does that then isnt Str and Offense added twice when it hits the code below??

I am trying pretty hard to balance things for my server, and the ground keeps shifting under my feet every time i solve one problem. Any information is apprecaited. Thank you.

Code:
if(attacker->IsClient())
		{
			attack_rating = (attacker->CastToClient()->CalcATK() + ((attacker->GetSTR()-66) * 0.9) + (attacker->GetSkill(OFFENSE)*1.345));
		}
		
		else
		{
			attack_rating = (attacker->GetATK() + (attacker->GetSkill(OFFENSE)*1.345) + ((attacker->GetSTR()-66) * 0.9));
		}


Reply With Quote