Commit Graph

89 Commits

Author SHA1 Message Date
Nay 2b2d054f64 R.I.P SimpleAI
- Convert SimpleAI to (DB) SmartAI
- Spell ids corrected (and completed some of the scripts)
- Random cleanup (code style) in some scripts
2012-03-11 16:59:17 +00:00
Shauren f85fdbebe7 Core/DBC: Remove store getters (useless since we don't have scripts as external dll) 2012-03-10 20:53:26 +01:00
Spp d38bc3a178 Core: Rename GetCreatureInfo to GetCreatureTemplate and minor cleanup here and there 2012-02-27 14:58:47 +01:00
Venugh 1cac01b3df Core/Movement: Use SetWalk(true/false) instead of AddUnit/RemoveUnit. 2012-02-23 11:50:58 +01:00
Shocker 08be716ef8 Core/Misc: Rename UNIT_STAT_* enums to UNIT_STATE_* 2012-02-03 19:02:17 +02:00
Machiavelli dbbac0bdaa Core/Movement: Implement spline movement subsystem.
Spline movement controls movements of server-side controlled units (monster movement, taxi movement, etc).
Proper implementation of effects such as charge, jump, cyclic movement will rely on it.
However, need improve our states system before.

Technical changes:

* Added linear, catmullrom and bezier3 splines which based on client's algorthims. They can be reused for proper transport position interpolation.
* Precission increased. There are no more position desync issues since client's position calculation formulas used.
* Now possible to move by paths with multiple points, send whole path to client.

--
Original author of research and implementation: SilverIce. Massive kudos.
Original port for Trinity (ref #4629) Chaplain and Venugh
With the following incremental fixes during my review:

- Restore flightmaster end grid pre-loading
- Fix uninitialized Creature::m_path_id
- Add missing trinity_string entries for .movegens command
- Fix a bug in WaypointMovementGenerator that would trigger unexpected pausing at waypoints for various amounts of time

Known issues:
- Errors like WaypointMovementGenerator::LoadPath creature XXX (Entry: YYYYY GUID: ZZZZZZ) doesn't have waypoint path id: 0.
This is caused by bad DB data. This commit didn't "break" it.

Do not forget to re-run CMake before compiling.
2012-01-14 15:36:07 +01:00
Valcorb ed27fb6d7d Update the rest of the headers 2012-01-13 16:58:48 +01:00
kiper 8299627ed9 Update headers for 2012. HAPPY NEW YEAR!!! 2012-01-01 00:32:13 +01:00
Spp d59c5e627f Fix warnings 2011-12-15 11:12:15 +01:00
kaelima be0b2fcf97 Core/Grid:
- Simplified CellArea calculation (Original author: SilverIce)

- Removed unused code in Cell class (Original author: SilverIce)

- Improve some Visit functions.
2011-10-19 17:40:44 +01:00
megamage c29ff41001 Rename some classes in grid system.
Note: The naming of classes is still confusing. "cell" usually refers to class "Grid", and "grid" usually refers to class "NGrid". But it requires a lot of changes to clean this up.
2011-10-18 10:53:34 -04:00
megamage d156e066cf Rename "SetPosition" to "UpdatePosition".
Replace CreatureRelocation in scripts with new Creature::SetPosition.
2011-10-10 17:08:01 -04:00
Bootz 5b4c7783c2 REPO: Code-style clean-ups
* Fixed pMap->map
* Fixed pInstance->instance
* Fixed pInsta->instance
* Fixed pQuest->quest
* Fixed pWho->who
* Fixed pTarget->target
* Fixed pGo->go

~DEVNOTES: Handlers/QuestHandler.cpp still needs to be cleaned...
2011-10-07 19:45:43 -05:00
Shauren 2ff1c28c4c Scripts/Icecrown Citadel
* The Lich King
2011-10-05 20:48:34 +02:00
Spp b16d2245bb Cosmetic: Multiple cosmetic changes
- Added missing space to 'if', 'for', 'while' and 'switch' when it's followed by '('
- Added missing space after a comma and remove space before comma (with some exceptions)
- Remove trailing spaces
- Convert tab to spaces

Note: Only affects files with extension "cpp" and "h" under /src/server
2011-09-29 12:43:05 +02:00
Souler 99c63e86ae Scripts/Ulduar: Make XT-002 and Ignis enter evade mode if pulled out from their fight areas.
Also implement a default case for EnterEvadeIfOutOfCombatArea.
2011-09-22 22:14:52 +02:00
QAston ec7da6f911 Core/ScriptedAI: remove ScriptedAI::CanCast function which is not functioning properly (compare that func with Spell::CheckCast to see how it should work) and is unused. Closes #2275. 2011-09-12 00:20:37 +02:00
Shauren f13f32c972 Core/Achievements: Award normal mode achievements when instance was done on heroic mode 2011-09-05 15:21:37 +02:00
Fredi Machado 78e10e9cd0 Core/AI: Cleaning up hungarian notation 2011-08-20 20:31:31 -03:00
Fredi Machado 0b64d726c2 Core/AI: Code style and cleanups 2011-08-18 14:55:59 -03:00
Machiavelli 58f10c74f7 Core/Spells: Change low level bool triggered with bitmask TriggerCastFlags to better manipulate the behaviour of certain triggered spells. 2011-07-31 21:58:25 +02:00
Spp- fa50c0a464 Fix some warnings here and there 2011-07-27 11:00:39 +02:00
QAston b0fe236265 Core: Use new SpellInfo class in core. Sadly, this commit is not compatibile with some of the custom code. To make your code work again you may need to change:
*SpellEntry is now SpellInfo
*GetSpellProto is now GetSpellInfo
*SpellEntry::Effect*[effIndex] is now avalible under SpellInfo.Effects[effIndex].*
*sSpellStore.LookupEntry is no longer valid, use sSpellMgr->GetSpellInfo()
*SpellFunctions from SpellMgr.h like DoSpellStuff(spellId) are now: spellInfo->DoStuff()
*SpellMgr::CalculateEffectValue and similar functions are now avalible in SpellEffectInfo class.
*GET_SPELL macro is removed, code which used it is moved to SpellMgr::LoadDbcDataCorrections
*code which affected dbc data in SpellMgr::LoadSpellCustomAttr is now moved to LoadDbcDataCorrections
2011-07-26 23:09:28 +02:00
kaelima b9e8694540 Core: Continued cleanup
If and for whitespaces.
2011-06-12 02:30:32 +02:00
click c77aa6e846 Core: And some more cleanups... 2011-06-12 02:00:43 +02:00
click f16df538ee Core: More codestyle cleanups 2011-06-12 01:47:45 +02:00
click 158966dc79 Core: Codestyle cleanup 2011-06-11 22:35:29 +02:00
click df20ba9956 Core/AI: Fix previous commit (467f33e) 2011-05-28 02:14:47 +02:00
click 467f33e3d9 Core/AI: Minor adjustment on the WorldBossAI : Avoid putting the entire map in combatmode... 2011-05-28 01:24:27 +02:00
click fac7534611 Core/AI: Add WorldBossAI for world-side (non-instanced) bosses (essentially a stripped version of BossAI) 2011-05-28 00:28:04 +02:00
click 2d1b3ccaa1 Compile warnings fixes 2011-05-27 14:45:44 +02:00
Shauren 0ad14aeafd Core/Gossip: Gossip menu items will now have constant index, allowing to properly define scripts relying on that index when mixed with conditions. Script-created menus via ADD_GOSSIP_ITEM will still have the index generated dynamically 2011-05-26 23:57:17 +02:00
Shauren a644206f88 Scripts: Removed SEND_VENDORLIST and SEND_TRAINERLIST defines 2011-05-26 23:31:46 +02:00
Shauren c8f71c00a1 Core/Scripts: Added ExecuteEvent BossAI hook designed to contain event code which would otherwise be in while (uint32 eventId = events.ExecuteEvent()) switch blocks. This allows to define a base class sharing spells with other scripts 2011-05-25 18:50:44 +02:00
Shauren 9cc7f25b9a Scripts: Removed CAST_PET and CAST_INST 2011-05-25 16:22:13 +02:00
Shauren 64adce7b8b Scripts: Removed CAST_SUM define 2011-05-25 15:55:14 +02:00
click eff3c1f98a Core: Clean up some more silly warnings 2011-05-09 03:37:31 +02:00
leak 1003f30448 Add spaces after commas 2011-04-29 20:47:02 +02:00
leak c51c817a45 Core/ObjectMgr: Refactor sCreatureStorage 2011-04-28 22:57:08 +02:00
Shauren d73ffc9e81 Core/Vehicles:
* Added generic solution for vehicle accessories not relying on AI calls
* Only accessories marked as minion will be respawned when the vehicle enters evade mode
* Notify the summoner's AI when vehicle accessory fails to install and despawns
2011-04-22 21:59:37 +02:00
Machiavelli d42ab6c8bd Core/ScriptedAI: Reset VehicleKit in BossAI::_Reset()
Core/Vehicles: Minor log fix and comment a redundant assertion
2011-04-22 11:07:58 +02:00
Sawiner 1be1b1559c Core/Scripts: Extended escort AI 2011-04-16 17:15:21 +02:00
Shauren 82991448f7 Core/Scripts: Removed some hungarian notation 2011-04-16 14:00:47 +02:00
pek2011 535b663280 Core/Cleanup: Drop various unused code 2011-04-03 16:05:27 +03:00
Shauren 0fbde67824 Core/AI: Some code style cleanup 2011-03-27 12:54:42 +02:00
Shauren 99104ab576 Scripts/Icecrown Citadel: Replace instance check with a safer one, this way if failed the creature is not idle 2011-03-21 19:00:56 +01:00
Shauren 3b343ac497 Core/Scripts: Code style cleanup in AI base classes, removed duplicate DoAction method 2011-03-19 19:41:42 +01:00
Shauren 1a4a618d81 Core/Scripts: Code style cleanup in ScriptedAI and BossAI 2011-03-19 10:54:16 +01:00
Machiavelli 7b62bfc1c5 Core/ScriptedAI: Add ResetLootMode() to BossAI::_Reset() and remove some redundant calls in General Vezax script 2011-03-13 22:28:37 +01:00
Shauren c2c40a4750 Scripts: Removed duplicate target selection function (SelectUnit), there is only SelectTarget now 2011-03-09 21:32:04 +01:00