Commit graph

35 commits

Author SHA1 Message Date
XTZGZoReX
1f23884757 Don't use singleton to access static functions.
* This affects especially ObjectMgr functions:
   - GetCreatureInfo
   - GetGameObjectInfo
   - GetInstanceTemplate
   These are in fact static functions.
2009-11-08 03:54:27 +01:00
tomrus88
de73c52a77 Fixed group loot display bug. 2009-10-24 19:31:38 +04:00
laise
211b50ce63 [8699] Fix instance bound difficulty selection.
This must fix crashes at enter to heroic mode instances and raids showup after client switch.

Signed-off-by: VladimirMangos <vladimir@getmangos.com>

I can't repeat crashes with existed raids after changes apply but possible in some cases
need drop content of related DB table for resolve some crashes.
2009-10-21 22:51:43 +04:00
balrok
dc96ddfbfb [8599] removed now unneeded parameter from GetBattleGroundQueueIdFromLevel
cause alterac valley is not handled special since 3.2.2
this function also works without bgtypeid parameter
2009-10-07 15:36:43 +02:00
VladimirMangos
a9af7f2b1c Use reset time for normal/heroic from new DBC. Improve basic support for raid difficalties. 2009-10-06 02:12:02 +04:00
tomrus88
3882772658 Merge commit 'origin/master' into 320
Conflicts:
	src/game/Player.cpp
2009-08-27 01:54:04 +04: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
tomrus88
1df1f7cff5 Fixed player movement.
Fixed multinode taxi.
Removed some unhandled opcode spam.
2009-08-09 18:08:14 +04:00
tomrus88
54cc2dcb53 Merge commit 'origin/master' into 320 2009-07-05 13:19:54 +04:00
lukaasm
1498f93e49 [8108] Fixed a case in resetting group binds where the actual map reset was done even though it had permanent binds.
This is a temp fix as the function should be rewritten to be more clear / less error prone.

Signed-off-by: Wyk3d <Wyk3d@getmangos.com>
2009-07-02 15:41:01 +03:00
Ambal
2baccbebc3 [8103] More wide use IsInWorld checks and delayed at teleport operations.
* IsInWorld used to prevent return unexpected not in world objects.
* Delayed operations need to process its in world state.

Signed-off-by: VladimirMangos <vladimir@getmangos.com>
2009-07-02 09:18:43 +04:00
Ambal
9f938a9ed4 [8103] More wide use IsInWorld checks and delayed at teleport operations.
* IsInWorld used to prevent return unexpected not in world objects.
* Delayed operations need to process its in world state.

Signed-off-by: VladimirMangos <vladimir@getmangos.com>
2009-07-01 14:00:29 +04:00
tomrus88
02bcc56919 Added placeholders for new battlegrounds, some other stuff. 2009-06-25 19:08:53 +04:00
VladimirMangos
2a27a44e2a [7918] Improve portability in work with uint64 string format specifiers and in code literals.
* Replace platform seelction MaNGOS code for select format descriptor for uint64 by using ACE define.
  I64FMTD renamed to UI64FMTD for more clear name.
* Add new define UI64LIT (base at ACE seelction) for build portables uint64 literals.
  Please always use UI64LIT(0x00001) instead less portable 0x00001LL
2009-05-30 22:44:20 +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
arrai
fefe56e3c5 [7776] Completed implementation of CMSG_SPELLCLICK
For vehicles, you have to add the correct SPELL_AURA_CONTROL_VEHICLE spells to
npc_spellclick_spells, otherwise you won't be able to use them
2009-05-05 18:58:58 +02:00
zhenya
8144f30199 [7730] Some optimizantion and code style.
Signed-off-by: AlexDereka <dereka.alex@gmail.com>
2009-04-29 01:05:21 +04:00
AlexDereka
c9d51a6dc7 [7716] Fixed some typos and possible crashes. 2009-04-26 18:49:07 +04:00
Triply
74006886e9 [7457] Fixed set Bg raid leader to party or raid leader who entered Bg.
Removed useless code from my previous patch.

Signed-off-by: Triply <triply@getmangos.com>
2009-03-14 20:22:17 +01:00
Triply
b45b075668 [7455] Implemented condition that player can be in 2 groups in 1 time - BG raid and normal group / raid.
Patch is tested, but can cause problems / unexpected behaviour.
TODO: set raid leader of battleground raid to raid leader who entered BG
TODO: when player leaves group, he is removed from GroupQueueInfo, and for him is created new GroupQueueInfo in normal queue.

Signed-off-by: Triply <triply@getmangos.com>
2009-03-14 17:01:30 +01:00
Triply
8f995ce904 [7336] Implemented new BattleGroundQueue invitation system. Now it supports premade group versus premade group matches.
Added 2 new config options - InvitationType and PremadeGroupWaitForMatch - you can find more info in default config file.
This patch can cause crashes.

Signed-off-by: Triply <triply@getmangos.com>
2009-02-25 19:21:31 +01:00
balrok
bd89568993 [7275] getbattlegroundqueueidfromlevel returns now bg-specific queueids
before this commit, queueids were staticaly given for
9-19,20-29,30-39... but for instance alterac valley needs
51-60,61-70,71-80.. this patch allows this,
if you change the minlevel in battleground_template you also could make
23-32,33-42.. levelranges
not that we always use 10lvl-steps.. this is actually hardcoded..
2009-02-13 10:32:21 +03:00
balrok
b75157946c [7269] Use enum type for battleground queue type ids, and related cleanups.
* renamed a variable to make the content of it more clear: type->arenaslot
* renamed BattleGroundQueueTypeId-variables to bgQueueTypeId
  just to make it easier reading the code (cause there existed
  3 different names for this..)
* renamed GetBattleGroundQueueId to GetBattleGroundQueueTypeId
  again this is just for better understanding
* Renamed [GS]etQueueType and m_Queue_type
* Renamed to [GS]etQueueId and m_QueueId

Signed-off-by: VladimirMangos <vladimir@getmangos.com>
2009-02-12 09:00:28 +03:00
VladimirMangos
5a4358dda9 [7250] Use bg type ids enum insted raw values and catch some bugs in result for fixing.
* Replace max bg type checks by DBC valid index check
* Use in functions and fields BattlegroundTypeId type instead uint32
* Fixed wrong use bg queue ids instead bg type ids in queue update/remove function calls.
  Many bg have same raw values for type id and queue id but some can be affected by this bug:
  BATTLEGROUND_EY, BATTLEGROUND_SA, and all areans (with small arena/team size exceptions)
* Move Battlemaster to bg type ids map fron ObjectMgr to BatteleGroundMgr.
* Remobe redundent for header itself includes for BG headers.
* Use Auction location enum instead raw valus.
2009-02-08 11:05:11 +03:00
VladimirMangos
ed52e3f8f0 [7213] Fixed quest related GO activation/deactivation at join/leave/convert raid group. 2009-02-01 03:23:29 +03:00
arrai
c6f48843ad [7017] Updated copyright notice for new year 2009-01-03 18:09:51 +01:00
hectolight
802b35fbb8 [6999] Implemented ACHIEVEMENT_CRITERIA_TYPE_ROLL_GREED_ON_LOOT and ACHIEVEMENT_CRITERIA_TYPE_ROLL_NEED_ON_LOOT
Signed-off-by: arrai <array.of.intellect@gmail.com>
2009-01-02 00:05:50 +01:00
ApoC
a5331ab517 [6910] Implemented rewritten arenas. Original author w12x@getmangos.com
Many thanks also to:
  Balrok@github.com for long time updating.
  Triply@github.com for great work in rewriting process.
  All who I forget to name.
Signed-off-by: ApoC <apoc@nymfe.net>
2008-12-16 00:17:24 +01:00
hunuza
ac2748a141 [6897] Avoid DB access on uninvite from group.
Signed-off-by: hunuza <hunuza@gmail.com>
2008-12-11 21:37:24 +01:00
balrok
2e08a63da7 [6884] Replaced iterator++ with ++iterator in for-loop-headers
i used this script
for i in ls *.[ch]*; do cat $i | sed -r 's/(.*for.*iterator.*;\
    *)([a-z0-9\_\*]+)\ *\+\+(.*)/\1++\2\3/' > /tmp/mangos/$i; done
for i in ls *.[ch]*; do cp /tmp/mangos/$i $i; done

and rechecked it with my eyes, if everything is right
i took only for-loops cause they can be gathered easier with a script

Signed-off-by: hunuza <hunuza@gmail.com>
2008-12-07 19:49:45 +01:00
hunuza
90828fa699 Cache highest arena team/guild ids. Some code clean up. 2008-11-05 16:58:57 +01:00
ApoC
aae37a6dce Added missed part from my prev. commit.
Compile fix.
Signed-off-by: ApoC <apoc@nymfe.net>
2008-10-28 21:10:08 +01:00
ApoC
61b2b3d234 Prevent adding more than 5 people into RAID subgroup.
Optimized free subgroup in raid finding.
Optimized method calls, now using const uint64& instead of value passing.
Signed-off-by: ApoC <apoc@nymfe.net>
2008-10-28 20:15:24 +01:00
Reiner030
0d4f770811 Implement low character expirience level in group with high character.
Signed-off-by: VladimirMangos <vladimir@getmangos.com>
2008-10-23 07:29:53 +04:00
TheLuda
800ee76535 Imported MaNGOS revision 6767 from http://mangos.svn.sourceforge.net/svnroot/mangos/trunk/ 2008-10-14 00:29:20 +02:00