Commit graph

18 commits

Author SHA1 Message Date
VladimirMangos
fe6e2e1746 [9122] Updated copyright notice for new year.
Also fix some lost in past cases.
2010-01-08 00:02:21 +03:00
balrok
97c94cff56 fixed problems with isInvisbleForAlive
removed redundant check at MoveInLos
this check is already done in istargetableForAttack
thx to NoFantasy

fixed in isVisibleForOrDetect that isInvisbleForAlive
wasn't checked.. and therefore all spiritserviceprovider
got visible
thx to NetSky
2009-10-21 20:00:07 +02:00
balrok
46389e4e1c [8689] implement function Unit::isInvisibleForAlive
with that i've implemented all known auras which makes
units invisible for alive.. but that's currently quite hacky
i think best would be if we could set a unit-flag after those auras
getting applied
2009-10-20 23:37:21 +02:00
balrok
e990d5c509 [8688] proper implementation of creatures ghost-flags
this reverts 8676 (9c50d9e70314b0cd9eb0fe3bac8040d64a9965a5)
the new flag is from wdb-files so your database should be
already alright

also i've dropped the function Player::CanInteractWithNPCs
cause it was used only in one place and didn't seem to make anything
easier

NOTE for this flag:
it just means that the creature can be seen by ghost-players
too..
so they are still visible for alive players.. unless a special
aura or ther unitflag (spiritguide/healer) disables this..
(see next commit for it)
2009-10-20 23:34:13 +02:00
balrok
a2ff999fd3 [8676] implemented dead-visible creature flags_extra
with this flag you can specify a creature to be only
visible for dead players - this removes all hacks from
spiritguides/spirithealers from code and allows some other
special creatures

i decided to not implement an extra deathstate cause
actualy those creatures are almost equal to living ones
2009-10-18 21:28:36 +02:00
VladimirMangos
b258a17ba4 [8658] Threat calculation fixes and improvements.
* Add single arg version Unit::AddThreat for just adding to threat list.
* Req. provide schollmask and crit flag for any real threat value for proper threats mod apply.
* Send crit flag in DealDamage as MELEE_HIT_CRIT for spell damage for later send to threat call.
* For not affected by modifiers threat values use SPELL_SCHOOL_MASK_NONE.
* Implement aura SPELL_AURA_MOD_CRITICAL_THREAT (used only in itemset 529 effect).
2009-10-17 11:02:30 +04:00
NoFantasy
e973b082f4 [8643] Correct a few typos in debug log messages.
Signed-off-by: NoFantasy <nofantasy@nf.no>
2009-10-14 13:42:44 +02:00
NoFantasy
65965bc5fa [8642] Replace the Spanish word 'hostil' with the English one.
Signed-off-by: NoFantasy <nofantasy@nf.no>
2009-10-14 12:46:10 +02:00
balrok
02d45b4b54 [8625] feign_death cleanups
use an extra function for setfeigndeath()
like it's done with setfeared already..
allow to apply feigndeath on creatures too
avoid moving of creatures with feign death applied
and start attacking last victim when feigndeath disappears
2009-10-11 14:22:52 +02:00
VladimirMangos
45dd7140b5 [8422] Implement far sight like spells work for long distance.
* Added basic infrastructure for visibility update in case difference player and current view point.
  Just for note: seletect additional arg way beacuse repeatable search object will slow but store pointer will not safe,
  so use middle case: get view point pointer early as possible at visibility updates.
* Implement dynamic object and creature activisation while it's target of far sight spell effect
* Use this for SPELL_AURA_BIND_SIGHT, SPELL_AURA_FAR_SIGHT and SPELL_EFFECT_ADD_FARSIGHT.
* Note2: some spyglass like spells let look _around_ at long distance, this hard implement in current grid loading system
  Without additional changes and not implemented (you will see empty area without creatures in likes case)

* Also fixed warning spam at CMSG_MOVE_SET_CAN_FLY_ACK receive by use proper packet sructure reading.
2009-08-26 08:30:40 +04:00
VladimirMangos
788cdf9b3a [7826] Avoid use GetDistance* that used slow sqrt call where possible, other related speedups. 2009-05-14 18:51:13 +04:00
VladimirMangos
73db1cbe01 [7723] New AI call EnterCombat called at enter creature to combat (and re-enter if leave by some reason). 2009-04-27 03:40:50 +04:00
VladimirMangos
d910610600 [7697] Interrupt casting at enter to evade mode. 2009-04-22 18:05:59 +04:00
VladimirMangos
69fb9736cc [7667] Add to CreatureAI field pointing to creature itself. Use it instead diff. fields in subclases.
Also send pointer to AI constructors ans mark constructors as explicit.

This changes allow move now some generic often used AI code to CreatureAI helper functions.
2009-04-14 06:52:16 +04:00
balrok
c947823b66 removed unneeded Player.h includes
with:
ack -c Player | ack ":1$" | sed 's/:1//' | xargs /usr/bin/ack-grep "include \"Player.h\""
2009-03-08 02:08:43 +03:00
arrai
c6f48843ad [7017] Updated copyright notice for new year 2009-01-03 18:09:51 +01:00
arrai
a3a57a5390 [6885] In dungeons even fighting creatures are supposed to put nearby players in combat. 3rd party scripting libraries might have to be updated 2008-12-07 21:34:27 +01:00
TheLuda
800ee76535 Imported MaNGOS revision 6767 from http://mangos.svn.sourceforge.net/svnroot/mangos/trunk/ 2008-10-14 00:29:20 +02:00