mirror of
https://github.com/MinecraftForge/MinecraftForge.git
synced 2026-11-18 11:29:15 +00:00
Add isServer and isClient methods to LogicalSide (#5606)
* Add helper methods to LogicalSide. * Fix backwards docs.
This commit is contained in:
1 parent
3fe08f149d
commit
201c368325
1 file changed
+17
-1
@@ -21,5 +21,21 @@ package net.minecraftforge.fml;
|
||||
|
||||
public enum LogicalSide
|
||||
{
|
||||
CLIENT, SERVER
|
||||
CLIENT, SERVER;
|
||||
|
||||
/**
|
||||
* @return if the logical side is a server.
|
||||
*/
|
||||
public boolean isServer()
|
||||
{
|
||||
return !isClient();
|
||||
}
|
||||
|
||||
/**
|
||||
* @return if the logical side is a client.
|
||||
*/
|
||||
public boolean isClient()
|
||||
{
|
||||
return this == CLIENT;
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user