Skip to content

Releases: evolutionleo/Warp

[v7.0] Sessions, Reconnecting and Chats!

04 Dec 05:11
Compare
Choose a tag to compare

This is a very big update, below is a (non-complete) list of things I've added/changed since v6.0

  • Added Temporary accounts
  • Added Sessions
  • Session tokens are saved to a local file client-side and used to login automatically on each game start
  • If no session token is present - a new temporary account will be created, with a new session token assigned to it
  • Temporary accounts are used to save player progress and identify different clients, without the need for a login screen
  • Registering while logged into a temporary account upgrades it to a permanent account instead
  • Clients now have a reconnect_timer and don't get destroyed immediately after a socket is disconnected. If another socket connects using the same session until the timer expires, that socket will automatically take place of the old Client and continue as normal (from the same lobby, room, etc.)
  • Removed the nested keys object in PlayerEntity's key inputs (entity.inputs.keys.k* -> entity.inputs.k*)
  • Refactored sending/receiving player inputs for easier adding/removing of keys (now you only need to change code in 2 places instead of 4)
  • Merged utility functions from schemas/account, schemas/profile and util/hash_passwords into a single file util/auth
  • Refactored the old login functions to use async/await instead of Promises (for better readability)
  • Replaced uuid.v4() with crypto.randomUUID() (~4x faster)
  • Removed redundant/unused dependencies: "uuid", "extend", "module-alias", "0x", "performance-now", "rbush", getting rid of the "critical vulnerability" warnings in npm from unused code
  • Replaced var with let in a lot of the old code
  • Changed data.status variable type from string to boolean in a lot of functions for more consistency and simplicity
  • Fixed bug where an entity being removed twice or more in the same frame could remove other unrelated entities
  • Updated all entity collision functions to accept an optional parameter collider, default to this.collider to have secondary colliders
  • Updated entity colliders to use scale (Entity.updateCollider() no longer creates a brand new collider every time you change the scale of the entity)
  • Entity.updateCollider() is now automatically called after each collision check
  • Added Entity.origin and Entity.collider_origin variables to support sprite origins other than the top left corner (these are 2D variables with x/y values from 0 to 1, 0 meaning top/left, and 1 = bottom/right)
  • Changed the way default/guest names are generated
  • Moved a function from #util/entity_functions to #concepts/entity
  • Added Chats
  • Added a mongoose schema for Chats, keeping track of messages and members' profile ids
  • Clients now have a chats attribute with all their current active chats
  • Profile schema now has a chats attribute (an array of references to Chat objects in the database)
  • Renamed variables from lobbyid -> lobby_id, profileid -> profile_id, etc. across the codebase for consistency and readability reasons
  • Renumbered most initializers (changing file names and order of execution)
  • Fixed initializers/00_exit_handler.ts not handing Ctrl+C exit from the process on Windows correctly
  • ...and more!

Enjoy! And please report any bugs to my Discord server

- Evoleo

[v6.0.3] Remove Entities fix + get rid of JSON serialization in entities

08 Oct 15:51
Compare
Choose a tag to compare

This patch release fixes a bug where ghost entities would sometimes remain on the client, as well as gets rid of a piece of very old placeholder code that slowed down all server-side entities for years 0_0

Also adds syncing image_angle on the server-side entities

Enjoy!
- Evoleo

[v6.0.2] Fix macros and update tabularelf/MultiClient

28 Aug 10:06
Compare
Choose a tag to compare

this small update introduces a couple fixes to a couple issues introduced with minor breaking changes in a new GameMaker monthly update

[v6.0.1] Fix delay autoadjust and chaining packet handlers client-side

14 Mar 06:01
Compare
Choose a tag to compare

☄️ [v6.0] Matchmaking, Game Modes, Levels, Middleware ☄️

07 Jan 19:13
Compare
Choose a tag to compare

🎉 The long awaited v6.0 update! 🎉
Honestly I should've released this months ago, but it is what it is
There could still be some [breaking] bugs, so please report any so I can fix them asap in v6.0.1

This update introduces a bunch of new features and concepts, improved Matchmaking being the main one obviously, and other systems, such as Game Modes and Levels are just there to support it and allow you to interact with the mm system and describe your specific game.

The old Matchmaking used to just put every player in the first non-full lobby (cringe)
The new Matchmaking system, on the other hand, tries to balance the teams to have close average MMR, as well as account for parties (for now, only full parties are supported for Ranked game modes (any party sizes for unranked though!))

Of course, it is, as always, customizable inside config.js

Have fun and lmk what you think about the update!
- Evoleo

[v5.1] Project structure changes + input validation

29 Apr 16:04
Compare
Choose a tag to compare

This update introduces some big changes to the project structure (most noticeably I got rid of the "internal" and "custom" folders and instead moved everything out to the root folder, I thought it made more sense that way)

Also packet handlers and senders are now split into different files! Previously it would get pretty inconvenient to have everything in one place as your project eventually grows in scale

You can still write your handlers and senders as before if you want to though!

In addition to that, I added the ability to validate incoming data using the library "fastest-validator". This is useful for additional type/value safety, as well as for potentially preventing cheaters from hijacking the packets to e.x. submit a really long username or other invalid data that could potentially break the backend and would otherwise be only filtered on the client-side

I know there haven't been any updates in quite a while, so I hope you like this one!
- Evoleo

[v5.0.2] Snapshot interpolation fix

30 Mar 13:20
Compare
Choose a tag to compare

Fixes a major bug with snapshot interpolation that caused the game to sometimes be jittery

Also you no longer need to set non-static type and object_name properties on each instance, as they will be set automatically from the static ones in the Entity constructor

There are also a couple really minor changes in the project structure (moved the client-side entities from WarpDemo/Objects/Gameplay to Warp/Objects/Entities)

Enjoy!
- Evoleo

[v5.0.1] JS usability fixes

27 Mar 18:55
Compare
Choose a tag to compare

Adds jsconfig.json and a couple new JSDoc types for better JS experience

[v5.0.0] Snapshot interpolation & friends

06 Mar 19:40
Compare
Choose a tag to compare

This major update introduces a whole bunch of new features and improvements, most notably snapshot interpolation (which allows to smoothen out the entities jittering that was caused by packages being spaced unevenly when latency is present), a friends request system, as well as some changes and improvements to the server-side physics system, including making it delta-time based

Also I was able to reduce the server's tickrate from 60 to 20 tps, which makes it much more performant and less bandwidth-heavy!

Advanced matchmaking functionality unfortunately didn't make it into 5.0, since I really didn't want to delay this major update for another few weeks. It is currently planned for v5.1 though!

Keep in mind, that as always I haven't been able to test everything, so please let me know of any bugs/inconveniences that you find in the framework!

Enjoy! :D
- Evoleo

[v4.4.3] Compatibility between client and server versions

29 Dec 17:35
Compare
Choose a tag to compare

This minor release introduces a new feature for the server - it now fetches clients' GAME_VERSION and checks it (using the "semver" npm package) against its own config.meta.compatible_game_versions, which you can edit inside the config.js/ts file.
It then kicks the client if their version is out of date (not compatible with the server)

(As of now this feature does not work for the js/web client, bc I'm too lazy to implement that lol)

Also, looks like somewhere along the way a GameMaker update broke dual instances, so I fixed that by swapping the extension used to execute shell commands with the amazing YellowAfterlife's execute_shell_simple (the previous one used was also written by him btw lol)

So, uhh, Enjoy!
...and have a Happy New Year!

- Evoleo