Commit graph

154 commits

Author SHA1 Message Date
cyberium
9022705faf [12195] Improve AreaTrigger teleport requirement checks
Implement AreaLockStatus concept by rsa

Also drop basicly unneeded `areatrigger_teleport`.required_failed_text field.
This concept is still in testing phase, please feedback results of some glitches that might exist!

TODO: Use Player::GetAreaLockStatus or GetAreaTriggerLockStatus for other "CanEnter" checks as well.

Signed-off-by: Schmoozerd <schmoozerd@scriptdev2.com>
2020-02-16 20:42:13 +00:00
stfx
c8814791e1 [12153] Remove unneeded InBattleGround() as it is already checked by GetBattleGround()
Also call OutdoorPvP handlers before instance script ones
2020-02-16 20:41:31 +00:00
rsa
de95d1d480 [12123] Move BattleGround code to separate BattleGround directory. Also some corrects to unload BG's 2020-02-16 20:40:57 +00:00
Reamer
e90caf7349 [12111] Add Unit::KnockBackWithAngle function
Also wrap up the packet sending for a knockbacked player to WorldSession::SendKnockBack

Signed-off-by: Schmoozerd <schmoozerd@scriptdev2.com>
2020-02-16 20:23:03 +00:00
kid10
0c752dbdbd [12109] Add file to handle vehicle related opcodes
Also fixed a stupid typo from recent commit. Thx to dbauz for pointing

Signed-off-by: Schmoozerd <schmoozerd@scriptdev2.com>
2020-02-16 20:10:42 +00:00
Yaki Khadafi
b4d97ccf77 [0072] Fix world teleport and use normalized orientation in some more places
Signed-off-by: Yaki Khadafi <ElSolDolLo@gmail.com>
2020-02-16 08:58:36 +00:00
Yaki Khadafi
e7d0275ae2 [0067] Set- canfly/forcemoveroot/waterwalk packets, SMSG_PLAY_SPELL_VISUAL
Signed-off-by: Yaki Khadafi <ElSolDolLo@gmail.com>
2020-02-16 08:29:40 +00:00
Yaki Khadafi
4409188546 [0006] Fix most of movement opcodes. Thx Strawberry & Trinity for MovementStatusElements idea.
Signed-off-by: Yaki Khadafi <elsoldollo@gmail.com>
2020-02-16 02:54:05 +00:00
Yaki Khadafi
f7cd8ce52a Fix SMSG_UPDATE_OBJECT, SMSG_DESTROY_OBJECT, and some teleport opcodes
Authors: Strawberry, Trinity, me
Signed-off-by: Yaki Khadafi <elsoldollo@gmail.com>
2020-02-16 02:53:44 +00:00
Schmoozerd
835d1c7479 [12069] Cleanup comment style 2012-07-22 14:39:31 +02:00
Schmoozerd
e32b9953a1 Cleanup Operator padding 2012-07-20 17:38:23 +02:00
Schmoozerd
8d0c106aa4 Various Cleanups (game L-M) 2012-07-19 21:46:40 +02:00
stfx
f3f3349661 [11973] Various Cleanups
Signed-off-by: Schmoozerd <schmoozerd@scriptdev2.com>
2012-04-22 19:48:05 +02:00
Schmoozerd
8068dcf6dd [11875] Update Copyright notice to year 2012
Start timemachine and a Happy new year to all!
2012-01-16 17:43:59 +01:00
SilverIce
fc0eb7e9fa [11721] Simplify walk/run movement mode selection code 2011-07-08 19:30:00 +03:00
VladimirMangos
249fb836ca [11490] Alow implicit cast ObjectGuid->uint64 and only explicit uint64->ObjectGuid
Now safe allow this casts in like way after completed convertion to ObjectGuid use.
Also simplify code in result allowed auto cast to uint64.

Please _not_ add new uint64 storages (local and in structures) for guid values.
2011-05-15 22:04:57 +04:00
VladimirMangos
719e298795 [11470] Final cleanup uint64 guid cases
Also drop logout player update fields cleanup that in any cases not saved.
2011-05-11 21:36:27 +04:00
VladimirMangos
605fb79847 [11446] Reimplement corpse enter to instance.
* Resurrect player _before_ enter to instance with corpse
* In case corpse in more deep instance teleport to corpse instance inner entrance.
* If by some reason player can't enter to corpse instance it will just resurrected before entrance.

Original patch and research done by Den.
2011-05-09 00:58:42 +04:00
zergtmn
2835aa5f20 [11385] Add support for static vehicle spawns
Signed-off-by: zergtmn <zerg@myisp.com>
2011-04-20 23:23:47 +06:00
VladimirMangos
108feb993d [11127] Rename src/game/InstanceSaveMgr.* -> src/game/MapPersistentStateMgr.* 2011-02-10 05:35:07 +03:00
VladimirMangos
dde16bc48c [11126] Rewrite InstanceSaveMgr related code.
* For better fit name to related map type class InstanceMap renamed -> DungeonMap.
  This clarify usage Instanceable()/IsDungeon() because BG/Arenas maps also instanceable maps.

* InstanceSave have many code related to only DungeonMap case, so it replaced by 3 new classes:
   - MapPersistentState as base class, used for non-instanceable maps (continents and some other) (!Instenceable())
   - DungeonPersistentState subclass of MapPersistentState, used for DungeonMap states (IsDungoen())
   - BattlegroundPersistentState subclass of MapPersistentState, used for BattlegroundMap states (IsBattleGroundOrArena())

   Now all dungeon resets code moved to subclass and all player/gpoup bound functions/structures also use it.

* Map::GetInstanceSave renamed to Map::GetPersistentState and DungeonMap have specialized version
  return DungeonPersistentState (same pointer in fact with proper subcalss type)

* InstanceResetScheduler renamed to DungeonResetScheduler
2011-02-10 05:20:56 +03:00
zergtmn
c9fc5727fc [11070] Correct meaning of one field in MSG_MOVE_TELEPORT_ACK packet 2011-01-25 22:45:36 +05:00
VladimirMangos
784c0ca781 [11017] Finaly restore non-crashing non-in-world logout.
For example at close client with far teleport loading screen.
2011-01-16 20:38:48 +03:00
VladimirMangos
0c19c2c6a2 [11015] Prevent crash at player far teleport landing to nonexisten battleground instance.
Teleport back in like case or to homebind in bad case.
2011-01-16 00:31:41 +03:00
VladimirMangos
bf0ecf6e71 [10947] Update copyright notice for 2011 year. 2011-01-01 20:33:43 +03:00
Ambal
b11820593c [10924] Send time diff between Update() calls for object - should help with mob respawn on inactive grids etc. Based on patches by VladimirMangos and cipherCOM. All issues from previous patches should be finally fixed now.
Signed-off-by: Ambal <pogrebniak@gala.net>
2010-12-27 22:27:20 +02:00
maly32167
1fef606dd8 [10839] At far teleport fail retunr player to source point instead homebind.
Signed-off-by: VladimirMangos <vladimir@getmangos.com>
2010-12-08 06:48:27 +03:00
VladimirMangos
ce7b98c45e [10799] Add GetGuidStr() short call for GetObjectGuid().GetString() and use it. 2010-12-01 09:56:13 +03:00
VladimirMangos
cc0655a402 [10782] Use Team enum types in all appropriate cases and catches bug in result fix.
* Fixed wrong arenaid use at leave arena queue.
* Fixed memory lost and etc at not virtual EndBattleground call
* Fixed crash at arena join with fake data from client.
* Code cleanups.
2010-11-25 01:11:17 +03:00
VladimirMangos
10273fa38a [10732] Not send session fields as args into HandleMoverRelocation/VerifyMovementInfo.
Also mark args as constant where expected in this functions.
2010-11-18 06:12:15 +03:00
Ambal
f67d89f109 [10727] Map system re-engineered. Special thanks to Blueboy for tests.
Signed-off-by: Ambal <pogrebniak@gala.net>
2010-11-16 21:08:28 +02:00
VladimirMangos
a32d68febd [10671] Convert some Unit owner/etc guids to ObjectGuid way. 2010-11-01 13:19:50 +03:00
SilverIce
1370ead743 [10659] Fixed mistake in [10653] that causes player to fall from the transport at teleporting to another map 2010-10-31 12:15:32 +02:00
SilverIce
1871cf977f [10653] Implemented MSG_MOVE_KNOCK_BACK opcode
* Player's knockback movement now smooth and doesn't looks like teleporting
 * Cleanup WorldSession::HandleMovementOpcodes, separated opcode specific and generic movement handlers code
 * Handle Feign Death aura interrupting into more appropriate place
2010-10-28 05:48:43 +03:00
VladimirMangos
54d991ef3a [10469] Rename some opcode handler to better follow used naming style 2010-09-11 14:38:22 +04:00
VladimirMangos
72414ad03b [10450] Skip wrong guid movement packets.
Also fix src/game/SharedDefines.h line ends corrupted in prev. commit. :/
2010-09-06 18:35:03 +04:00
VladimirMangos
09b03b470e [10402] Use ObjectGuid in packets and fix some uint32 guids cases. 2010-08-23 12:37:11 +04:00
Lynx3d
01d326b90d [10202] Rename isInFlight() to IsTaxiFlying() and UNIT_STAT_IN_FLIGHT to UNIT_STAT_TAXI_FLIGHT.
Also add IsFreeFlying() function to Player class.
2010-07-17 02:06:28 +02:00
VladimirMangos
e88a718c5d [10094] Extract instance reset scheduler from InstanceSaveMgr
Reset scheduler code not need explicit access to instance saves,
and no reson mix it with instance save managment code in single class
2010-06-22 04:40:33 +04:00
VladimirMangos
2326292981 [10059] Cleanup in Player::m_mover uses
* Also fix triggered by related checks unread packet tail spam cases.
* Fix one case when expected death at fall controlled player
  under ground has been possible avoided
2010-06-15 03:50:52 +04:00
VladimirMangos
722135b326 [9838] More log filters and macro uses.
* LogFilter_Weather
* LogFilter_PeriodicAffects
* LogFilter_PlayerMoves
* LogFilter_SQLText
* LogFilter_AIAndMovegens
* LogFilter_PlayerStats
2010-05-05 18:46:10 +04:00
VladimirMangos
9e356f10c9 [9806] Fixed player loading to transport.
Bug exist already some time but possible hide by another code way work or
client change maybe.
2010-04-29 17:25:13 +04:00
SilverIce
6ab55fa09e [9796] Controlled unit should be a source of movement packets, not player-controller.
Now movements of controlled unit are visible for nearby players,
even when controller too far from controlled unit

This new type of packet broadcasting used in HandleMovementOpcodes handler only,
maybe it can be used somewhere else.

(based on SilverIce's repo commit d2387ca)

Signed-off-by: VladimirMangos <vladimir@getmangos.com>
2010-04-26 14:02:41 +04:00
XTZGZoReX
34e56c9978 [9641] Fix typo; IN_MILISECONDS -> IN_MILLISECONDS. 2010-03-30 14:44:57 +02:00
VladimirMangos
b658b25ff8 [9618] More use ObjectGuid in spell/etc code 2010-03-25 13:59:46 +03:00
VladimirMangos
ab7840a591 [9580] Add ObjectGuid const& Object::GetObjectGuid() and restore build. 2010-03-13 17:35:47 +03:00
Iron
37f733221d [9560] Fixes possible runtime crash added by 9551
Signed-off-by: AlexDereka <dereka.alex@gmail.com>
2010-03-10 10:12:49 +03:00
VladimirMangos
c8fd454a79 [9551] Add and use PackedGuid wrapper.
Also
* use more wide bytebuff << >> operators for objects
* use at read packet faisl alsways exception way instead some time used bool results.
2010-03-08 20:23:16 +03:00
VladimirMangos
73eeac234f [9454] Fixed some time existed multi-map taxi problem.
Interrupt taxi movegen at far teleport time with remove related state.
Far teleport triggered code not expect this state set.
2010-02-26 00:48:10 +03:00
AlexDereka
ccfd42bf3e [9381] Fixed some compile warnings. 2010-02-14 18:16:07 +03:00