[Free] Anti-Void teleport plugin [Open-Source]

Status
This thread has been locked.

BrianGrug

Full time failure
Supreme
Feedback score
56
Posts
1,473
Reactions
995
Resources
1
PebbleHost
High performance, consistent uptime and fast support. Minecraft hosting that just works.

Ghast

Founding Father of Hypocrisy - https://artemis.ac
Supreme
Feedback score
54
Posts
2,096
Reactions
3,285
Resources
79

BrianGrug

Full time failure
Supreme
Feedback score
56
Posts
1,473
Reactions
995
Resources
1
What would be the point of this plugin? Not trying to hate just wondering.
skyblock servers where the owners don't be dicks/make it so the only way you don't die in the void is /fly (with paid ranks)
Nah, the main point is to stop this other guy from selling a simple plugin like this for 7$ Kappa
 

BrianGrug

Full time failure
Supreme
Feedback score
56
Posts
1,473
Reactions
995
Resources
1

BrianGrug

Full time failure
Supreme
Feedback score
56
Posts
1,473
Reactions
995
Resources
1
I think it's not the best way to do it, everytime a player moves you add a Location to a map?
Yeah, I don't like using PlayerMoveEvent but I couldn't really think of another way, if you have a better way, let me know and I'll use it :p
 

BrianGrug

Full time failure
Supreme
Feedback score
56
Posts
1,473
Reactions
995
Resources
1
Neither should player nor location object be saved into the map.
Especially when you aren't removing, neither are you using WeakHashMap.

Which would cause huge memory leaks.

Then you are using PlayerMoveEvent for detecting void?
You realize that PlayerMoveEvent is triggered in smallest measures when you just change your aim, now imagine how much of a triggering is happening whilst having 100+ players online.

Again causing huge performance lag.

If anything you work around with EntityDamageEvent, where you have cause of damage (https://hub.spigotmc.org/javadocs/s...ntity/EntityDamageEvent.DamageCause.html#VOID).

(No harsh words, just trying to help and improve yourself along with your code)
No, I 100% agree, I appreciate it, as I still am learning a lot. Thanks, I'll be sure to take a look into this!
 

Receiver

Feedback score
1
Posts
44
Reactions
10
Resources
0
If you want to use PlayerMoveEvent first check if the player has moved, at least
 

BrianGrug

Full time failure
Supreme
Feedback score
56
Posts
1,473
Reactions
995
Resources
1
If you want to use PlayerMoveEvent first check if the player has moved, at least
Alrighty, thanks! I'll take a look for sure :)
 

BrianGrug

Full time failure
Supreme
Feedback score
56
Posts
1,473
Reactions
995
Resources
1
Pushed an update to hopefully fix some of the bugs :)
 
Status
This thread has been locked.
Top