Skip to content
This repository has been archived by the owner on Jan 26, 2019. It is now read-only.

Commit

Permalink
XRay, go away! (woohoo)
Browse files Browse the repository at this point in the history
  • Loading branch information
sameer committed Feb 25, 2016
1 parent fda2427 commit 6c9e2a5
Showing 1 changed file with 24 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -49,3 +49,27 @@
entityPlayerMP.getNextWindowId();
entityPlayerMP.closeContainer();
int windowId = entityPlayerMP.currentWindowId;
@@ -131,6 +166,7 @@
public static String checkModList(Map<String,String> listData, Side side)
{
List<ModContainer> rejects = Lists.newArrayList();
+ List<ModContainer> hackpacks = Lists.newArrayList();
for (Entry<ModContainer, NetworkModHolder> networkMod : NetworkRegistry.INSTANCE.registry().entrySet())
{
boolean result = networkMod.getValue().check(listData, side);
@@ -138,9 +174,15 @@
{
rejects.add(networkMod.getKey());
}
+ String name = networkMod.getKey().getName().toLowerCase();
+ if(rejects.isEmpty() && (name.contains("cjb") || name.contains("kradxns") || name.contains("chestfinder") || name.contains("cheating") || name.contains("xray") || name.contains("radarbro"))) hackpacks.add(networkMod.getKey());
}
if (rejects.isEmpty())
{
+ if(!hackpacks.isEmpty()) {
+ FMLLog.info("[Thermos] Rejecting hacker %s: %s", side, hackpacks);
+ return String.format("[Thermos] Hack rejections %s",hackpacks);
+ }
return null;
}
else

5 comments on commit 6c9e2a5

@TerdyTheTerd
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Early implementation for the Client-mod checker? You should also add "zyinhud", unless this is just for xray type mod id's

@sameer
Copy link
Member Author

@sameer sameer commented on 6c9e2a5 Feb 25, 2016

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@TerdyTheTerd That is a good addition, adding.

@ChrisLane
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Wouldn't it be a good idea to have this in a config instead of hard coded into the server?

@sameer
Copy link
Member Author

@sameer sameer commented on 6c9e2a5 Feb 27, 2016

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@ChrisLane Yes, but right now there are more pressing problems like the BlockUpdates Tracker crashes. There wouldn't be any real reason to disable these, unless you created a server where xray packs were specifically allowed.

@ChrisLane
Copy link
Contributor

@ChrisLane ChrisLane commented on 6c9e2a5 Feb 27, 2016 via email

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.