Skip to content

Commit 7eea5ea

Browse files
committed
Add hook OnNoticeHidden on player disconnect with notice
1 parent e700a73 commit 7eea5ea

File tree

3 files changed

+15
-3
lines changed

3 files changed

+15
-3
lines changed

plugins/rust/RustApp.cs

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@
4949

5050
namespace Oxide.Plugins
5151
{
52-
[Info("RustApp", "Hougan & Xacku & Olkuts", "1.10.3")]
52+
[Info("RustApp", "Hougan & Xacku & Olkuts", "1.10.4")]
5353
public class RustApp : RustPlugin
5454
{
5555
#region Classes
@@ -3100,6 +3100,10 @@ private void OnPlayerDisconnected(BasePlayer player, string reason)
31003100
{
31013101
if (_Worker.Queue.Notices.ContainsKey(player.UserIDString))
31023102
{
3103+
if (_Worker.Queue.Notices[player.UserIDString] == true) {
3104+
Interface.Oxide.CallHook("RustApp_OnCheckNoticeHidden", player);
3105+
}
3106+
31033107
_Worker.Queue.Notices.Remove(player.UserIDString);
31043108
}
31053109

plugins/rust/devblog/236/RustApp.cs

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@
4949

5050
namespace Oxide.Plugins
5151
{
52-
[Info("RustApp", "Hougan & Xacku & Olkuts & King.(ADAPTATION)", "1.10.3")]
52+
[Info("RustApp", "Hougan & Xacku & Olkuts & King.(ADAPTATION)", "1.10.4")]
5353
public class RustApp : RustPlugin
5454
{
5555
#region Classes
@@ -3103,6 +3103,10 @@ private void OnPlayerDisconnected(BasePlayer player, string reason)
31033103
{
31043104
if (_Worker.Queue.Notices.ContainsKey(player.UserIDString))
31053105
{
3106+
if (_Worker.Queue.Notices[player.UserIDString] == true) {
3107+
Interface.Oxide.CallHook("RustApp_OnCheckNoticeHidden", player);
3108+
}
3109+
31063110
_Worker.Queue.Notices.Remove(player.UserIDString);
31073111
}
31083112

plugins/rust/devblog/261/RustApp.cs

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@
4949

5050
namespace Oxide.Plugins
5151
{
52-
[Info("RustApp", "Hougan & Xacku & Olkuts & King.(ADAPTATION)", "1.10.3")]
52+
[Info("RustApp", "Hougan & Xacku & Olkuts & King.(ADAPTATION)", "1.10.4")]
5353
public class RustApp : RustPlugin
5454
{
5555
#region Classes
@@ -3103,6 +3103,10 @@ private void OnPlayerDisconnected(BasePlayer player, string reason)
31033103
{
31043104
if (_Worker.Queue.Notices.ContainsKey(player.UserIDString))
31053105
{
3106+
if (_Worker.Queue.Notices[player.UserIDString] == true) {
3107+
Interface.Oxide.CallHook("RustApp_OnCheckNoticeHidden", player);
3108+
}
3109+
31063110
_Worker.Queue.Notices.Remove(player.UserIDString);
31073111
}
31083112

0 commit comments

Comments
 (0)