Release thread

Intro

ScapeEmulator is a RuneScape server emulator, created by Jonneh and Graham, which targets build 530 of the game. It is written in Java 7, and can be built with Apache Maven.

It is released under the ISC license: ISC License Explained in Plain English

The following third-party libraries are used:

  • JUnit
  • SLF4J
  • APIviz
  • ObjectWeb ASM
  • Netty 4
  • MySQL Connector/J

See the release thread at the top of this article for setup, screenshots

Download

Everything: scape-emulator-final.zip
Server code only (no cache/client etc.): scape-emulator-lw.zip

More complete 530 cache

Using a program Graham wrote (CacheAggregator, which is in the cache submodule), I've taken the 530 cache we have and drastically reduced the number of missing files in it, by searching for files with the same CRC/version in other caches (the latest cache, and all the caches I could find near similar revisions.)

This means it only has the following missing files (30 total):

6:28 missing
6:33 missing
6:41 missing
6:49 missing
6:138 missing
6:161 missing
6:180 missing
6:203 missing
6:211 missing
6:217 missing
6:257 missing
6:274 missing
6:311 missing
6:349 missing
6:357 missing
6:408 missing
6:464 missing
6:552 missing
6:582 missing
6:604 missing
7:6589 out of date
14:12 missing
14:13 missing
14:394 missing
14:538 missing
14:591 missing
14:601 missing
14:628 missing
14:629 missing
14:631 missing

The original 530 cache we used (which is the one floating around rune-server) has 1049 missing files for comparison! So from this to 30 is a dramatic improvement!

If anyone manages to finds a cache with the appropriate versions of these btw, then please post about it

Support for obscure parts of the protocol

As well as world list, ondemand, jaggrab and in-game support, it also has support for the auto login protocol (this is used in the signed clients where it has 'World: Auto', and the server sends back a world number for the client to connect to) and the registration protocol (although unfinished - the codecs are complete, but not the logic for dealing with them.)

Tools for creating a client using the original loader/client jars

The tool uses ASM to replace the parts of the bytecode (e.g. the hostname checking, the CRC checksums, the RSA key, the cache path) so that the original client/loader can be used to connect to the server. There's an in-built HTTP server to demonstrate this, just visit http://127.0.0.1:8080/index_gl.html when the game server is running.

Also I managed to find the native libraries corresponding to the version of JOGL jagex used at the time, so the client should work across Windows, Mac and Linux - 32 and 64 bit. Unfortunately I have no Mac to test it on though - but it has been tested on Windows and Linux. The unsigned client ofc works across all of them as it does not load the native libraries.

Benchmark

Tom asked for some benchmarks. There is a flooder module for you to test it on your own PC, but connecting 2k players on my PC (i5-2500k, 24g of RAM), the mean cycle time is ~92ms, with a standard deviation of ~14ms.

Some things ScapeEmulator lacks!

As it states in the README, you shouldn't just flock to this instead of using Apollo. Apollo is still your best choice for old engine servers, but it was never designed with the new engine in mind. So if you are making a new engine server, this may well be your best choice, but otherwise, I'd still recommend use of Apollo and carrying on with the development going on there (buroa, chris fletcher, etc. have released some really good stuff for Apollo.)

Some things Apollo has that this doesn't are: plugin system, multi-threaded updating, multi-protocol support, walkback support in the walking queue (although this would probably be reasonably easy to rip out of Apollo and add.) There are probably more.