mirror of
https://github.com/DarkflameUniverse/DarkflameServer.git
synced 2025-10-10 17:38:08 +00:00
Initial NPC script and gating
- TEMP: Adds guilds gating. - FV Guild Master script added which will toggle the guild UI.
This commit is contained in:
@@ -3,6 +3,7 @@ set(DSCRIPTS_SOURCES_AI_FV
|
||||
"FvFlyingCreviceDragon.cpp"
|
||||
"FvDragonSmashingGolemQb.cpp"
|
||||
"FvFreeGfNinjas.cpp"
|
||||
"FvGuildCreate.cpp"
|
||||
"FvPandaSpawnerServer.cpp"
|
||||
"FvPandaServer.cpp"
|
||||
"FvBrickPuzzleServer.cpp"
|
||||
|
14
dScripts/ai/FV/FvGuildCreate.cpp
Normal file
14
dScripts/ai/FV/FvGuildCreate.cpp
Normal file
@@ -0,0 +1,14 @@
|
||||
#include "FvGuildCreate.h"
|
||||
#include "GameMessages.h"
|
||||
|
||||
// Server script for Guild Master NPC in FV area.
|
||||
// This NPC will react to a user interaction and display
|
||||
// the guild creation screen.
|
||||
|
||||
void FvGuildCreate::OnUse(Entity* self, Entity* user) {
|
||||
AMFStringValue* value = new AMFStringValue();
|
||||
value->SetStringValue("ToggleGuildCreate");
|
||||
AMFArrayValue args;
|
||||
GameMessages::SendUIMessageServerToSingleClient(user, user->GetSystemAddress(), value->GetStringValue(), &args);
|
||||
delete value;
|
||||
}
|
7
dScripts/ai/FV/FvGuildCreate.h
Normal file
7
dScripts/ai/FV/FvGuildCreate.h
Normal file
@@ -0,0 +1,7 @@
|
||||
#pragma once
|
||||
#include "CppScripts.h"
|
||||
|
||||
class FvGuildCreate : public CppScripts::Script {
|
||||
public:
|
||||
void OnUse(Entity* self, Entity* user) override;
|
||||
};
|
Reference in New Issue
Block a user