Commit Graph

102 Commits

Author SHA1 Message Date
QAston
1d96091d2a *Improvements in map managing.
--HG--
branch : trunk
2009-08-01 00:20:32 +02:00
megamage
7bd47f8827 [8225] Some fixes from 320 branch. Author: tomrus88
--HG--
branch : trunk
2009-07-30 10:26:15 +08:00
QAston
e3e0fd522e *Fix a crash with MAP_BASED_RAND_GEN - thanks to Azuritus for research.
--HG--
branch : trunk
rename : sql/updates/4602_world_spell_bonus_data.txt => sql/updates/4602_world_spell_bonus_data.sql
rename : sql/updates/4603_world_tmp.txt => sql/updates/4603_world_tmp.sql
rename : sql/updates/4604_world.sql => sql/updates/4610_world.sql
2009-07-27 16:06:39 +02:00
Kudlaty
607dfaf8c9 Merge [SD2]
r1088 Add grid searcher class PlayerAtMinimumRangeAway and create ScriptedAI function GetPlayerAtMinimumRange that return player in grid with at least the defined range away from m_creature.
r1089 Remove no longer needed grid search code and use function instead. - skip
r1090 Rename and clarify function variables - skip
r1091 Add two new grid search functions to return list of creature and gameobject. Remove unused class.
r1092 Remove more grid search code in scripts and use functions instead.
r1093 Remove obsolete grid search class and rename new to a more consistent name.
r1094 Speed up functions GetCreature/GameObjectListWithEntryInGrid a bit

--HG--
branch : trunk
2009-07-24 05:27:49 +02:00
megamage
208087ff6e [8182] Store and use Map* pointer in WorldObject instead map ids for speedup Author: Ambal
Also some code logic cleanups.
    Changes let make more cleanups in base map access and other places,
    but this chnages not inlcuded in patch.

*This patch may cause crash.

--HG--
branch : trunk
2009-07-16 11:49:00 +08:00
megamage
111dac5f94 [8102] Simplify code base at new root method WorldObject::CleanupsBeforeDelete Author: VladimirMangos
* Call it from Map::AddObjectToRemoveList and remove now not needed explcit calls
    * Create Gameobject version to make GO with owner more safe for remove

--HG--
branch : trunk
2009-07-01 18:23:36 -05:00
megamage
3cf2be6042 [8026] Obtain object's map directly by calling appropriate WorldObject::GetMap()/GetBaseMap() functions instead of accessing MapManager. Code cleanups. Big thanks Infinity for tests. Author: Ambal
--HG--
branch : trunk
2009-06-16 11:19:59 -05:00
megamage
ee9c12b480 *Some fix of vehicles. Thanks to Seizerkiller.
--HG--
branch : trunk
2009-06-13 09:18:54 -05:00
megamage
9d670fe6f5 *Switch to support client version 3.1.3
*I strongly recommend you not to use this until you get the 313 db. Now all destructible buildings cause client crash.

Source: Mangos
Thanks to TOM_RUS for most work to make this switch possible ;)

--HG--
branch : trunk
2009-06-11 00:45:59 -05:00
megamage
999b49201a *Merge. (spell parts skipped)
--HG--
branch : trunk
2009-06-01 15:02:58 -05:00
megamage
76e4dfe8dd *Store creatureData and goData for creatures and gos.
--HG--
branch : trunk
2009-05-31 21:04:04 -05:00
megamage
5034078d49 *Lay on hands should have heal amount = caster's max health.
*Let goober call zonescript when an event happens.
*Thanks Elron for the last rev (flight bug)

--HG--
branch : trunk
2009-05-31 20:45:34 -05:00
megamage
5ed5513ca8 Mangos [7911]. Author: tomrus88
Very big patch. May cause bugs.

--HG--
branch : trunk
2009-05-31 15:56:51 -05:00
megamage
da871e2fc0 *Move addcre/go functions from opvp to objmgr.
*Do not save respawn time for internally added cre/go.

--HG--
branch : trunk
2009-05-31 14:26:57 -05:00
megamage
8d1f4f9ea0 *Provide another way to implement dynamic spawns. Now a creature will call its zonescript before spawn to determine the spawned entry. This can be used to implement zones such as wintergrasp with less data requirement (only need to know the entry of counterpart creatures, not require spawn points)
*Use zonescript as basic class of opvp script and dugeon script (can also be used for bg)
*Store zonescript in worldobject.
*Add door for sapphiron.

--HG--
branch : trunk
2009-05-30 22:15:05 -05:00
megamage
b5778357d9 *Fix a crash. Thanks to Amok
--HG--
branch : trunk
2009-05-30 17:17:05 -05:00
megamage
89f4c1c444 *Add function FindNearestCreature and FindNearestGameObject to replace old FindCreature and FindGameObject
--HG--
branch : trunk
2009-05-29 16:49:28 -05:00
megamage
106766e4ac *Add an assert to find a bug.
--HG--
branch : trunk
2009-05-29 12:08:06 -05:00
megamage
cb72853dc6 *Cleanup message deliver functions. Remove unused parameters.
--HG--
branch : trunk
2009-05-27 09:09:22 -05:00
megamage
c2588042e9 *Move some random generator functions to map class: functions in map/object/movementgenerator/spell
--HG--
branch : trunk
2009-05-25 12:05:23 -05:00
krz
4423ac3194 Range calculation fix.
Channeled SPELL_AURA_PERIODIC_TRIGGER_SPELL will now not trigger spell if target is out of range.
Channeled periodic damage auras will now not deal damage if target is out of range.

--HG--
branch : trunk
2009-05-24 16:18:19 +02:00
Anubisss
3449432e38 *Add ATTACK_DISTANCE from MaNGOS.
--HG--
branch : trunk
2009-05-18 20:34:09 +02:00
megamage
047cc95388 *Add some distance check functions. By VladimirMangos.
--HG--
branch : trunk
2009-05-14 16:50:47 -05:00
megamage
40a8e6d3ab *Rename some script functions (no real change).
--HG--
branch : trunk
2009-05-10 14:29:28 -05:00
megamage
e35d07ad81 *Update Sapphiron script.
--HG--
branch : trunk
2009-05-09 10:50:41 -05:00
megamage
eb9328e4db *Fix the calculation of isInLine.
--HG--
branch : trunk
2009-04-30 16:13:57 -05:00
megamage
3a316370b1 [7696] Fixed compile warnings Author: AlexDereka
--HG--
branch : trunk
2009-04-22 17:56:59 -05:00
megamage
1cd8ea8c1a *Fix some bugs about vehicle.
--HG--
branch : trunk
2009-04-22 17:50:26 -05:00
megamage
787cd7fcb5 *More work on vehicle.
--HG--
branch : trunk
2009-04-21 13:49:39 -05:00
megamage
0c56b79e96 *Merge.
--HG--
branch : trunk
2009-04-20 20:31:20 -05:00
megamage
df26c17a11 *Try to fix compile in linux.
--HG--
branch : trunk
2009-04-20 19:57:01 -05:00
megamage
95a0928190 *Merge.
--HG--
branch : trunk
2009-04-20 18:05:32 -05:00
megamage
dc99a44797 *Add m_map in worldobject to make getmap faster.
--HG--
branch : trunk
2009-04-20 17:37:59 -05:00
megamage
c7d78b5ff9 *Some work on vehicles.
--HG--
branch : trunk
2009-04-17 15:08:58 -05:00
megamage
0010f7ffe3 [7648] Resolve problems with expected fall damage at near teleport. Author: VladimirMangos
Move near teleport landing code to WorldSession::HandleMoveTeleportAck.
    This make Player::TeleportTo code working in same way for both far/near teleports.
    Move mSemaphoreTeleport from WorldObject to Player and merge with DoNotMove (using 2 fields for far/near teleport flag).
    Skip movement packets until landing confirmation for near teleport from client.

--HG--
branch : trunk
2009-04-11 23:07:07 -05:00
megamage
dda2fdff33 *Implement spell Disengage and Death Grip.
--HG--
branch : trunk
2009-04-11 22:41:15 -05:00
megamage
c106914e94 *Remove some invalid template functions.
--HG--
branch : trunk
2009-04-10 17:56:42 -05:00
megamage
f59c4debf6 [7622] Added creatureAI with related database tables. Author: AlexDereka
*Note: three tables are renamed.

--HG--
branch : trunk
2009-04-07 19:38:09 -05:00
megamage
9a03bb1e5f *Backport some contents from TC2.
--HG--
branch : trunk
2009-04-04 20:31:29 -06:00
megamage
30eedaa72d *Try to fix some crash.
--HG--
branch : trunk
2009-04-01 21:17:59 -06:00
megamage
031df598ab *Try to fix crash.
--HG--
branch : trunk
2009-03-31 09:18:39 -06:00
megamage
829c8022ac [7577] Implement YellToZone for different world object types. Author: VladimirMangos
--HG--
branch : trunk
2009-03-28 18:03:56 -06:00
megamage
1c2e62d2f4 *Backport a missing function from TC2.
--HG--
branch : trunk
2009-03-26 08:50:51 -06:00
megamage
312b8e5b73 *Merge.
--HG--
branch : trunk
2009-03-25 16:00:38 -06:00
megamage
581ae2719d *Do not allow to add/remove obj to/from world more than once.
--HG--
branch : trunk
2009-03-25 15:54:23 -06:00
megamage
d1169aa48b *Fix a crash caused by summoncreature.
--HG--
branch : trunk
2009-03-24 09:06:49 -06:00
megamage
f18a9c916d *Fix some crashes possibly related to vehicles.
*Fix a bug that client crashes when seer is far away from caster.

--HG--
branch : trunk
2009-03-23 20:13:37 -06:00
megamage
ba957ed9f4 *Allow knockback creatures.
--HG--
branch : trunk
2009-03-23 15:26:13 -06:00
megamage
a47d2e1c22 *Note some script id are changed. DB change may be needed.
[7518] Implement new script command SCRIPT_COMMAND_PLAY_SOUND (look in World.h for args) Author: VladimirMangos

    * Also rewrite use SMSG_PLAY_OBJECT_SOUND/SMSG_PLAY_SOUND
      Now WorldObject have 2 function for sound level dependent from distance (PlayDistanceSound)
      and for not depednet (PlayDirectSound)
    * Old Player::PlaySound function removed and uses need to be updated to WorldObject functions
      Note: function called for _source_ of sound in different from old function.
    * chat command .debug ps removed and .debug playsound can used for bother packects test:
      if no selection used SMSG_PLAY_SOUND, if selection exist including self then SMSG_PLAY_OBJECT_SOUND.

--HG--
branch : trunk
2009-03-22 19:20:03 -06:00
megamage
a2392121f0 *Fix the bug that summon dbc is not read. Now creatures can be summoned.
*Make minipet as tempsummon instead of pet. Make totem as tempsummon.

--HG--
branch : trunk
2009-03-19 14:41:30 -06:00