Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
65 changes: 58 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,27 +1,28 @@
### Latest stable version: v1.6.5
### Latest stable version: v1.6.5 | Latest alpha version: Download from the Discord or compile from `main`

The latest stable version can currently only be found on Modrinth https://modrinth.com/plugin/raycasted-anti-esp/ or by compiling from `v1.6.x`. The latest alpha version can be found on the [Discord](https://discord.gg/hGTRAK2hNM) or by compiling from `main`.

This is a predominantly async plugin for PaperMC and its forks that hides/culls entities (and tile entities) from players if they do not have line-of-sight.
This is an async plugin for PaperMC and its forks that hides entities (including players) and tile entities (blocks such as chests, banners, signs, etc) from players if they do not have line-of-sight.

The supported versions are 1.21.x PaperMC and Pufferfish. Other server versions and software may work too. v2 alpha builds support 26.x.
The supported versions are 1.20.6+, with MC 26.x support in v2 only. Only Paper and derivative software is supported, not Spigot.

## Use cases:

- Prevent cheating (anti-esp hacks)
- Block usage of pie-ray to locate underground bases
- Prevent mods such as mini-maps or cheat clients from displaying the locations of hidden entities
- Increase client-side performance for low-end devices
- Massive megabases containing hundreds of armour stands, item frames, banners etc can cause performance issues on low-end devices unable to process so many entities. REO will cull those entities for the client, reducing the number of entities to process.
- Massive megabases containing hundreds of armour stands, item frames, banners etc can cause performance issues on low-end devices unable to process so many entities. Raycasted AntiESP will cull those entities for the client, reducing the number of entities to process.
- Hide nametags behind walls
- Yes, this plugin is a bit overkill for doing that, yes you can do it anyways.

## Dependencies:
- Packetevents (soft depend)
- Only needed if you are using the cull-players option and wish for the players to remain in the tablist
- Packetevents
- In v1: Only needed if you are using the cull-players option and wish for the players to remain in the tablist
- In v2: Required for all features

## Known issues:
- Due to the nature of the plugin, there will be a short delay once an entity should be visible before it appears, causing it to appear like it "popped" into view. This issue is partially resolved by turning engine-mode to 2, and is worse for players with higher ping.
- Due to the nature of the plugin, there will be a short delay once an entity should be visible before it appears, causing it to appear like it "popped" into view.

## Versioning:
Note that the following versioning information only applies to v2 and beyond.
Expand All @@ -32,5 +33,55 @@ Each of these has its own versioning system. Locatable-lib and the logging api b

In addition to the versions for each module, there is also an overall version for each platform binary, which is the version that is advertised in the description and file name, and is used for update checks. This version is a combination of the core and platform adapter versions, in the format `{core version}-PlatformName-{platform adapter version}`. This allows all platforms to share the same first three version numbers, while still allowing for differences in the platform adapter versions.

## Credits:

- Cubicake (Sole developer, creator and maintainer of RaycastedAntiESP)

### Special mentions:

- Strokkur424 and other contributors to [StrokkCommands](https://github.com/Strokkur424/StrokkCommands), an LGPL-licensed open-source annotation-based brigadier command tree generator.
- While StrokkCommands is not essential for the functioning of the project, it makes handling commands infinitely easier.
- Retrooper, Booky10, and all other contributors to [PacketEvents](https://github.com/retrooper/packetevents), a GPL-licensed open-source library for handling minecraft packets.
- PacketEvents is essential for the functioning of the plugin, as it allows for handling of packets across multiple platforms and Minecraft versions.
- All contributors to Paper and its upstream projects Spigot and Bukkit, without which none of this would be possible.

### Note about in-game attributions and other (A)GPL requirements:
The plugin includes the command `/raycastedantiespCredits`, which displays a list of all authors and contributors, the license and a link to the source code. It can be run by all players. This command is intended to satisfy the "preservation of specified reasonable legal notices or author attributions" requirement of the AGPLv3 license in an easily accessible way for all users of the plugin, including players on a multiplayer server. If you fork this repository and remove the command you must include some other easily accessible way for all users of your fork to view the same information, as required by the AGPLv3.

This command has been deliberately named a long and unwieldy name to avoid clashing with any commands your server may wish to add, and does not pose any risks to your server as there is no unfair advantage which can be gained due to knowledge of the plugin's existence on your server.

It is **illegal** to remove the credits without providing an alternative, equally prominent way for users to view the same information. If for some reason crediting people who have worked on a feature for your server for free is a problem for you, you can contact Cubicake on discord (@cubicake) or make an issue to discuss receiving a special commercial/closed licensed version with all attributions, credits, and source code links removed.

Using external software such as a command-hiding plugin to hide the command is **still illegal**, so please do not try to circumvent the requirement to provide attributions, credits, and source code links to users of your server.

Requesting a commercial/closed license is also required if you wish to link (as defined by the AGPL) a closed source project to this project.

An example of a suitable alternative to the command would be a single book-gui or dialog which contains all attributions, licenses, disclaimers, and source code links for all programs used by the server as long as the gui is easily accessible to all users of the server.

## Contributions:
Contributions via pull requests are welcome. See [CONTRIBUTING.md](CONTRIBUTING.md) for details.

## Forking:

Please see the [AGPL v3 license](LICENSE)—especially section 5, section 7, and section 13—before forking this repository, as there are some specific legal requirements for forks.

In summary, translated into layman, plugin-specific terms, the most important requirements for forks are as follows:
1. Forks must not remove any names currently present in the authors/contributors list in the plugin's description, as this falls under the "preservation of specified reasonable legal notices or author attributions".
2. Forks must not claim to be the original software, as this falls under the "no misrepresentation of the origin of the material".
3. Per section 5 subsection c, derivative works such as forks must remain licenced under AGPLv3, and must include a copy of the license with the work. To be clear, copying any non-trivial amount of code from this repository into your own repository, whether via making a fork, directly copying and pasting or other means, makes it a derivative work and obligates you to license your derivative work under the AGPL v3. You must then include a copy of the license and make the source code (not decompiled code) accessible to all users of your program, explicitly including players on a multiplayer server as well as the server owners.
4. "Appropriate Legal Notices" such as the copyright notice, license notice, disclaimer, and link to the source code must be preserved. Currently this is implemented via the /raycastedantiespCredits command, and while you are not obligated to keep this specific implementation, if you remove the command you must provide an equally prominent way for all users of the plugin (including players on a multiplayer server) to easily view the same information.

`games.cubi.raycastedantiesp.paper.commands.Attribution` has been written with forks in mind, and a template has been left for forks to modify so that the AGPLv3 license can be obeyed with minimal effort from forkers.

## Copyright and Disclaimer:
Copyright © 2025-2026 Cubicake and Contributors

This project is licensed under the GNU Affero General Public License v3.0 only (AGPLv3). You may copy, modify, and redistribute this software only in compliance with the terms of that licence. A copy of the licence is provided in the LICENSE file.

If you modify and deploy this software for remote network interaction, including operating a public multiplayer server, you must make the complete corresponding source code of the modified version available to users interacting with the software over the network, as required by section 13 of the AGPLv3.

Any modified versions must be clearly marked as modified and must not be misrepresented as the original project.

This software is provided “as is”, without warranty of any kind, express or implied, including but not limited to the warranties of merchantability, fitness for a particular purpose, and noninfringement. In no event shall the authors or copyright holders be liable for any claim, damages, or other liability arising from, out of, or in connection with the software or the use of the software.

The AGPL is the sole license this program is governed by. All statements found in this copyright notice and disclaimer, the above forking guidelines, or anywhere else in this program should be considered merely guidelines and interpretations of the AGPL unless they are direct extracts of the AGPL. If any statement conflicts with the AGPL, the AGPL takes legal precedence over any such statement. However, any such conflicting statements should be taken as good-faith non-binding requests by the authors.
Original file line number Diff line number Diff line change
@@ -1,3 +1,11 @@
/*
* SPDX-License-Identifier: AGPL-3.0-only
* Copyright © 2026 Cubicake.
* This file is part of RaycastedAntiESP.
* RaycastedAntiESP is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License v3.0 only, which can be accessed at https://www.gnu.org/licenses/agpl-3.0.html.
* See README.md for warranty disclaimer and further information.
*/

package games.cubi.raycastedantiesp.paper;

import games.cubi.logs.CheckPreviousLogForError;
Expand Down Expand Up @@ -107,7 +115,7 @@ public void warning(Throwable throwable, @Range(from = 1, to = 10) int level, Cl

@Deprecated @Override
public void debug(String message) {
forwardLog(message, Level.INFO, 10);
forwardLog(message, Level.INFO, 1);
}

@Override
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,16 @@
/*
* SPDX-License-Identifier: AGPL-3.0-only
* Copyright © 2026 Cubicake.
* This file is part of RaycastedAntiESP.
* RaycastedAntiESP is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License v3.0 only, which can be accessed at https://www.gnu.org/licenses/agpl-3.0.html.
* See README.md for warranty disclaimer and further information.
*/

package games.cubi.raycastedantiesp.paper;

import games.cubi.raycastedantiesp.core.Core;
import games.cubi.raycastedantiesp.paper.commands.Attribution;
import games.cubi.raycastedantiesp.paper.commands.AttributionBrigadier;
import games.cubi.raycastedantiesp.paper.commands.RaycastedAntiESPCommandBrigadier;
import games.cubi.raycastedantiesp.paper.engine.PaperSimpleEngine;
import games.cubi.raycastedantiesp.packetevents.config.PacketEventsBlockProcessorConfig;
Expand Down Expand Up @@ -91,6 +101,7 @@ public void onEnable() {

this.getLifecycleManager().registerEventHandler(LifecycleEvents.COMMANDS.newHandler(event -> {
RaycastedAntiESPCommandBrigadier.register(event.registrar());
AttributionBrigadier.register(event.registrar());
}));
//bStats
metricsCollector = new MetricsCollector(this, config);
Expand All @@ -103,6 +114,7 @@ public void onEnable() {
}
}
}, 1200, 1200);*/
/*Do not delete, this is a legal notice*/Attribution.sendAttributionMessage(Bukkit.getConsoleSender()); // Legal notice as required by AGPLv3, it prominently offers users of this plugin the source code and displays an appropriate copyright notice. If you are a fork developer, do NOT remove this unless you have a thorough understanding of the AGPL and have replaced it with a suitable equivalent notice which is "prominently visible", displays the copyright notice, and includes a link to the source code of your fork which is accessible to all users of the plugin.
}

private String parseTrackers(Set<Player> trackers) {
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,68 @@
/*
* SPDX-License-Identifier: AGPL-3.0-only
* Copyright © 2026 Cubicake.
* This file is part of RaycastedAntiESP.
* RaycastedAntiESP is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License v3.0 only, which can be accessed at https://www.gnu.org/licenses/agpl-3.0.html.
* See README.md for warranty disclaimer and further information.
*/

package games.cubi.raycastedantiesp.paper.commands;

import net.strokkur.commands.Command;
import net.strokkur.commands.Executes;
import org.bukkit.command.CommandSender;

@Command("raycastedantiespCredits") //Deliberately an obscure name and not "attribution" or "credits" to avoid being annoying to server owners. Not permission-gated as all players need to be able to access it to comply with the AGPLv3 licence.
public class Attribution {
public static final byte READ_COMMENTS_BEFORE_EDITING_OR_DELETING_CLASS_OR_FACE_LEGAL_ACTION = 0; //Provocative name to make sure people actually read the comments.
/*
Please note that removing this command without providing an alternative, equally (or more) prominent way to view this information is a violation of the AGPLv3 licence, which may result in legal action.
If you are forking this project, read the below note for fork developers to see how to modify the notice to remain AGPLv3 compliant.

If you wish to acquire a copy of the plugin without the obligation to display this notice or equivalent, you may discuss purchasing a commercial licence by contacting Cubicake via Discord (@Cubicake) or by making a GitHub issue at https://github.com/Cubicake/RaycastedAntiESP

Note that using external software to remove this command (for example by using a command blocker plugin to block players from using this command) is ALSO illegal.
* */
@Executes
public void execute(CommandSender sender) {
sendAttributionMessage(sender);
}

public static void sendAttributionMessage(CommandSender sender) {
sender.sendRichMessage("<white>This server runs <gold><click:open_url:'https://github.com/Cubicake/RaycastedAntiESP'>RaycastedAntiESP</click></gold>, a packet-based anti-esp plugin.\n" +
"\n" +
"<white>The plugin is <dark_green>copyright © 2025-2026 Cubicake and Contributors</dark_green>, and licenced under the <dark_green>AGPLv3 licence</dark_green>, which requires the source code to be available to all users of the plugin, including you. \n" +
"<white>As such, the source code can be found at <u><blue><hover:show_text:'Click to view source'><click:open_url:'https://github.com/Cubicake/RaycastedAntiESP'>https://github.com/Cubicake/RaycastedAntiESP</click></hover></blue></u>.");
/* Fork developers: Comment out the above message and uncomment this one, making sure to replace the placeholders with the appropriate information about your fork.
// Some notes for fork developers:
// While you are allowed to modify the message below, you must still include all of the legally obligated information. As such, I recommend you only modify the {bracketed} placeholders and the formatting of the message.
// The legally obligated information you must include is as follows:
// 1. You must not claim to be the original creator of the project. Therefore, the notice must still clearly include a mention of "copyright © 2025-2026 Cubicake and Contributors"
// 2. You must include a link to the source code of your fork, which must be accessible to all players on all servers running your plugin, and include the full source code of your fork. This is a requirement of the AGPLv3 licence, which requires that all users of the software have access to the source code. Therefore, you must include a link to the source code of your fork in the message, and it must be easily accessible to users of the plugin.
// 3. You may not remove this notice without providing an alternative **prominent** notice containing a link to the source code and the original copyright notice.

sender.sendRichMessage("<white>This server runs a fork of <gold><click:open_url:'https://github.com/Cubicake/RaycastedAntiESP'>RaycastedAntiESP</click></gold> called {YOUR_FORK_NAME_HERE}, a packet-based anti-esp plugin.\n" +
"\n" +
"<white>The original plugin is <dark_green>copyright © 2025-2026 Cubicake and Contributors</dark_green>, with this fork copyright © 2025-2026 {YOUR_NAMES_HERE}. The plugin in its entirety is licenced under the <dark_green>AGPLv3 licence</dark_green>, which requires the source code to be available to all users of the plugin, including you. \n" +
"<white>As such, the source code can be found at <u><blue><hover:show_text:'Click to view source'><click:open_url:'{YOUR_SOURCE_CODE_LINK_HERE}'>{YOUR_SOURCE_CODE_LINK_HERE}</click></hover></blue></u>.");
*/
sender.sendRichMessage("A copy of the AGPLv3 Licence can be found at <hover:show_text:'Click to view licence'><u><blue><click:open_url:'https://www.gnu.org/licenses/agpl-3.0.html'>https://www.gnu.org/licenses/agpl-3.0.html</click></blue></u></hover>.\n" +
"\n" +
"Disclaimer: This software is provided “as is”, without warranty of any kind, express or implied, including but not limited to the warranties of merchantability, fitness for a particular purpose, and noninfringement.\n" +
"In no event shall the authors or copyright holders be liable for any claim, damages, or other liability arising from, out of, or in connection with the software or the use of the software.");
sender.sendRichMessage("Credits:\n" +
"\n" +
"Plugin developers:\n" +
"- Cubicake (Sole developer, creator and maintainer of RaycastedAntiESP)\n" +
/*
* "- Feel free to add your name here as the developer of your fork!\n" +
* */
"\n" +
"Libraries:\n" +
"- Strokkur424 and other contributors to <click:open_url:'https://github.com/Strokkur424/StrokkCommands'><u><hover:show_text:'Click to view Github repository'><blue>StrokkCommands</blue></hover></u></click>, an LGPL-licensed open-source annotation-based brigadier command tree generator.\n" +
"- Retrooper, Booky10, and all other contributors to <click:open_url:'https://github.com/retrooper/packetevents'><u><blue><hover:show_text:'Click to view Github repository'>PacketEvents</hover></blue></u></click>, a GPL-licensed open-source library for handling minecraft packets.");
assert READ_COMMENTS_BEFORE_EDITING_OR_DELETING_CLASS_OR_FACE_LEGAL_ACTION == 0; // Make IDEs highlight the variable to make it easier to read.
}

public static final String attributionCommandDescription = "<green>/raycastedantiespCredits - View copyright notice and source code link (required to be displayed by the AGPLv3 licence)";
}
Loading