diff options
| author | Shauren <shauren.trinity@gmail.com> | 2017-03-23 00:11:58 +0100 |
|---|---|---|
| committer | ariel- <ariel-@users.noreply.github.com> | 2017-06-03 02:27:48 -0300 |
| commit | abac1b34bcb84d65ef857076321af3acd22a3c9b (patch) | |
| tree | 3b698b17e9233a612faf44777d7b8d4402cb18f2 /src/server/game/AI/ScriptedAI | |
| parent | ff39c27104634c9f1d37a0625eb78461e34c77a0 (diff) | |
Core/Utilities: Rename RandomResizeList->RandomResize as it is no longer restricted to a list
* Also fix gcc build
(cherry picked from commit f097e341f5afcac2dd0ae9dbb265201c0de2a934)
Diffstat (limited to 'src/server/game/AI/ScriptedAI')
| -rw-r--r-- | src/server/game/AI/ScriptedAI/ScriptedCreature.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/server/game/AI/ScriptedAI/ScriptedCreature.h b/src/server/game/AI/ScriptedAI/ScriptedCreature.h index f1b25cd505d..b4db664a980 100644 --- a/src/server/game/AI/ScriptedAI/ScriptedCreature.h +++ b/src/server/game/AI/ScriptedAI/ScriptedCreature.h @@ -107,11 +107,11 @@ public: } template <class Predicate> - void DoAction(int32 info, Predicate& predicate, uint16 max = 0) + void DoAction(int32 info, Predicate&& predicate, uint16 max = 0) { // We need to use a copy of SummonList here, otherwise original SummonList would be modified StorageType listCopy = storage_; - Trinity::Containers::RandomResizeList<ObjectGuid, Predicate>(listCopy, predicate, max); + Trinity::Containers::RandomResize<StorageType, Predicate>(listCopy, std::forward<Predicate>(predicate), max); for (StorageType::iterator i = listCopy.begin(); i != listCopy.end(); ) { Creature* summon = ObjectAccessor::GetCreature(*me, *i++); |
