No longer spam users to login.
This commit is contained in:
parent
14e55301e1
commit
92d6e7b9fb
2 changed files with 6 additions and 1 deletions
|
|
@ -489,8 +489,12 @@ namespace TShockAPI.DB
|
||||||
public bool HasPermissionToBuildInRegion(TSPlayer ply)
|
public bool HasPermissionToBuildInRegion(TSPlayer ply)
|
||||||
{
|
{
|
||||||
if (!ply.IsLoggedIn)
|
if (!ply.IsLoggedIn)
|
||||||
|
{
|
||||||
|
if (!ply.HasBeenNaggedAboutLoggingIn)
|
||||||
{
|
{
|
||||||
ply.SendMessage("You must be logged in to take advantage of protected regions.", Color.Red);
|
ply.SendMessage("You must be logged in to take advantage of protected regions.", Color.Red);
|
||||||
|
ply.HasBeenNaggedAboutLoggingIn = true;
|
||||||
|
}
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
if (DisableBuild == 0)
|
if (DisableBuild == 0)
|
||||||
|
|
|
||||||
|
|
@ -51,6 +51,7 @@ namespace TShockAPI
|
||||||
public bool HasBeenSpammedWithBuildMessage = false;
|
public bool HasBeenSpammedWithBuildMessage = false;
|
||||||
public bool IsLoggedIn = false;
|
public bool IsLoggedIn = false;
|
||||||
public int UserID = -1;
|
public int UserID = -1;
|
||||||
|
public bool HasBeenNaggedAboutLoggingIn = false;
|
||||||
Player FakePlayer = null;
|
Player FakePlayer = null;
|
||||||
|
|
||||||
public bool RealPlayer
|
public bool RealPlayer
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue