Skip to content

Commit

Permalink
feat: add online network play. (#767)
Browse files Browse the repository at this point in the history
Integrated with the bones matchmaker to support online network play.
  • Loading branch information
zicklag committed Apr 19, 2023
1 parent 6dd630a commit 8324419
Show file tree
Hide file tree
Showing 9 changed files with 553 additions and 12 deletions.
14 changes: 12 additions & 2 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,7 @@ rustls = { version = "0.20.7", features = ["dangerous_configurat
postcard = { version = "1.0.4", features = ["alloc"] }
bytes = "1.4.0"
ping-rs = "0.1.2"
bones_matchmaker_proto = "0.1.0"

# Optimize dependencies even in development
[profile.dev.package."*"]
Expand Down
2 changes: 1 addition & 1 deletion assets/default.game.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ main_menu:
menu_width: 350

default_settings:
matchmaking_server: localhost:8943
matchmaking_server: matchmaker.bones.fishfolk.org:65534
player_controls:
# Gamepad controls
gamepad:
Expand Down
2 changes: 2 additions & 0 deletions assets/locales/en-US/network-game.ftl
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@ stop-server = Stop Server
fish-fight = Fish Fight
configure-match = Configure Match
player-count = Player Count
search = Search
searching = Searching...
search-for-match = Search for Match
connecting = Connecting...
joining = Joining...
Expand Down
3 changes: 3 additions & 0 deletions src/networking.rs
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,9 @@ use proto::*;
pub use lan::*;
mod lan;

pub use online::*;
mod online;

pub struct NetworkingPlugin;

impl Plugin for NetworkingPlugin {
Expand Down
Loading

0 comments on commit 8324419

Please sign in to comment.