Commit Graph

317 Commits

Author SHA1 Message Date
asofold
126c400813 Ensure copy-on-write is used for worldsMap. 2014-07-26 22:20:48 +02:00
asofold
564ce88132 Fix burstEPM violation + add tags for MorePackets + more lenient burst. 2014-07-26 21:42:56 +02:00
asofold
901b2a45a2 Account for server-side lag with burst packets.
Only count as burst, if there was enough lag. Might need adaption to
count lag again for judging the EPM, due to differing window resolution.
2014-07-26 20:49:46 +02:00
MyPictures
584a3d9ab0 Design improvements on Permissions.java
- admin.debug is now in the plugin.yml
- all permissions are now in alphabetic order
- aligned every permissions group
- Added additonal comments
2014-07-26 04:19:51 +02:00
MyPictures
d5c7bb7d27 Merge pull request #2 from NoCheatPlus/master
Downstream merge
2014-07-26 04:04:32 +02:00
MyPictures
ce339c62bd Permissions.java cleanup
- Replaces all tabulators with spacebars
- Splits Commands to Commands and Auxiliary Commands
- Commands and Auxiliary Commands are ordered alphabetically now
2014-07-26 03:54:44 +02:00
asofold
9f03a3ea06 Add direct burst violations and increase epm limit. 2014-07-26 01:06:58 +02:00
asofold
4eefc0c3ff Check speeding permission in the end, thus it will apply to all speeds.
This way, using the speeding permission as a workaround for all
individual speeds is possible. A player moving faster than default will
likely move faster in web too, and so on. There seems to be little
reason for keeping it confined to walking + sprinting only.

Moving it to the end also allows a quicker return for walking and
sprinting, though that policy might be questionable as well, because
some calculations might use hAllowedDistance, subject to review.
2014-07-25 18:51:18 +02:00
asofold
2257ac2f71 Add exception for MILK_BUCKET. 2014-07-25 15:22:01 +02:00
asofold
552beed739 Add limiting of "bursts" in moving.morepackets. 2014-07-23 23:31:31 +02:00
asofold
039c4b407f Add configuration to morepackets for "eps", i.e. events per second. 2014-07-21 14:39:17 +02:00
asofold
d5c1e289a9 Count "just look" moves same way.
As CB reduces the number of events, this should be fine. The cause of
trouble that lead to skipping these had been elsewhere.
2014-07-21 14:24:06 +02:00
asofold
7de214abae Only check for lag if there is windows to burn. 2014-07-21 14:22:45 +02:00
asofold
1441859ced Move the new packet frequency check to a static utility, minor cleanups.
* Always use lag.
* Let the morepackets check decide how to treat "just look" events.
* Optimizations.
* Renames.
2014-07-18 15:54:46 +02:00
asofold
3d5bbbbedd Server-side lag adaption: more strict if there is no lag. 2014-07-18 03:04:32 +02:00
asofold
58a7c15966 Check violation vs. the less strict limit. 2014-07-18 02:33:13 +02:00
asofold
4ee4e6f08d Don't count empty ones. 2014-07-18 02:25:38 +02:00
asofold
27d35c1208 Not just block changes. 2014-07-18 02:15:49 +02:00
asofold
db7ac2bd80 Only count moving.morepackets on non-zero distances. 2014-07-18 02:05:26 +02:00
asofold
f79c89b45a MIX UP. 2014-07-18 01:47:55 +02:00
asofold
e3cdd761ec [BLEEDING] Attempt to make moving.morepackets less strict. 2014-07-18 01:45:58 +02:00
asofold
85a104ed75 [BLEEDING] Switch moving.morepackets to use Actionfrequency. 2014-07-18 00:21:19 +02:00
asofold
7cc936878e Simplify/optimize morepackets checks. 2014-07-17 20:30:01 +02:00
asofold
b6c146ce64 Remove getKeepAliveTime from MCAccess.
It does not seem to become accessible any time soon, while packet level
access allows to fetch it.
2014-07-17 14:33:38 +02:00
asofold
96462dab90 Allow ConfigManager.getConfig... from any thread (copy on write).
This allows fast config getting from any thread, without need to know if
it is the main thread.
2014-07-16 14:55:31 +02:00
asofold
7b6305de78 Packet checks adjustments and renaming.
* More appropriate names.
SoundDistance
* Plus wither plus dragon.
* Horizontal distance.
2014-07-16 13:50:04 +02:00
asofold
d473f19247 It's THEM. 2014-07-14 23:08:15 +02:00
asofold
39e2a86472 [BLEEDING] Extra method for set-back + reset positions differently.
Setting back players on PlayerMoveEvents:
* Reset internal from/to tracking the set-back location.
* Use an extra method for that.
2014-07-14 22:49:37 +02:00
asofold
4ebe911509 Abort ray-tracing if there is no advance. Formatting + numbers.
If there is no advance on any axis, loop should be stopped.
2014-07-13 03:19:28 +02:00
asofold
aba5674f6a Correct log messages. 2014-07-13 01:45:39 +02:00
asofold
aa91a39eea Some Formatting. 2014-07-13 01:14:17 +02:00
asofold
e09d024101 Un-fix tempkickillegal issue: Do kick if location could not be restored. 2014-07-13 01:13:50 +02:00
asofold
607407d4fa Fix tempkickillegal setting being ignored. 2014-07-13 00:29:52 +02:00
asofold
74e6844e00 Check child individual child permissions for checks.blockplace.against. 2014-07-06 21:36:18 +02:00
asofold
5d8f77f309 Change "ncp ban ..." command to use the vanilla command.
This should be better in case the vanilla command allows UUIDs some day.
At least during testing in uuids did not work, so we added a warning
message if uuids are used for banning.

Using player names for actions should be safe anyway.
2014-06-15 02:57:24 +02:00
asofold
754fea92d8 Add some utility methods for names/uuids (taken from TrustCore).
Someone remind me of rendering TrustCore "uploadable" or to just upload
it.
2014-06-15 02:54:50 +02:00
asofold
24aecb58d3 Set dependency for NCPCore to Bukkit 1.7.9-R0.2.
This might allow to add compatibility stuff similar to BridgeHealth,
just for UUIDs.

Shortly tested on 1.7.9, 1.7.2 and 1.5.2 (no joke).
2014-06-15 02:52:41 +02:00
asofold
fc83b884b3 Whoops. 2014-06-15 01:34:22 +02:00
asofold
b25b2be62c Hide some more warnings behind BlockProperties. 2014-06-14 22:29:10 +02:00
asofold
ae9415a012 More use of Material instead of ids... 2014-06-14 20:45:51 +02:00
asofold
c23e5e15a7 Remove unused calls. 2014-06-14 20:42:46 +02:00
asofold
785de7c0f4 Suppress deprecation warnings for BlockProperties.
Access by id may or may not be changed internally, depending on what
happens on the API side.

For performance reasons we might like to do without passing on extra
stuff like Material, or even do String-comparison.

If ids will become more expensive to use than other ways, or if it will
be possible/accepted that ids get reused during runtime, then we will
have to change all internals.
2014-06-14 20:39:32 +02:00
asofold
98f101e9ff Import cleanup. 2014-06-14 20:33:30 +02:00
asofold
f53cf96e78 Fix test failure due to invalid input.
A merge can happen if the maximum distance between any two points
exceeds the merge distance, because LocationTrace attempts to balance
distances entries. Thus this test must not bne able to walk further than
the merge distance.
2014-06-14 20:22:02 +02:00
asofold
6afaf4ebbd Formatting, shuffling, commenting. 2014-06-14 16:40:43 +02:00
asofold
75224adf63 Reduce use of using block-ids in more places.
* Use Material directly in more places.
* Hide id-getting within BlockProperties.

TODO:
* BlockInit, BlockFlags + use of those.
* Possibly other.
2014-06-13 12:01:44 +02:00
asofold
5bfad6016c Small cleanup for fastbreak: creative mode is not handled by this check. 2014-06-13 11:12:50 +02:00
asofold
587236dfdc Alter resetting of FastConsume timings.
* Reset to time, if time ran backwards.
* Reset to time instead of 0, on eating.

TODO: Switch to Monotonic.
2014-06-13 00:39:42 +02:00
asofold
56bab0a3ae Cancel various actions for dead players. Config pending. 2014-06-04 23:52:07 +02:00
asofold
a75e32b2d3 Ra-add the instant-break compatibility code.
For whatever reason it was commented out, it is now put back, assuming
that the reason was "it did not help with mcMMO", because mcMMO used to
fire extra BlockBreakEventS.

Now we use a tri-state and set it to MAYBE if instantBreak is set
already on lowest priority, to have a rough indicator if a plugin set
it, or if the server might have done it. Later we might let FastBreak
assume some maximal duration for either case, instead of ignoring these.
2014-06-04 22:31:31 +02:00