Commit Graph

51 Commits

Author SHA1 Message Date
Ceikry 9a25c2a87d Improved logout handling 2023-06-02 01:34:01 +00:00
Dan Ginovker 034cc75a61 Started implementing Castle Wars (not ready to enable yet) 2023-04-10 07:13:54 +00:00
Ryan 374ad2f2e5 Implemented unit testing in gitlab CI/CD pipeline
Contributors: If you run unit tests locally, you will need to import Server/db_exports/testuser.sql to set up the unit test user in your local database server (or change the credentials used for unit testing in Server/src/test/resources/test.conf)
2023-03-27 09:19:49 +00:00
Ceikry 8b62e42323 Fixed a bug that prevented progression in tutorial island
Fixed a bug that caused woodcutting to take slightly longer
Fixed a bug that caused the woodcutting axe message to print more often than it should
Fixed a bug that caused fishing to not print its fishing attempt message
Fixed a bug that caused fishing to take slightly longer
Fixed a bug that would cause nechryaels to lose interest in the player when their minions attacked
Made sure the grand exchange tests always clean up the GEDB
2023-03-16 03:27:30 +00:00
Ceikry 88a2f354b4 Added support for varying log levels configurable in the server config (see log_level in default.conf)
Error logs now properly print to stderr when possible
Colour-coded logs
Addressed a scenario in which outgoing packet writes could get hung up
Fixed interface incorrect definition message on server startup
2023-03-01 08:01:14 +00:00
Ceikry 124eeab893 Implement Authentic Interaction Subsystem
Implemented authentic script/interaction queues
This does now mean we have a total of 3 interaction systems, but this additional system is necessary to fix certain categories of bug and implement some authentic features
Converted mining to new system
Converted fishing to new system
Converted woodcutting to new system
Provided an example of soft-queued scripts with GrandTreePodListener
Implemented tick-eating (it is now possible to eat a shark, drink a potion, and eat a karambwan all on the same tick)
Can now eat and drop items while stunned
2023-02-28 23:41:14 +00:00
Skal Fate f243293e8c Fixed construction issue relating to incorrect isloaded checks causing null scenery
Fixed construction issue relating to houseregionid getting registered for dunegon id
Fixed construction issue relating to teleports in houses
2023-02-16 22:16:46 +00:00
Ceikry a100affda2 Repository reorganisation
Unified kotlin and java into just src/main
Unified the rs09 and core packages
Took all content out of the core package, and placed it into the new content package
Reorganised all source code relating to content to be easier to find and explore
2023-01-26 13:59:28 +00:00
Ceikry b387e993bb Fixed a bug when buying items from shops with a full inventory 2022-12-20 08:40:59 +00:00
Von Hresvelg e8ea397b6b Added an Allotment Seed drop table
Reworked Farmer drop table
2022-12-17 07:40:18 +00:00
Dan Ginovker 97e74320fb Implemented Doubling Money scammer bots at GE
Converted some classes to Kotlin
Fixed a trading bug when you removed an item, the modified slot would flash on the wrong side
2022-12-11 06:45:42 +00:00
Von Hresvelg aa935855c9 Moved drop tables into dedicated folder (data/config/shared_tables)
Added Rare Seed Drop Table
Reworked Aberrant Spectre drops
2022-11-16 08:16:22 +00:00
Von Hresvelg 712b44f008 Added secondary drop tables
Uncommon seed drop table added
Gem drop table added
Herb drop table added
Reworked Green Dragon drop table
Reworked Moss Giant drop table
2022-10-30 07:24:31 +00:00
Ryan 1f078ed0f4 Alchemy value now derived from item value (from cache)
Removed all alchemy value overrides from item config json
All items should now have authentic alchemy values
2022-10-03 08:50:31 +00:00
Ceikry 39cf1f60ca Fixed value parsing from item definitions 2022-10-03 07:26:34 +00:00
Ceikry d2283e6716 Removed lots of dead code 2022-09-17 16:28:52 +00:00
Ceikry f406b8aa98 Graves Rewrite
Rewrote graves from scratch using new systems and abundant unit testing
Fixed a race condition bug that would prevent classes implementing PersistWorld from properly... persisting
Fixed a bug where graves were (still) too generous
Fixed a bug where graves would not persist across server reboots
Fixed a bug where graves would not recognize a relogged player
Fixed numerous other bugs with graves, see the unit tests for complete coverage
Grave system now supports quest requirements
2022-09-17 14:40:25 +00:00
Ceikry a1e9e4b2a1 Added worldprops option noauth_default_admin so admin-by-default can be disabled when use_auth = false, thus making it possible to have singleplayer builds where the player is not automatically given admin rights 2022-09-09 12:54:01 +00:00
Ryan 0ea1438a33 Changed GE database uids to account database format 2022-09-03 08:47:53 +00:00
Ceikry 131a123eeb Fixed dialogue splitLines edge case 2022-09-01 14:34:27 +00:00
Ceikry 21d334a989 Rewrote splitLines using Test-Driven Development, words should no longer get lost 2022-08-16 13:37:00 +00:00
Avi Weinstock ee65b58ca4 Improved region handling
Deep copy scenery for build region chunks
Now clearing clipping and projectile flags when entering a dynamic region
2022-07-30 03:31:24 +00:00
vddcore 895444f1a8 Refactored pulse running logic, made it easier to follow and debug
Made the pulse runner use thread-safe collections instead of synchronizing on a thread-unsafe list
2022-07-16 07:36:44 +00:00
vddcore 374d6ec478 Items with destroy option can no longer be sold to stores
Items that cannot be traded can no longer be sold to stores
2022-07-09 08:51:48 +00:00
Avi Weinstock b2763a5586 Equipping an item into an occupied equipment slot now places the swapped item into the inventory slot of the item being equipped 2022-07-07 07:45:17 +00:00
Avi Weinstock 0fcaa8ad24 Fixed hardcoded database credentials in unit tests 2022-07-05 13:28:27 +00:00
Ceikry 5c28375c3b Pathfinder now correctly paths to the closest accessible tile of an object, not the closest tile numerically. This should fix instances where you end up running around an object before interacting with it. 2022-06-11 12:35:16 +00:00
Ceikry 2045143378 Removed independent management server
World server now handles its own management-server-related functionality, a new management server will be written in the future to facilitate cross-world event syncing
World server now runs standalone, this requires the client to be configured to connect the world server port for the world list (world list was previously supplied by the management server on port 5555, which should be swapped to the world server port that is generally 43595 for world 1) work is in progress to update client launchers to make this as seamless as possible
This should resolve issues where players sometimes get a login error claiming they are already logged in
2022-06-09 10:09:57 +00:00
Ceikry 185496e561 Add maven 2022-05-31 02:51:22 +00:00
Ceikry a40dbfbc1c Improved server shutdown order
Improved GE threading, introduced locks fixing server lags and GE offers not executing
Moved player login hooks to the major update worker (from management server thread)
Fixed random events in rare circumstances causing noted item loss
2022-05-24 11:02:05 +00:00
Ryan 40d227d430 Reverted alchemy changes, turns out the item value data in the game cache is so unreliable it's essentially unusable 2022-05-21 17:01:27 +00:00
Ryan 09ce411a0c Removed all alchemy values from config (inauthentic values, seem to have been copied from RS3) - we will probably need to add new overrides as they are discovered, none known at time of writing
Defined low alchemy value as item value * 0.4 unless override exists in config (authentic)
Defined high alchemy value as item value * 0.6 unless override exists in config (authentic)
2022-05-20 12:02:03 +00:00
Ceikry 334bc77d06 Improved the GE database access to use a basic reference counter for the connection that automatically closes the connection when no one is using it anymore
Grand Exchange now uses the GE sqlite database's price index table to track price changes
Removed the old price index (confusingly called GrandExchangeDatabase.java)
Grand Exchange prices are now dynamic and influenced by trades (weighted stepping average price)
Fixed GE interfaces not loading on login
2022-05-20 11:23:30 +00:00
Ceikry 907838bb5f Addendum to login/auth improvements to make sure communication info gets parsed
Only update db fields if they have changed
2022-05-18 13:59:51 +00:00
Ceikry 07065c7e79 Random Events should now spawn correctly
Fixed an issue that was causing tick event hooks to not fire
2022-05-16 12:22:29 +00:00
Ceikry 8835799230 Refactored equipment.add, fixes bug #420 (blaze it) 2022-05-16 11:54:23 +00:00
Ceikry 9ab9885eef Introduced modular components for authentication, including the storage backend
Servers in dev mode now have a no-auth equivalent that allows any user/pass combo without registration
Added a ban command
Added a mute command
Hooked up the mute functionality of the report screen (for pmods+)
Cleaned up all the now-unused classes for player SQL stuff
Player SQL stuff now uses entirely prepared statements
No longer storing PC name, MAC address, serial number as these are inauthentic components of the protocol Packet to be corrected in the future to allow closer compatibility with authentic clients
Used less threading for the SQL queries/updates as these were causing issues both with the old system and the new
Updated ::resetpassword and ::setpasswordother commands to use the new server authentication pipeline (to ensure things are always correctly set)
Refactored the login read event, now handles more exceptions and edge cases
2022-05-16 11:51:42 +00:00
Ceikry 966a5e1c55 Fixed the load order of configs with plugins - many configs are now loaded after plugins so that npc/item/object handlers in the old plugin system are set properly 2022-05-15 23:22:30 +00:00
Ceikry 24cea604fc Class scanning now distinguishes side effectful plugins from our pure content interfaces
Server store is now loaded and parsed ***before*** side effectful plugins
2022-05-15 11:20:27 +00:00
Ryan ebc540c7c7 selling items for tokkul now returns the correct amount of tokkul (10x less) 2022-05-14 13:23:27 +00:00
Ceikry 90060fde21 Item sets now appear and can be unpacked at the GE
Added a proper mock session that gets used for mock players in unit tests. Allows verifying that certain packets made it to the IoSession (the stage right before sending it to the client)
2022-05-14 10:24:47 +00:00
Ceikry 7478f68d40 fixed a bug that allowed purchasing 0-stock items (you would only lose gold without getting an item) 2022-05-14 06:24:47 +00:00
Ryan d91396d0ea adjusted price calculation formula used when selling items to shops 2022-05-06 22:54:32 +00:00
Ceikry a5f9c64dbb New dynamic region abstraction, consumed in construction 2022-05-03 23:18:11 +00:00
Ceikry 8438ecdbd7 Fixed an exception thrown when buying from player stock
Fix issue where malformed stock could shift following shop items
2022-05-02 10:22:36 +00:00
Ceikry b5a78fe18a Add more unit tests for shops and quest related architecture
Fixed bug where quests could be repeatedly finished
Fixed bug where ironman status wasn't checked when buying overstocked items
Fixed bug where selling multiple items at a time that weren't listed in a shop would not succeed
Fixed bug where shop restocking would sometimes interrupt if a shop stock item was in a null slot
2022-04-26 03:48:20 +00:00
Ceikry 96abfe6ab1 Add symlink for unit test cache access 2022-04-25 12:41:59 +00:00
Ceikry fb98015536 Added unit tests for the GE
GE should now favor the buy offer if it's newer than the paired sell offer (buyer gets GP back)
GE should now favor the sell offer if it's newer than the paired buy offer (buyer does NOT get gp back)
GE should now always award bot offers to the highest bidder
2022-04-25 12:35:51 +00:00
Ceikry 933dc72a48 Added unit tests for regions (now requires cache at Server/src/resources/cache)
Reverted some really old changes (2019) to house loading code (Might fix construction? Probably not.)
2022-04-25 12:15:56 +00:00
Ceikry eab32ccef8 Add unit tests for slayer
Kill server networking as soon as shutdown process starts
2022-04-24 15:08:08 +00:00