mirror of
https://github.com/DarkflameUniverse/DarkflameServer
synced 2024-08-30 18:43:58 +00:00
Fix non-standard lambda.
When this commit is applied it fixes use of non-standard lambda.
This commit is contained in:
parent
6f6be5ec47
commit
c8177563e9
@ -3,20 +3,15 @@
|
|||||||
#include "dLogger.h"
|
#include "dLogger.h"
|
||||||
|
|
||||||
void BuccaneerValiantShip::OnStartup(Entity* self) {
|
void BuccaneerValiantShip::OnStartup(Entity* self) {
|
||||||
const auto skill = 982;
|
self->AddCallbackTimer(1.0F, [self]() {
|
||||||
const auto behavior = 20577;
|
|
||||||
const auto skillCastTimer = 1.0F;
|
|
||||||
|
|
||||||
self->AddCallbackTimer(skillCastTimer, [self]() {
|
|
||||||
auto* skillComponent = self->GetComponent<SkillComponent>();
|
auto* skillComponent = self->GetComponent<SkillComponent>();
|
||||||
auto* owner = self->GetOwner();
|
auto* owner = self->GetOwner();
|
||||||
|
|
||||||
if (skillComponent != nullptr && owner != nullptr) {
|
if (skillComponent != nullptr && owner != nullptr) {
|
||||||
skillComponent->CalculateBehavior(skill, behavior, LWOOBJID_EMPTY, true, false, owner->GetObjectID());
|
skillComponent->CalculateBehavior(982, 20577, LWOOBJID_EMPTY, true, false, owner->GetObjectID());
|
||||||
|
|
||||||
// Kill self if missed
|
// Kill self if missed
|
||||||
const auto selfSmashTimer = 1.1F;
|
self->AddCallbackTimer(1.1F, [self]() {
|
||||||
self->AddCallbackTimer(selfSmashTimer, [self]() {
|
|
||||||
self->Kill();
|
self->Kill();
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user