-
-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: combat, stats, levelling, and inventory (#76)
* feat: basic skeleton groundwork for combat * feat: gracefully logout without causing server errors * fix: display correct monster name on look command * feat: initial working combat systems * fix: enable and fix clippy::cargo warnings * refactor: simplify position and velocity into single struct * refactor: make client naming convention distinct from server * fix: crash when player enters top row * refactor: first pass at clippy pedantic warnings for integer casts * refactor: first pass at clippy pedantic warnings for client and lib * refactor: first pass at clippy pedantic warnings for server * refactor: second pass at clippy pedantic warnings * refactor: third pass at clippy pedantic warnings * refactor: resolve final clippy pedantic warnings * feat: make player HP updates visible to player after combat * feat: add uuid to player_details * refactor: use f32 stats more accurate combat calculations * fix: revert incorrect player str default * refactor: split systems into separate modules * feat: implement player death mechanics * refactor: remove the need for player_position_updates resource * chore: remove todo comments * feat: implement monster deaths * feat: implement sending combat system messages to players * feat: implement sending combat system messages to players * docs: update readme to reflect combat feature * feat: implement monsters attacking players * feat: implement monster respawn mechanics * fix: skip combat checks if either attacker/defender already dead * feat: implement health regen every second server tick * feat: make player attacks only happen on server tick * refactor: change look command to l key * docs: clarify controls * chore: clarify attack miss message * refactor: move exp and lvl to stats * feat: implement exp gain on killing enemy * fix: only give exp on monster deaths, not players * feat: implement levelling up and stat gains * chore: change clippy lint checks * fix: new max hp should be rounded * feat: implement inventory system structs * feat: implement inventory system * fix: make resizing the client window more robust * feat: dynamically resize viewport based on window resize * docs: clarified comment * feat: gain gold from killing monsters * refactor: tweak side status bar layout * refactor: create network message system * refactor: tweak side status bar text * fix: gain gold from multiple monsters * feat: added trinket item type * refactor: move entity update messages to broadcast system * fix: player walking on item * refactor: minimise broadcast size to minimum required * fix: remove dead monsters from player display * fix: send entity broadcasts individually so max packet size is not exceeded * feat: add item ids * fix: look underneath now works * docs: added CHANGELOG.md * docs: add more details to README.md * chore: update dependencies * feat: implement pickup command with some bugs * docs: updated CHANGELOG.md * fix: duplicate items being added to world * fix: item disappears correctly from client viewport when picked up * chore: add local startup script to .gitignore * feat: new default maps and spawns * feat: add drop item functionality * docs: clarified description * docs: clarified description * docs: clarified description * docs: clarified description
- Loading branch information
1 parent
59ced75
commit ad79e78
Showing
85 changed files
with
3,576 additions
and
1,291 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -22,4 +22,7 @@ out/ | |
.Spotlight-V100 | ||
.Trashes | ||
ehthumbs.db | ||
Thumbs.db | ||
Thumbs.db | ||
|
||
# Local startup script | ||
start.bat |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,114 @@ | ||
# Changelog | ||
All notable changes to this project will be documented in this file. | ||
|
||
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), | ||
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). | ||
|
||
## [Unreleased] | ||
|
||
## [v0.3.0] | ||
The combat, stats, levelling, and inventory update! | ||
### 🚀 Features and Improvements | ||
- PvE combat with monsters | ||
- PvP combat with players | ||
- player stats now actually used: | ||
- str increases damage | ||
- dex increases accuracy | ||
- con increases health and regen rate | ||
- player sidebar now displays and updates values in realtime | ||
- death and respawning for players and monsters | ||
- exp gain, levelling up, and stat gains | ||
- inventory system | ||
- picking up items | ||
- dropping items | ||
- default weapons and armour (used in combat calculations) | ||
- system messages and combat notifications displayed in bottom of client window | ||
- look command changed to L key | ||
- client window can now be dynamically resized | ||
- a slightly larger default map with more variety | ||
|
||
### 🐛 Bug Fixes | ||
- gracefully logout without causing server errors (only if you use ctrl-q) | ||
- look command now displays monster name correctly | ||
- look command now shows underneath items in all situations | ||
- no longer crashes when player enters top row of map | ||
|
||
### 🧰 Maintenance | ||
- clippy::cargo and clippy::pedantic warnings resolved | ||
- network code efficiency improved (no more MaxPacketSize issues) | ||
- CHANGELOG.md added | ||
- dependencies updated | ||
- link time optimisations enabled for release build | ||
- a lot of code refactoring and tidying | ||
|
||
## [v0.2.2] - 2022-07-13 | ||
### 🚀 Features and Improvements | ||
- enable large map data | ||
|
||
### 🧰 Maintenance | ||
- updated dependencies | ||
- refactoring and tidying of messaging code | ||
|
||
## [v0.2.1] - 2021-11-21 | ||
### 🧰 Maintenance | ||
- updated dependencies | ||
- updated rust edition to 2021 | ||
|
||
## [v0.2.0] - 2021-02-27 | ||
The monsters update! | ||
### 🚀 Features and Improvements | ||
- initial implementation of monsters | ||
- ability to load monsters and spawns from .json assets | ||
- player and monster stats | ||
- stat window and map location display | ||
- implemented look command | ||
|
||
### 🐛 Bug Fixes | ||
- fixed bug with logged out player being collidable | ||
|
||
### 🧰 Maintenance | ||
- updated dependencies | ||
- updated logo | ||
|
||
## [v0.1.1] - 2021-02-17 | ||
### 🚀 Features and Improvements | ||
- support multiple players | ||
- connectivity improvements | ||
- added --debug logging switch | ||
- implement player rejoin & check if player exists | ||
- bind to 0.0.0.0 by default for simplicity | ||
- implemented collisions between player entities | ||
- added DisplayDetails to entity updates | ||
|
||
### 🧰 Maintenance | ||
- better exception handling | ||
- updated some dependencies | ||
- refactored method locations into appropriate modules | ||
- limited pub methods to pub(crate) | ||
|
||
## [v0.1.0] - 2021-02-12 | ||
### 🚀 Features and Improvements | ||
- implemented client/server | ||
|
||
## [v0.1.0-alpha.3] - 2021-02-07 | ||
### 🚀 Features and Improvements | ||
- use release-drafter.yml | ||
|
||
## [v0.1.0-alpha.2] - 2021-02-05 | ||
### 🚀 Features and Improvements | ||
- ability to load a map from a file | ||
|
||
## [v0.1.0-alpha.1] - 2021-02-03 | ||
### 🚀 Features and Improvements | ||
- first version of working code | ||
|
||
[Unreleased]: https://github.com/pbellchambers/rustyhack-mmo/compare/v0.3.0...HEAD | ||
[v0.3.0]: https://github.com/pbellchambers/rustyhack-mmo/compare/v0.2.2...v0.3.0 | ||
[v0.2.2]: https://github.com/pbellchambers/rustyhack-mmo/compare/v0.2.1...v0.2.2 | ||
[v0.2.1]: https://github.com/pbellchambers/rustyhack-mmo/compare/v0.2.0...v0.2.1 | ||
[v0.2.0]: https://github.com/pbellchambers/rustyhack-mmo/compare/v0.1.1...v0.2.0 | ||
[v0.1.1]: https://github.com/pbellchambers/rustyhack-mmo/compare/v0.1.0...v0.1.1 | ||
[v0.1.0]: https://github.com/pbellchambers/rustyhack-mmo/compare/v0.1.0-alpha.3...v0.1.0 | ||
[v0.1.0-alpha.3]: https://github.com/pbellchambers/rustyhack-mmo/compare/v0.1.0-alpha.2...v0.1.0-alpha.3 | ||
[v0.1.0-alpha.2]: https://github.com/pbellchambers/rustyhack-mmo/compare/v0.1.0-alpha.1...v0.1.0-alpha.2 | ||
[v0.1.0-alpha.1]: https://github.com/pbellchambers/rustyhack-mmo/releases/tag/v0.1.0-alpha.1 |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,4 +3,7 @@ members = [ | |
"rustyhack_client", | ||
"rustyhack_lib", | ||
"rustyhack_server", | ||
] | ||
] | ||
|
||
[profile.release] | ||
lto = true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,10 @@ | ||
########################## | ||
# v# | ||
# # | ||
#----- ^ -----# | ||
# # | ||
# ^ # | ||
#----- -----# | ||
# # | ||
#----- -----# | ||
# # | ||
##########################% |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,30 +1,37 @@ | ||
##################################################################################################### | ||
# |--------| |--------| | # | ||
#* | , | | | | # | ||
############################# | ||
########### |------------------| ################ | ||
##### | | ############### | ||
## | | ######## | ||
## |--| |--/------------/--| | #### | ||
## |v / * | ## | ||
# |--| ## | ||
# | |-------| # | ||
# |--------| |--------| * | | # | ||
#* | , | | | | |---+---| # | ||
# | | | | | # | ||
# |---/----| |------/-| | # | ||
# | # | ||
# |--/-----| * | # | ||
# | | | # | ||
# # | ||
# |--/-----| * # | ||
# | | # | ||
# | | ----# | ||
# |--------| # | ||
# * # | ||
# # | ||
# * |-------| # | ||
# | | # | ||
# |---+---| # | ||
# # | ||
# # | ||
# # | ||
# * # | ||
# # | ||
# # | ||
# # | ||
# # | ||
############################################ ######################### | ||
# * * * # | ||
# # | ||
# # | ||
# * |-/--| * # | ||
# | v| # | ||
# # | ||
# * # | ||
# * # | ||
# # | ||
#-------------------------| # | ||
# * * * * *| ## | ||
# |--| * * *| # | ||
# |--| |------| | ## | ||
# |* / # | ||
# |--| |------| # | ||
# v|--| * * *| #### | ||
# * * * * *| ### | ||
########################### # | ||
## ### | ||
## * # | ||
### ## | ||
#### # | ||
##### ## | ||
##########################% |
Oops, something went wrong.