DarkflameServer/dScripts/02_server/Map/njhub/ImaginationShrineServer.cpp

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

17 lines
436 B
C++
Raw Normal View History

#include "ImaginationShrineServer.h"
#include "QuickBuildComponent.h"
void ImaginationShrineServer::OnUse(Entity* self, Entity* user) {
// If the rebuild component is complete, use the shrine
auto* quickBuildComponent = self->GetComponent<QuickBuildComponent>();
if (quickBuildComponent == nullptr) {
return;
}
if (quickBuildComponent->GetState() == eRebuildState::COMPLETED) {
// Use the shrine
BaseUse(self, user);
}
}