mirror of
https://github.com/DarkflameUniverse/DarkflameServer
synced 2024-08-30 18:43:58 +00:00
Move mailbox closing to its script (#740)
This commit is contained in:
parent
c05562a227
commit
ceb374591f
@ -4745,12 +4745,6 @@ void GameMessages::HandleFireEventServerSide(RakNet::BitStream* inStream, Entity
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (args == u"toggleMail") {
|
|
||||||
AMFArrayValue args;
|
|
||||||
args.InsertValue("visible", new AMFFalseValue());
|
|
||||||
GameMessages::SendUIMessageServerToSingleClient(entity, sysAddr, "ToggleMail", &args);
|
|
||||||
}
|
|
||||||
|
|
||||||
// This should probably get it's own "ServerEvents" system or something at some point
|
// This should probably get it's own "ServerEvents" system or something at some point
|
||||||
if (args == u"ZonePlayer") {
|
if (args == u"ZonePlayer") {
|
||||||
// Should probably check to make sure they're using a launcher at some point before someone makes a hack that lets you testmap
|
// Should probably check to make sure they're using a launcher at some point before someone makes a hack that lets you testmap
|
||||||
|
@ -9,3 +9,11 @@ void MailBoxServer::OnUse(Entity* self, Entity* user) {
|
|||||||
args.InsertValue("state", value);
|
args.InsertValue("state", value);
|
||||||
GameMessages::SendUIMessageServerToSingleClient(user, user->GetSystemAddress(), "pushGameState", &args);
|
GameMessages::SendUIMessageServerToSingleClient(user, user->GetSystemAddress(), "pushGameState", &args);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void MailBoxServer::OnFireEventServerSide(Entity* self, Entity* sender, std::string args, int32_t param1, int32_t param2, int32_t param3) {
|
||||||
|
if (args == "toggleMail") {
|
||||||
|
AMFArrayValue args;
|
||||||
|
args.InsertValue("visible", new AMFFalseValue());
|
||||||
|
GameMessages::SendUIMessageServerToSingleClient(sender, sender->GetSystemAddress(), "ToggleMail", &args);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
@ -12,4 +12,5 @@ public:
|
|||||||
* @param user The user that interacted with this Entity.
|
* @param user The user that interacted with this Entity.
|
||||||
*/
|
*/
|
||||||
void OnUse(Entity* self, Entity* user) override;
|
void OnUse(Entity* self, Entity* user) override;
|
||||||
|
void OnFireEventServerSide(Entity* self, Entity* sender, std::string args, int32_t param1, int32_t param2, int32_t param3) override;
|
||||||
};
|
};
|
||||||
|
Loading…
Reference in New Issue
Block a user