Jump to content

[patch/dev] pet stats


Auntie Mangos

Recommended Posts

Hmm, no idea. Tried to reproduce the problem, but without success. Especially this pet is not tamable with my used db. Only after some modifications (type_flags, family) I was abled to tame. But than I did not get any crash.

Anyway this behavior is very strange. To get exactly 0 HP you need less stamina than the creatures (or pet's in this case) base stamina, what is (and was already without this patch) theoretically possible if you have any debuff on your pet tha decreases it's stamina. Maybe it would a good idea to limit the hp>0 in Unit::SetMaxHealth().

Do you have any ideas to reproduce the crash. Did it also happen with other pets?

Link to comment
Share on other sites

  • Replies 111
  • Created
  • Last Reply

Top Posters In This Topic

Just after this crash, i add check in Unit::SetMaxHealth (if maxhealth == 0 then set maxhealth = createhealth), no other crashs.

I don't have ideas for reproduce this crash, it is my data in creature_template:

+-------+--------------------+--------------------+--------------------+-------------+-------------+-----------+------------+-----------+------------+------------------------+---------+----------+----------------+----------+----------+-----------+-----------+---------+---------+-------+-----------+-----------+---------+-------+-------+------+--------+--------+-----------+-------------+----------------+----------------+-----------------+------------+------------+--------------+--------+--------------+---------------+---------------+--------------+-------------+-------------+-------------------+------+------------+--------+----------------+----------+-------------+-------------+-------------+-------------+-------------+-------------+--------+--------+--------+--------+----------------+---------+---------+--------+--------------+-------------+-------+-------+--------------+------------+------------+------------+------------+------------+------------+------------+-------------+--------------+----------------------+-------------+------------------+
| entry | difficulty_entry_1 | difficulty_entry_2 | difficulty_entry_3 | KillCredit1 | KillCredit2 | modelid_A | modelid_A2 | modelid_H | modelid_H2 | name                   | subname | IconName | gossip_menu_id | minlevel | maxlevel | minhealth | maxhealth | minmana | maxmana | armor | faction_A | faction_H | npcflag | speed | scale | rank | mindmg | maxdmg | dmgschool | attackpower | dmg_multiplier | baseattacktime | rangeattacktime | unit_class | unit_flags | dynamicflags | family | trainer_type | trainer_spell | trainer_class | trainer_race | minrangedmg | maxrangedmg | rangedattackpower | type | type_flags | lootid | pickpocketloot | skinloot | resistance1 | resistance2 | resistance3 | resistance4 | resistance5 | resistance6 | spell1 | spell2 | spell3 | spell4 | PetSpellDataId | mingold | maxgold | AIName | MovementType | InhabitType | unk16 | unk17 | RacialLeader | questItem1 | questItem2 | questItem3 | questItem4 | questItem5 | questItem6 | movementId | RegenHealth | equipment_id | mechanic_immune_mask | flags_extra | ScriptName       |
+-------+--------------------+--------------------+--------------------+-------------+-------------+-----------+------------+-----------+------------+------------------------+---------+----------+----------------+----------+----------+-----------+-----------+---------+---------+-------+-----------+-----------+---------+-------+-------+------+--------+--------+-----------+-------------+----------------+----------------+-----------------+------------+------------+--------------+--------+--------------+---------------+---------------+--------------+-------------+-------------+-------------------+------+------------+--------+----------------+----------+-------------+-------------+-------------+-------------+-------------+-------------+--------+--------+--------+--------+----------------+---------+---------+--------+--------------+-------------+-------+-------+--------------+------------+------------+------------+------------+------------+------------+------------+-------------+--------------+----------------------+-------------+------------------+
| 18706 |                  0 |                  0 |                  0 |           0 |           0 |     17408 |          0 |     17408 |          0 | Bonechewer Riding Wolf |         | NULL     |              0 |       58 |       59 |      4000 |      4100 |       0 |       0 |  3431 |        14 |        14 |       0 |  1.48 |     1 |    0 |    116 |    174 |         0 |          44 |              1 |           2000 |            2000 |          0 |          0 |            0 |      0 |            0 |             0 |             0 |            0 |          93 |         139 |                35 |    1 |          0 |      0 |              0 |        0 |           0 |           0 |           0 |           0 |           0 |           0 |   3149 |  16460 |      0 |      0 |              0 |       0 |       0 |        |            1 |           3 |     1 |     1 |            0 |      25812 |      25807 |          0 |          0 |          0 |          0 |          0 |           1 |            0 |                    0 |           0 | generic_creature |
+-------+--------------------+--------------------+--------------------+-------------+-------------+-----------+------------+-----------+------------+------------------------+---------+----------+----------------+----------+----------+-----------+-----------+---------+---------+-------+-----------+-----------+---------+-------+-------+------+--------+--------+-----------+-------------+----------------+----------------+-----------------+------------+------------+--------------+--------+--------------+---------------+---------------+--------------+-------------+-------------+-------------------+------+------------+--------+----------------+----------+-------------+-------------+-------------+-------------+-------------+-------------+--------+--------+--------+--------+----------------+---------+---------+--------+--------------+-------------+-------+-------+--------------+------------+------------+------------+------------+------------+------------+------------+-------------+--------------+----------------------+-------------+------------------+

Link to comment
Share on other sites

The new crash happened with the modification in Unit::SetMaxHealth?

I compared your db values with mine. The only 'eventually' critical values are type_flags and family. As I already told you -in fact- should not be abled to tame a pet without values here (type&0x01 and any family = 1, wolf in this case). I can not image how this can produce such a crash, but who knows...^^ Maybe you can change your db values and observ the probelm...

Thank you for your intensiv evaluation :-)

Edit: Hmm, just found in your crashlog:

/scripts/world/mob_generic_creature.cpp:9393 if (m_creature->GetHealth()*100 / m_creature->GetMaxHealth() < 30
this is a custom scrip, or am I wrong?
Link to comment
Share on other sites

Good work pasdVn

Before the damage of Shadowfiend to 40-120

now a priest with 2600 sp, the damage Shadowfiend ago 1 -350

I would copy the comment http://www.wowhead.com/?spell=34433 # comments

especially this part

Pre-3.1 shadowfiend:

Approximately hits for 111 dmg @ 1.5 speed = 74dps = 1110 shadow damage

Ulduar 3.1 Shadowfiend

Shadowfiend's dps scales with your spell power now (receives 30% of caster's spell power in damage). New Shadowfiend ability, Shadowcrawl, teleports the Shadowfiend to an enemy target and increases its damage done by 15% for 5 seconds.

So if you pick a target, cast shadowfiend, then cast Shadowcrawl within 10 seconds to get the most dps out of shadowfiend you will..

for 10 seconds do = 74 dps + (your spell power x 0.2) x 5

for 5 seconds do = 1.15 x (74 + (your spellpower x 0.2)) x 10

(0.2 comes from 30% coefficient divided by 1.5 attack speed)

Your Spellpower = 2000 ...

74 + (2000 x 0.2) = 474 dps x 10 = 4740 shadow damage

474 x 1.15 = 545.1 dps x 5 = 2725.5 shadow damage

=================================================

Estimated total damage = 7565.5 shadow damage

///////////////////////////////////////////////////////////////////////////////////////////////////

Your Spellpower = 1500 ...

74 + (1500 x 0.2) = 374 dps x 10 = 3740 shadow damage

374 x 1.15 = 430.1 x 5 = 2150.5 shadow damage

=================================================

Estimated total damage = 5890.5 shadow damage

If you want a REALLY rough coefficient to work around the math

Your shadowfiends...

total damage will be about: 3.84 x spellpower

total dps will be about: 0.2422 x spellpower

You can also take into account certain raid debuffs on the enemy that will increase the damage furthermore since it is considered shadow damage (Shadow Weaving, Curse of Shadows, etc)

My damage parse using it once: http://img4.imageshack.us/img4/3153/shadowfiend.png

For those curious, 15 sec active time / 1.5 aspd = 10 hits x 5% caster's max mana = possible 50% Mana gain over 15 sec

stress attack speed is 1.5 s, is currently 2s

The damage is shadow, not physical

The speed should be faster Shadowfiend

Any improvements that can be done to be appreciated Shadowfiend

Good patch continues

P.D Sorry for my English

Link to comment
Share on other sites

Update:

  • * fixed Ayane's crash :-)
    * make attack speed definable via creature_template (for all except hunter pets, ofc.), so shadowfiend should now be faster
    * added haste scaling for dk pet, I also checked the other stats, but they don't fit at all to my less values I gathered on an official server, so I leave it as it is for now
    * added the second water elemental^^

Damage school could be always set by db (also before this patch), so shadowfiend, fire elemental totem... should work (as long as you have the correct db values).

Also updated for current HEAD (but no merge errors, so does not matter).

Link to comment
Share on other sites

I just realized, that pet's don't share the owners armor penetration, but the owners spell penetration. Can anyone confirm that?...

I'm confused now. I could swear I read about it somewhere, or has this been changed already?

One thing I forget to say that life was now the 2400 is just shadowfiend

I do not think anything logical as any scratch shadowfiend dies on an area 2400 of damage of any kind takes away the shadowfiend

Should really be just a DB issue now. The actual UDB has around 2400hp at level around 70 (I tink in older releases it was around 12k o.O).
Link to comment
Share on other sites

pasdVn: 3.2.0 patch notes:

All pets now receive 40% of their master's resilience and 100% of their master's spell penetration. In addition, if a player is at their appropriate spell hit chance or hit chance maximum, their pet will be at the maximum for spell hit chance, hit chance, and expertise. If they are below the maximum, their pet will be proportionately below those maximums.
Link to comment
Share on other sites

  • 2 weeks later...

Rebased patches onto [9443] and merged branch with [9443].

Additionally I substituted the armor penetration by spell penetration (as there are no scaling auras and this seems to be valid for all pets, this is just a hardcoded part). Maybe in fact it would also be more clever to solve the hitchance/expertise like that, because also hit chance/expertise is for all pets...?

Link to comment
Share on other sites

pasdVn, even though you have merged your repo branches for 'pet' and 'petstats' into 9443, does either rely on updated MaNGOS core code or functions?

The reason I'm asking is my server is currently set at 0.15 revision 9134, but I wanted to include your improvements and fixes for 'pets' and 'petstats'. Doing a compare, I noticed you added entire blocks of code, like in Creature.cpp, but most of the remaining code is the same as your last two merge/commits with MaNGOS 0.16 r 9347 and, before that, MANGOS 0.16 r 9266 (-dev1 branch now).

Can I simply add the new versions into my server sources by manually editing or will there need to be some changes made to the patches, like renaming variables/classes/functions or declaring a uint64 as uint32?

These two patches are among my "must have" additions for my server. Hunter Pets and Warlock Guardians/Minions work so much better! Thank you for continuing to work upon these. :D

I used them with my old TBC server and I had feared you abandoned the projects with such a long period lacking updates. Bless you for restoring my hope that 'pets' and 'petstats' will remain. I'm eagerly looking forward to the year when they become a standard part of the core.

Now... if only balrok can be flushed out of his hiding to continue work on Outdoor PvP! :P

Link to comment
Share on other sites

Can I simply add the new versions into my server sources by manually editing or will there need to be some changes made to the patches, like renaming variables/classes/functions or declaring a uint64 as uint32?

Mostly that are really minor changes, another coding style or other small things. So I think it should be no problem for you to fix some merge errors by hand imo^^ Just be careful: The 'pet' branch is completly rebased, so probably you have some more work, if you merge with an older version of this branch, but that's off topic now :-/.

Link to comment
Share on other sites

Thank you for informing me and providing advice for merging 'pets' and 'petstats' 9443 with MaNGOS 0.15 revision 9134.

I do not wish to take this thread off-topic but, I need your aid, as the creator of the code, in keeping the pet patches current despite my server being an older version of MaNGOS. I must maintain it so for compatibility with my database, at least until UDB works out the kinks in 0.11.6 with their next release.

If you would please be so kind, I will continue this in a new topic to avoid further off-topic discussion here. I shall post it under Developer's Corner in the General Discussion section.

I look forward to learning more from one of the most skilled developers to contribute to the MaNGOs project. :)

Link to comment
Share on other sites

I don't know if it isn't something form insiders branch (I am merging it with your petstats ;-) ) but after player call pet (for example dismount) pets HP is increased by stat modifier but not filled to propper %. For example if raw pets maxhp is 5000, current saved hp is 5000 (100%) after stat modiefier applied additional 1500 hp is like 5000/6500. at least i think it could be the reason. Can anyone confirmes my issue?

Link to comment
Share on other sites

  • 3 weeks later...

Yes, you are right. This is caused by this patches.

I took my old version of the 3rd part again (the workaround), so that pets will keep their percental heath/mana when (re)applying stamina/intellect scaling aura (what should fix this problem).

Also merged/rebase branch and patches with/onto [9635] (but no merge errors, so it's not really needed).

Link to comment
Share on other sites

  • 3 weeks later...

I have noticed that in this patch, have been corrected are spell. In particular // mage's Water Elemental// priest's Shadowfien // Feral Spirit Wolves // Mirror Image

Which in last REV do not work as it is necessary..

Whether the author of the given patch, separately to write a patch, on correction of the given pet`s can?

Link to comment
Share on other sites

on mangos rev 9752 i got this error:

2>..\\..\\src\\game\\Pet.cpp(1927) : error C2664: 'void Unit::CalculateSpellDamage(SpellNonMeleeDamage *,int32,const SpellEntry *,WeaponAttackType)' : cannot convert parameter 1 from 'const SpellEntry *' to 'SpellNonMeleeDamage *'

2> Types pointed to are unrelated; conversion requires reinterpret_cast, C-style cast or function-style cast

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. Privacy Policy Terms of Use