Archiviert
13
0
Commit graph

972 Commits

Autor SHA1 Nachricht Datum
Kristian S. Stangeland
65e665aa59 Don't compare NBT names - they are no longer persistant. 2013-12-04 15:55:17 +01:00
Kristian S. Stangeland
c137640fee Updating ProtocolLib for 1.7.2.
Still a work in progress.
2013-12-04 04:17:02 +01:00
Kristian S. Stangeland
28b4874c60 Depreciate the Packets class - it is not safe to rely on integers. 2013-12-01 06:45:59 +01:00
Kristian S. Stangeland
c9fd6b4b93 Avoid item stack IDs if we can. 2013-11-23 05:01:52 +01:00
Kristian S. Stangeland
125bfbad30 TemporaryPlayer doesn't support getName(), so use getAddress() for maps
In addition, adding a useful ConcurrentPlayerMap that doesn't store 
player instances directly, and can even handle TemporaryPlayers.
2013-11-23 05:00:34 +01:00
Kristian S. Stangeland
00b297475c Switching to 1.6.4 in the unit tests. 2013-11-19 13:14:47 +01:00
Kristian S. Stangeland
86f04f53b5 Allow packet constructor to properly unwrap other Bukkit wrappers. 2013-11-19 00:50:55 +01:00
Kristian S. Stangeland
ba6c6e5abf Improve the documentation of getTypeID().
It might be confused with getIndex(), so emphasize the fact that it 
returns the data type ID of the object, and not its index.
2013-11-18 22:25:05 +01:00
Kristian S. Stangeland
3d6cfbf1e1 Ensure the MinecraftReflection.isCLASS-method return false for NULL. 2013-11-18 17:55:31 +01:00
Kristian S. Stangeland
4be582ef87 Use the MCPC JAR remapper when loading classes. Fixes #11
This will allow plugins to use MinecraftReflection.getMinecraftClass() 
in both CraftBukkit and MCPC.
2013-11-16 03:04:00 +01:00
Kristian S. Stangeland
8c8ca3746b Correctly wrap and unwrap ItemStacks in WrappedWatchableObject.
This should make it possible to set and retrieve watchable objects 
of the type ItemStack.
2013-11-10 20:47:32 +01:00
Kristian S. Stangeland
b6809f6ce6 Correctly remove packet listeners from the sorted lists.
Essentially, the SortedCopyOnWriteArray.remove() method would remove 
any packet listeners following a match, instead of just the match 
itself. 

Thanks to Libraryaddict for discovering the bug. :)
2013-11-01 04:45:30 +01:00
Kristian S. Stangeland
c416877f35 Add support for retrieving WorldType in MCPC 2013-11-01 02:09:59 +01:00
Kristian S. Stangeland
47134b43cc Adding automatic GamePhase detection.
This should solve the infamous UNKNOWN ORIGIN problem, especially in 
MCPC++.
2013-10-31 01:55:55 +01:00
Kristian S. Stangeland
68c0a3c1dc Ignore fake players in MCPC++ 2013-10-28 19:09:11 +01:00
Kristian S. Stangeland
f3b2b0bf3b Remove spigot listener when the plugin is disabling. 2013-10-18 03:45:06 +02:00
Kristian S. Stangeland
3ea5b5d62f Increment to 2.7.4-SNAPSHOT 2013-10-18 03:44:49 +02:00
Kristian S. Stangeland
6a0600cd7f Update to the latest version of Gravity's Updater class. 2013-10-17 02:14:02 +02:00
Kristian S. Stangeland
42395abe75 Add a small hint for plugin authors to the "unknown origin" error. 2013-10-14 19:09:59 +02:00
Kristian S. Stangeland
73804d45df Make UnknownHostException more low-key. They are to be expected.
Whenever the update procedure is ongoing, and the server temporarily 
lost connectivity to the internet (or more likely, dev.bukkit.org is 
down), a huge exception log will be printed in the console. See ticket
134 for a real life example.

This is completely out of propotion to the problem at hand (connection
problems), so we will replace the error log with a simple warning 
message.
2013-10-11 02:49:07 +02:00
Kristian S. Stangeland
8a4982e169 Add the test plugin to the plugin manager, just in case. 2013-10-07 21:50:07 +02:00
Kristian S. Stangeland
c058498267 Add a timeout to server startup and the ping test. 2013-10-07 05:16:20 +02:00
Kristian S. Stangeland
09cc024a3f Added a simple integration test to ensure ProtocolLib actually works.
We do this by running a CraftBukkit server in target/server, and 
copying ProtocolLib to its plugin folder.
2013-10-07 04:29:21 +02:00
Kristian S. Stangeland
47ffa7f62d Bumping to version 2.7.3 2013-10-06 02:35:07 +02:00
Kristian S. Stangeland
c2abc4277b Fix a critial bug that prevents PB from loading.
This was caused by a previous patch that corrected the version parser 
for special Spigot versions with a snapshot protocol enabled. 
Unfortunately, this also causes the comparer to fail on normal 
version ...

Somehow, that got through testing.
2013-10-06 02:34:33 +02:00
Kristian S. Stangeland
e4c193440e Correct all JavaDoc problems. 2013-10-05 21:42:19 +02:00
Kristian S. Stangeland
b1b4bc7fb3 Bumping to version 2.7.2 2013-10-05 20:20:43 +02:00
Kristian S. Stangeland
a63e03bf16 Version 1.6.4 is working fine. 2013-10-05 20:20:08 +02:00
Kristian S. Stangeland
b53908ef0f These fields will be updated and read from different threads.
Mark them as volatile just in case.
2013-09-30 19:27:22 +02:00
Kristian S. Stangeland
75f6cff5a5 Experimental: Correct a possible race condition with Spigot. 2013-09-28 17:22:06 +02:00
Kristian S. Stangeland
1b1f36c5d6 Attempt to handle snapshot versions by assuming Minecraft version.
The snapshot version contains a release date, so we'll simply compare
that against a known release date of a Minecraft version. It it's 
later, we know it is at least a minor version above, and vice versa.
2013-09-28 16:25:30 +02:00
Kristian S. Stangeland
2001c15132 Add the ability to track the amount of time spent by each plugin.
ProtocolLib can now keep track of the amount of time spent by each 
listener (for each packet), generated as a report file. This is 
done in the new "protocol timings" command.
2013-09-20 22:35:59 +02:00
Kristian S. Stangeland
4e2af45428 More descriptive error message when an entities tracker is not found. 2013-09-15 20:42:07 +02:00
Kristian S. Stangeland
bed74f6ab6 Cleanup proxy packet injector in Spigot too. FIXES 127 2013-09-13 09:35:53 +02:00
Kristian S. Stangeland
57ad8d8aaa Lets preserve the injection time, just in case. 2013-09-10 02:15:16 +02:00
Kristian S. Stangeland
dc8b23d48b Intercept packets sent during the handling of PlayerLoginEvent. 2013-09-10 01:48:38 +02:00
Kristian S. Stangeland
4392eb9ea0 Don't choke on exceptions during error filtering. Pointless. 2013-09-05 04:07:05 +02:00
Kristian S. Stangeland
9442e2c36f Report using the correct sender in the update methods. 2013-09-05 04:03:01 +02:00
Kristian S. Stangeland
db2efbe089 Relax expected Minecraft version format. Partially fixes ticket 124 2013-09-02 16:14:11 +02:00
Kristian S. Stangeland
d810d17abb Increment to 2.7.1-SNAPSHOT for development towards the next version. 2013-09-02 16:04:55 +02:00
Kristian S. Stangeland
37766d3ecf Added some missing features to 2.7.0.
Note that this supercedes the previous increment commit.
2013-09-02 02:42:18 +02:00
Kristian S. Stangeland
1b5463651f Increment to 2.7.0 2013-09-02 02:00:14 +02:00
Kristian S. Stangeland
fba2b7a6b3 Add the ability to broadcast a packet to every player or nearby players
This is just a convenience method.
2013-09-01 18:47:24 +02:00
Kristian S. Stangeland
8295b951d9 Don't throw an exception the first time we initialize IntHashMap. 2013-08-29 23:57:20 +02:00
Kristian S. Stangeland
fc01a61290 Call the correct get-method (not remove) in IntHashMap. Fixes #7
As it happens, there are two very similar methods in IntHashMap:
  Object get(int key);
  Object remove(int key);
  
I called the latter by mistake. Now, I distinguish between the two 
by performing a removal test.
2013-08-29 01:33:43 +02:00
Kristian S. Stangeland
3f8a48732e Don't assume the InputStream is an DataInputStream in Spigot's case. 2013-08-27 23:23:30 +02:00
Kristian S. Stangeland
be9bbc924e Experimental fix for issue #7 on Github.
Attempt to detect the correct "get" method in a IntHashMap.
2013-08-27 22:09:06 +02:00
Kristian S. Stangeland
3923e05178 Asynchronous client packets are handled twice. FIXES 118
This causes wierd artifacts such as double placing of half-slabs and so
on, as Minecraft will process the packets again (except chat packets). 
We correct this by uncancelling the asynchronous packet, and then 
cancelling it again.
2013-08-15 01:04:56 +02:00
Kristian S. Stangeland
ccc123b26f Added missing server packet WORLD_PARTICLES. 2013-08-09 23:15:33 +02:00
Kristian S. Stangeland
ba692d5b7d Display whether or not a packet has been cloned in the packet command. 2013-08-07 00:33:57 +02:00