Go Back   EQEmulator Home > EQEmulator Forums > Development > Development::Bug Reports

Development::Bug Reports Post detailed bug reports and what you would like to see next in the emu here.

Reply
 
Thread Tools Display Modes
  #1  
Old 06-22-2009, 09:56 PM
ChaosSlayerZ's Avatar
ChaosSlayerZ
Demi-God
 
Join Date: Mar 2009
Location: Umm
Posts: 1,492
Default NPC Dual Wield

I have a suspision that NPC dual wield skill takes a bit too long to build.

I have tested this on warrior NPCs who were wielding 1hs in Primary and 1hb in Secondary and put them into extensive fighting.

By logic at lev 30 your skill in DW should be at skill 150 - which is significant.
I have tested this with npcs from 30 to 35 level range for over an hour and have not seen a SINGLE 1hb attack message.

It was not until I set npc to lev 45 before they finaly started swinging the 2nd hand.
Reply With Quote
  #2  
Old 06-28-2009, 01:12 AM
AndMetal
Developer
 
Join Date: Mar 2007
Location: Ohio
Posts: 648
Default

Here's the code:

zone/MobAI.cpp
Code:
                                //now off hand
                                if (attack_dw_timer.Check() && CanThisClassDualWield()) 
                                {
                                        int myclass = GetClass();
                                        //can only dual weild without a weapon if your a monk
                                        if((GetEquipment(MATERIAL_SECONDARY) != 0 && GetLevel() > 39) || myclass == MONK || myclass == MONKGM) {
                                                float DualWieldProbability = (GetSkill(DUAL_WIELD) + GetLevel()) / 400.0f;
                                                DualWieldProbability -= MakeRandomFloat(0, 1);
                                                if(DualWieldProbability < 0){
                                                        Attack(target, 14);
                                                        if (CanThisClassDoubleAttack()) 
                                                        {
                                                                sint32 RandRoll = rand()%100;
                                                                if (RandRoll < (GetLevel() + 20))  
                                                                {
                                                                        if (Attack(target, 14));
                                                                }
                                                        } // if (CanThisClassDoubleAttack())
                                                }
                                        }
                                }
First of all, it looks like it's hard coded to be at least level 40 before we can duel wield. I honestly can't remember how this is supposed to be setup on Live, but if this is correct, it can very easily be changed to a rule.

Secondly, I honestly am not understanding why we're subtracting a random float with a value between 0 & 1 from our probability and checking to see if it's less than 0. Using your examples, that would put the probability somewhere between -0.55 & 0.45 for level 30 and between -0.325 & 0.675, which actually has an inverse affect on our probability to duel wield. Effectively, at level 70, the probability would be between 0.05 & 1.05, which will never be < 0.

Unless I'm misreading something, we should just be able to flip the check to > 0.

On a side note, if this is effectively broken, this could have a potentially large impact on DPS NPCs are dealing out at higher levels.
__________________
GM-Impossible of 'A work in progress'
A non-legit PEQ DB server
How to create your own non-legit server

My Contributions to the Wiki

Last edited by AndMetal; 06-28-2009 at 09:15 AM..
Reply With Quote
  #3  
Old 06-28-2009, 12:30 PM
ChaosSlayerZ's Avatar
ChaosSlayerZ
Demi-God
 
Join Date: Mar 2009
Location: Umm
Posts: 1,492
Default

well the 40+ cap is very strange.
on LIVE NPC were always MUCh stronger than players, and with levels they were getting stronger and stronger.
Why would npc warrior be getting DW 25 levels after players?

Not to mention this creates a strong disbalance between melee classes who reply on DW vs those who don't. For example since Paladin/SK doesn't use DW, they is not hampered by this, but their spells keep growing for 20 levels, while npc warriors/rogues/monks/rangers are lagging 20 levels behind
Reply With Quote
  #4  
Old 07-03-2009, 09:38 PM
ChaosSlayerZ's Avatar
ChaosSlayerZ
Demi-God
 
Join Date: Mar 2009
Location: Umm
Posts: 1,492
Default

I have been thinking about this some more, and there is yet another issue directly related.

Pets are essentialy npcs, and if npcs cannot DW untill 40+, neither can pets. (tested this separatly as well)
On LIVE lev 24 necromancer pet was first pet who could DW - this was well known fact as for all necros it was an important level to achieve (the lev of pet itself is only 22) - which means that all npcs should in fact very closly match player level to get the skill.

So here is one definite reason why curent 40+ cap on DW for npc is very wrong for no apparent reason.

Could we please have this corrected?
Reply With Quote
  #5  
Old 07-04-2009, 01:30 AM
AndMetal
Developer
 
Join Date: Mar 2007
Location: Ohio
Posts: 648
Default

Can anything other than the level 24 pet or Monks (NPC-wise) duel wield at 24? Or is the pet a special case?
__________________
GM-Impossible of 'A work in progress'
A non-legit PEQ DB server
How to create your own non-legit server

My Contributions to the Wiki
Reply With Quote
  #6  
Old 07-04-2009, 02:55 AM
ChaosSlayerZ's Avatar
ChaosSlayerZ
Demi-God
 
Join Date: Mar 2009
Location: Umm
Posts: 1,492
Default

OK I don't have any actual (current) LIVE access but I am prety sure all npc warriors (most of npcs on LIVE are warriors) could dual wield from lev 15 (or whenever warriors get their DW skill)

A research into older days "npc secrets" postings could help in this regard.

BTW another thing is, I read here
"//can only dual weild without a weapon if your a monk"

seems wrong...

Npc should ALWAYS DW even wihout the weapons (hey players can) - think about it that 99% of of all npc spawn wihout a weapon of any kind (specialy non humanoid types , like animals) - if none of them could DW - this would cut their DPS in half at higher levels. Now I may not remember my noob days (I was too busy trying to survive rather than count how many times npc hits), but from my days camping in BoT I remember very well those 850+ quads coming from Van Krigers, complited with Kick and a Bash. And they almost never wield any weapon at all, and were not monks.

On top of that, I just remembered the Needlites in Echo Caverns. The buggers were 22-26 and absolutly 100% QUADED


Of course if you want a SOLID prove, we have to bug someone with LIVE access to go and test this. But I am 99.99% sure that no way an NPC warrior could not DW when a player allready could. Just didn't work this way on LIVE =)

Not to mention, again, as I said before, a huge disbalance which exists between warriors/rogues who only fight at HALF dps, while paladins/sk who don't get the skill, stil getting steady rise of their combat potential via spells

More on pets- I doubt very much pets use formula much diffirent from actual npcs, and as I said, both necro and mage pets could DW from pet level 22+
And I very sure BST pets can too, it just harder to prove without parsing since you don't actualy see them swinging/wielding.

I am prety sure Trev has LIVE access (and maybe Cavedude) could verify this for us for all instances.

As a contingency plan, if you accept this, I propose to go with a "DW NPC Rule" which automaticly allows all npc of proper class and level to DW without weapons as allowed per actual class skill table in DB. Then each admin can decide how they would want this.
Reply With Quote
  #7  
Old 09-15-2009, 03:39 PM
Tharkun
Hill Giant
 
Join Date: Aug 2009
Posts: 125
Talking

I believe Chaos is correct at least as far as 40 being to high. I played a Necro that only got to 50's. I know for a fact that I had a pet that DW's while I was XP kiting in DL. Not exactly sure what level that was.

As far as quad's... that's a Special Attack in the NPC_Types Table so DW doesn't enter in to it.

Ideally I think this should be swapped to a rule, as some purists will want to have it "The it is on Live" ... which probably changed at least once per expansion...
others will not want to re-balance the NPC's
others still will think it's awesome that they can change it.

my 2cp... for what's it's worth with this exchange rate
Reply With Quote
  #8  
Old 10-15-2009, 06:42 PM
Shin Noir's Avatar
Shin Noir
Legendary Member
 
Join Date: Apr 2002
Location: Seattle, WA
Posts: 502
Default

Went ahead and tested this, taking above code and adding debug messages:
Code:
					//can only dual weild without a weapon if your a monk
					if((GetEquipment(MATERIAL_SECONDARY) != 0 && GetLevel() > 39) || myclass == MONK || myclass == MONKGM) {
						float DualWieldProbability = (GetSkill(DUAL_WIELD) + GetLevel()) / 400.0f;
						printf("Probability Before Random: %f", DualWieldProbability);
						DualWieldProbability -= MakeRandomFloat(0, 1);
						printf("Probability After Random: %f", DualWieldProbability);
						if(DualWieldProbability < 0){
							Attack(target, 14);
							if (CanThisClassDoubleAttack()) 
							{
								sint32 RandRoll = rand()%100;
								printf("DoubleAttack Check: %i, Success? %i", %i, RandRoll < (GetLevel() + 20));
								if (RandRoll < (GetLevel() + 20))  
								{
									if (Attack(target, 14));
								}
Here's a level 44 Skeletal Monk pet going at it vs. a Phaes Spider in Dragon Necropolis:

Probability Before Random: 0.740000Probability After Random: 0.646369Probability
Before Random: 0.740000Probability After Random: 0.629035Probability Before Ran
dom: 0.740000Probability After Random: 0.349394Probability Before Random: 0.7400
00Probability After Random: 0.328153Probability Before Random: 0.740000Probabili
ty After Random: 0.129569Probability Before Random: 0.740000Probability After Ra
ndom: -0.029433DoubleAttack Check: 49, Success? 1Probability Before Random: 0.74
0000Probability After Random: -0.074081DoubleAttack Check: 8, Success? 1Probabil
ity Before Random: 0.740000Probability After Random: 0.274989Probability Before
Random: 0.740000Probability After Random: 0.279689Probability Before Random: 0.7
40000Probability After Random: 0.206414Probability Before Random: 0.740000Probab
ility After Random: 0.270778Probability Before Random: 0.740000Probability After
Random: -0.111894DoubleAttack Check: 95, Success? 0Probability Before Random: 0
.740000Probability After Random: -0.108079DoubleAttack Check: 43, Success? 1Prob
ability Before Random: 0.740000Probability After Random: 0.161308Probability Bef
ore Random: 0.740000Probability After Random: 0.190362Probability Before Random:
0.740000Probability After Random: -0.156573DoubleAttack Check: 92, Success? 0Pr
obability Before Random: 0.740000Probability After Random: -0.130205DoubleAttack
Check: 34, Success? 1Probability Before Random: 0.740000Probability After Rando
m: 0.103414

Here's a parse of him on another fight, using GAmParse, it has a report showing how many attempts per sec the pet has:

With hits (this ignores kicks)
1 Attempt per sec: 11
2 Attempt per sec: 14
3 Attempts per sec: 4
4 Attempts per sec: 4

I think that implies it's quadding. :P

Next pet is a lvl 60 Earth Pet, summoned via "Rathe's Son". Initially I'll not use weapons. No dual weilding printf messages being spammed.
For simplicity sake Ijust handed him two Fine Steel Scimitars.

Here's this lvl 60 pet spam:
Probability Before Random: 0.762500Probability After Random: 0.633620Probability
Before Random: 0.762500Probability After Random: -0.076210DoubleAttack Check: 8
0, Success? 0Probability Before Random: 0.762500Probability After Random: 0.3631
96Probability Before Random: 0.762500Probability After Random: 0.266910Probabili
ty Before Random: 0.762500Probability After Random: 0.213289Probability Before R
andom: 0.762500Probability After Random: 0.495371Probability Before Random: 0.76
2500Probability After Random: 0.062588Probability Before Random: 0.762500Probabi
lity After Random: -0.093056DoubleAttack Check: 75, Success? 1Probability Before
Random: 0.762500Probability After Random: 0.241183

So he's successfully quadding too. Here's a parse result like I did on the other pet:
Once again, ignoring kicks in parser
1 Attempt per sec: 2
2 Attempt per sec: 14
3 Attempts per sec: 1
4 Attempts per sec: 1

This is non-AA'd pet just using two weapons, it is getting quads off just very rarely.


Here you go:

Code:
[Thu Oct 15 16:13:45 2009] Zekab slashes a phase spider for 85 points of damage.
[Thu Oct 15 16:13:45 2009] Zekab pierces a phase spider for 85 points of damage.
[Thu Oct 15 16:13:47 2009] A phase spider tries to bite YOU, but  are INVULNERABLE!
[Thu Oct 15 16:13:47 2009] A phase spider tries to bite YOU, but  are INVULNERABLE!
[Thu Oct 15 16:13:48 2009] Zekab slashes a phase spider for 85 points of damage.
[Thu Oct 15 16:13:49 2009] A phase spider tries to kick YOU, but  are INVULNERABLE!
[Thu Oct 15 16:13:49 2009] Zekab kicks a phase spider for 21 points of damage.
[Thu Oct 15 16:13:51 2009] A phase spider tries to bite YOU, but  are INVULNERABLE!
[Thu Oct 15 16:13:51 2009] A phase spider tries to bite YOU, but  are INVULNERABLE!
[Thu Oct 15 16:13:51 2009] Zekab slashes a phase spider for 85 points of damage.
[Thu Oct 15 16:13:51 2009] Zekab slashes a phase spider for 58 points of damage.
[Thu Oct 15 16:13:54 2009] A phase spider tries to bite YOU, but  are INVULNERABLE!
[Thu Oct 15 16:13:54 2009] A phase spider tries to bite YOU, but  are INVULNERABLE!
[Thu Oct 15 16:13:54 2009] A phase spider tries to kick YOU, but  are INVULNERABLE!
---[Thu Oct 15 16:13:54 2009] Zekab kicks a phase spider for 61 points of damage.
---[Thu Oct 15 16:13:54 2009] Zekab slashes a phase spider for 59 points of damage.
---[Thu Oct 15 16:13:54 2009] Zekab slashes a phase spider for 65 points of damage.
---[Thu Oct 15 16:13:54 2009] Zekab pierces a phase spider for 59 points of damage.
---[Thu Oct 15 16:13:54 2009] Zekab pierces a phase spider for 60 points of damage.
[Thu Oct 15 16:13:57 2009] A phase spider tries to bite YOU, but  are INVULNERABLE!
[Thu Oct 15 16:13:57 2009] Zekab slashes a phase spider for 58 points of damage.
[Thu Oct 15 16:13:57 2009] Zekab tries to slash a phase spider, but misses!
[Thu Oct 15 16:13:59 2009] A phase spider tries to kick YOU, but  are INVULNERABLE!
[Thu Oct 15 16:13:59 2009] Zekab tries to bash a phase spider, but misses!
[Thu Oct 15 16:13:59 2009] Your EarthElementalStrike2 spell has worn off of a phase spider.
[Thu Oct 15 16:14:00 2009] Zekab tries to slash a phase spider, but misses!
[Thu Oct 15 16:14:00 2009] Zekab tries to slash a phase spider, but misses!
[Thu Oct 15 16:14:00 2009] A phase spider tries to bite YOU, but  are INVULNERABLE!
[Thu Oct 15 16:14:00 2009] A phase spider tries to bite YOU, but  are INVULNERABLE!
[Thu Oct 15 16:14:03 2009] a phase spider scowls at you, ready to attack -- You would probably win this fight..it's not certain though.
That's a quad.
__________________

~Shin Noir
DungeonEQ.com
Reply With Quote
  #9  
Old 10-15-2009, 07:44 PM
ChaosSlayerZ's Avatar
ChaosSlayerZ
Demi-God
 
Join Date: Mar 2009
Location: Umm
Posts: 1,492
Default

not saying they not quadding past 40+
however, I see no reason why they not DW before that...
necro and mage pet had DW since 29+, clearly not the case on Emu
neither any of npcs

also the diffirence that: necro/mage pets summoned with lev 29 spells, the pets themselves are not lev 29, but in fact much
lower (possibly as low as 22)
Reply With Quote
  #10  
Old 10-15-2009, 09:39 PM
ChaosSlayerZ's Avatar
ChaosSlayerZ
Demi-God
 
Join Date: Mar 2009
Location: Umm
Posts: 1,492
Default

I have asked people to post on what they know about DW on LOVE and gathered some extra data here:

http://www.eqemulator.net/forums/showthread.php?t=29556
Reply With Quote
  #11  
Old 10-16-2009, 03:38 AM
Dibalamin
Hill Giant
 
Join Date: Dec 2007
Posts: 182
Default

Even warrior mobs normally only doubled on live unless they happened to have the extra weapons on their table. But some mobs could naturally quad.

For example, I'm pretty sure Nagafen was a base warrior and didn't quad.
__________________
Retired EMarr
Project1999 Developer
Reply With Quote
  #12  
Old 10-16-2009, 12:10 PM
ChaosSlayerZ's Avatar
ChaosSlayerZ
Demi-God
 
Join Date: Mar 2009
Location: Umm
Posts: 1,492
Default

well in our case even giving them weapons does not change anything.

not to mention it creates a balance of power issue where warrior mobs become weaker than paladin or SK mobs, who can also just double attacking but also casting and using HT/LH
Reply With Quote
  #13  
Old 10-16-2009, 02:32 PM
Shin Noir's Avatar
Shin Noir
Legendary Member
 
Join Date: Apr 2002
Location: Seattle, WA
Posts: 502
Default

I posted partially about this here:
http://www.eqemulator.net/forums/showthread.php?t=29809
More so talking about the incosistancy between the graphical display of dual wield vs. the actual ability to DW.
But I think if the developers wanted to tweak the level in which the pets DW, they just syncronize those two snippets of code, and then you'll know when your pet is DWing or not just by the level check.

@what level to DW: That is a question for EQEMU, most servers may have different opinions from server to server..
Maybe make a rule_value entry for it.
__________________

~Shin Noir
DungeonEQ.com
Reply With Quote
  #14  
Old 10-24-2009, 04:52 PM
Twanfox
Fire Beetle
 
Join Date: Jul 2008
Location: IL
Posts: 1
Default

Just to stick my nose into this particular bug...

I used to play a magician and, from rare times still do on Live, and having played that class for a long time and getting deep into the pet balance issues, I can say with high confidence that pets began dual wielding when the magician was in their 20s. At the time I played, they had the pet spells batched together (20, 24, and get all 4 at once). I forget the specific level, but once they could dual wield, they had to use weapons to do so until they hit 28 or 32 and then they would dual wield innately.

I have a card just waiting to be used on Live one of these days, so when I do, I can always double check the level grouping of pet for those characteristics.

I'm curious, though. Shouldn't this kind of thing be more configurable per npc/pet instead of hard coded like this?

And Shin, yes, I've noticed that too. Visibility of dual wielding and actual dual wielding is inconsistent and misleading to the player.
Reply With Quote
  #15  
Old 10-24-2009, 10:05 PM
ChaosSlayerZ's Avatar
ChaosSlayerZ
Demi-God
 
Join Date: Mar 2009
Location: Umm
Posts: 1,492
Default

I agree that it would be MUCH better to control if any specific npc (pets included) can DW based on a SPECIAL ABILITY FLAG regardless of level or even class, so if I needed to, I could make a dual wielding wizard npc/pet

This would be best solution for either classic or custom servers, specially since current system is not true to LIVE neither.
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

   

All times are GMT -4. The time now is 12:05 PM.


 

Everquest is a registered trademark of Daybreak Game Company LLC.
EQEmulator is not associated or affiliated in any way with Daybreak Game Company LLC.
Except where otherwise noted, this site is licensed under a Creative Commons License.
       
Powered by vBulletin®, Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Template by Bluepearl Design and vBulletin Templates - Ver3.3