Commit Graph

567 Commits

Author SHA1 Message Date
joschiwald
52023b1e6b Scripts/MagistersTerrace: fix possible crash 2014-06-27 18:45:49 +02:00
Vincent-Michael
f94fe58f78 Script/MagistersTerrace: Fix fail in 27f2855248 2014-06-26 23:16:56 +02:00
Vincent-Michael
27f2855248 Core: Fix warnings and kill again whitespace ... 2014-06-26 22:50:06 +02:00
joschiwald
32d2e25556 Merge pull request #12364 from MitchesD/misc_2
Scripts/MagistersTerrace: reworked InstanceScript and fixed some issues ...
2014-06-26 22:28:51 +02:00
MitchesD
6ebb64892f Scripts/MagistersTerrace: reworked InstanceScript and fixed some issues on boss Vexallus
* removed old hacks and added missing auras
* Vexallus converted to EventMap
2014-06-26 22:25:24 +02:00
Kittnz
80e0c443ff Quest: Powering our Defenses fixed
Fix by @Discover-, @untaught, @Kittnz
2014-06-24 18:23:37 +02:00
MitchesD
86b3298a47 Scripts/Misc: random fixes 2014-06-14 17:48:47 +02:00
Vincent-Michael
1d39db16b9 Core/Misc: Kill Whitespace ... 2014-06-07 23:58:08 +02:00
aletuna
1b3149b07f Scripts/Blackrock Depths: Converted to eventmap+minor coding style changes
Closes #11730
2014-06-07 19:02:39 +02:00
Gacko
8ef34535a4 Scripts: Remove unused variables (kept as comment) 2014-06-01 19:34:34 +02:00
jackpoz
f091713086 Core/Misc: Fix typo
Fix typos about the word "Resurrect"
2014-05-24 18:25:53 +02:00
jackpoz
1083dbb993 Core/Misc: Remove Unit::Get* wrappers for ObjectAccessor::Get* 2014-05-20 21:21:33 +02:00
Shauren
f9c7bb4171 Partially revert f296095191 "Fix various warnings. The core, the scripts and the tools now compile without warnings with -Wall -Wextra -pedantic."
Visual studio does not support constexpr
Made semicolon after "Prepare*Script" mandatory - workaround for dumb IDEs inserting extra indentation level after newline
2014-05-18 12:50:10 +02:00
Praetonus
f296095191 Fix various warnings. The core, the scripts and the tools now compile without warnings with -Wall -Wextra -pedantic.
-Fix warnings from -Woverflow on implicit constant conversion.
-Fix warnings from -pedantic.
-Fix warnings from -pedantic.
-Fix warnings from -Wformat.

Two minor changes in addition :

-Replace a defined value equal to 2^31 - 1 by std::numeric_limits<int>::max().
-Remove useless null-check on pointer returned by new. New doesn't returns nullptr on failure, it throws std::bad_alloc.
2014-05-15 21:32:47 +02:00
Trisjdc
593fb9b68a Scripts/SWP: Sathrovarr will no longer cause player teleports on grid load 2014-05-13 11:32:56 +01:00
MitchesD
eabec73d98 Scripts/Duskwood: prevention to spawn multiple Twilight Corrupter and fixed some issues there 2014-05-09 16:59:55 +02:00
Dehravor
24ae6a6802 Core/Misc: Remove obsolete C++11 backward compatibility macros
OVERRIDE, FINAL, DELETE_MEMBER
2014-04-29 16:35:11 +02:00
joschiwald
84bff76ba0 Core/Misc: remove some obsolete parameters 2014-04-28 20:05:36 +02:00
jackpoz
2585e799f9 Core/Misc: Change how Position struct is retrieved
Update Position::GetPosition() and similar methods signatures to reflect 2a4c9bcaf9 changes by return a Position object instead of accepting a Position parameter by reference.
2014-04-25 21:19:30 +02:00
joschiwald
6c0ff5717f Scripts/Gnomeregan: moved Blastmaster Emi gossip to db 2014-04-21 21:39:51 +02:00
warmech
12b895e5ba Fixed spelling typo in gnomeregan.cpp script.
Fixed a typo on line 32 where [GOSSIP_START_EVENT "I am ready to being"] should read [GOSSIP_START_EVENT "I am ready to begin."]
2014-04-20 23:00:32 -05:00
jackpoz
fb6365ac68 Core/Misc: Check GetVictim() for NULL before dereferencing it
Add additional NULL checks all around the code before dereferencing GetVictim() result.
Keep in mind UpdateVictim() result has nothing to do with GetVictim() result and the caller shouldn't assume anything about GetVictim() based on UpdateVictim().
2014-04-20 00:38:25 +02:00
jackpoz
8ca6371793 Core/Misc: Ensure GetVictim() returns a valid reference when expected
Add a new method EnsureVictim() which asserts a valid not NULL reference will be returned to the caller. Use this whenever the GetVictim() would be dereferenced .
2014-04-19 21:48:22 +02:00
joschiwald
fa472c6142 Merge pull request #11787 from MitchesD/misc
Scripts/ZulGurub: clean up the old code
2014-04-17 02:01:05 +02:00
Nyeriah
870d5d9c45 [TW278] - Core/Scripts: Prevent multiple spawns of Ulag
http://www.wowhead.com/quest=1819/ulag-the-cleaver
2014-04-11 22:36:38 +02:00
MitchesD
ab602837b1 Scripts/ZulGurub: clean up the code and remove old hacks 2014-04-11 18:43:38 +02:00
Vincent-Michael
0b615ec159 Scripts/Misc: Small code optimizations 2014-03-29 20:58:49 +01:00
jackpoz
8c44259fae Core/Misc: Fix some static analysis issues
Fix uninitialized values, most of which are false positives, always initialized before being accessed.
Add some asserts and additional NULL checks as sanity checks. Use SpellMgr::EnsureSpellInfo() if the spell id is valid and always supposed to return a valid not-NULL SpellInfo* .
2014-03-27 21:43:59 +01:00
MitchesD
d9d088421d Scripts/ZulAman/Halazzi: convert text to create_text and fixed despawn of cat 2014-03-22 22:30:20 +01:00
jackpoz
6dcd8c8545 Core/Misc: Fix some static analysis issues
Fix some static analysis issues about:
- uninitialized values, most of which are false positives, always initialized before being accessed
- unchecked return values
- dead code never executed
- bad formatting leading to wrong behavior

Please ensure EventMap is never used with event id set to 0 or those events will never execute.
2014-03-22 14:54:32 +01:00
Aokromes
33316bde38 Merge pull request #11747 from untaught/Trinity1
Core/Scripts: Move 'The Defias Traitor' script to SAI
2014-03-21 00:55:49 +01:00
untaught
8a9bfbba48 Core/Scripts: Move 'npc_deathly_usher' scripts to SAI. 2014-03-20 20:29:06 +02:00
untaught
c31ffd774e Core/Scripts: Move 'The Defias Traitor' script to SAI 2014-03-18 08:31:23 +02:00
untaught
5f7e0f6929 Instance Script/Stratholme: Correct logic in Baron Run event and add SAI for Ysida Harmon 2014-03-16 08:47:27 +02:00
jackpoz
3b247f6bca Scripts/ZulGurub/Jeklik: Add missing "break" 2014-03-15 19:45:44 +01:00
Vincent_Michael
79a2a0c434 Core/Spell: Fix logic fail in 96ae4caf62 2014-01-26 16:42:02 +01:00
Vincent_Michael
9531073b77 Scripts: Gossip can crash with null instance 2014-01-24 17:08:17 +01:00
Vincent_Michael
46e1b93c2b Scripts: A lots of changes here and there (maybe useless?!?) 2014-01-23 22:54:01 +01:00
joschiwald
d6c5307a81 Scripts/Spells: use new hook in some spellscripts 2014-01-23 20:55:47 +01:00
MitchesD
57e599fa02 Scripts/ZulGurub/Jeklik: fixed flying in first phase, reworked spawn and rewritten to EventMap
Closes #11277
2014-01-22 23:46:45 +01:00
Vincent_Michael
101ac7f511 Misc: Minor cosmetic changes here and there 2014-01-21 20:20:38 +01:00
zengwf
23acf75d3b Core/Movement: Add LOS check for fleeingmovement target point.
Prevents fleeing or feared units from going to upper floor ignoring walls/ceilings with mmaps on(and usually get stucked).

Current implementation just randomly selects a distance and angle against the frighting unit, when in narrow circumstance such as underground caves, such targeting point would be at another floor.

Closes #11300
Ref #9475 (needs fixed confirmation)
2014-01-12 00:33:33 +00:00
joschiwald
cd76d32907 Core/Entities: correct creature damage, offhand damage should work too
* todo: some creatures need dmg_multiplier update in creature_template
2014-01-04 18:22:06 +01:00
Vincent_Michael
20004050bc Update copyright note for 2014.
Happy new year.
2014-01-01 00:07:53 +01:00
jackpoz
64b42c75d2 Scripts/Misc: Code cleanup
Remove some NULL checks not needed anymore after 3744c14184 .
Fix an invalid Creature to TempSummon cast.
2013-12-30 23:36:49 +01:00
jackpoz
5c64dade0f Scripts/Misc: Fix uninitialized values
Fix uninitialized values in scripts reported by valgrind.
Fix target and GetOwner() NULL dereferences .
2013-12-29 23:01:00 +01:00
jackpoz
e016ef3dbd Merge branch 'master' of github.com:TrinityCore/TrinityCore 2013-12-29 16:27:25 +01:00
Malcrom
0e0b00cab6 Scripting/War Master Voone: Fix Cleave spell and minor cleanup. 2013-12-29 11:41:46 -03:30
jackpoz
90c63e4818 Scripts/Misc: Fix uninitialized values
Fix uninitialized values in scripts reported by valgrind.
2013-12-29 16:05:31 +01:00
Malcrom
9af36d887b Merge branch 'master' of https://github.com/TrinityCore/TrinityCore 2013-12-28 20:52:49 -03:30