Commit Graph

51 Commits

Author SHA1 Message Date
Gent
7135767cc4 Egg checks, fixes, and cleanup
fixed not taking egg buff flag into consideration in mob manager

fixed stamina bug and improved sanity check

Egg cleanups
2020-11-11 23:19:07 -05:00
Kamil
0ecf76c5ec moved egg summoning to a custom ChatManager command 2020-11-11 23:19:07 -05:00
Kamil
d102fabc2f set up gruntwork 2020-11-11 23:19:07 -05:00
kamilprzyb
f2ff4c7f4d added basic player buffs implementation 2020-11-11 23:19:07 -05:00
83c378c9c2 Added /notify and /players admin commands
Co-authored-by: dongresource <dongresource@protonmail.com>
2020-11-03 21:07:59 +01:00
a1145aced4 Chat strings are now sanitized.
* Only plain, printable ASCII is allowed for now.
* Local chat is now printed to the server console, but group chat is
still private
* Added a helper function to print character names and IDs
2020-10-31 21:31:25 +01:00
c8497a4856
Implement two more mission types + tweaks & fixes
* Weapons will consume your batteries fully.
* Nerfed enemy damage at lower levels.
* Further reworked drain, uses a static variable as a timer (lastDrainTime)
* resendMobHP has been repurposed to drainMobHP.
* Players heal faster after a sizable cooldown.
* Nano type advantage is more noticeable during combat.

Implemented two more mission types + Tweaks

* Item delivery quests now work.
* Timed missions now work.
* All escort missions (type 6) are skipped.
* /minfo now also prints the terminator npc.
* Weapon battery consumption tweaked
* Fixed indentations.
* Heal nanos have better output (25% -> 35%)
* Damage formula had a slight tweak.
* Bugfixed weapon equipping.
* Other tweaks
2020-10-24 14:04:42 -04:00
10534886b8 Cleanup for 1.2.
Cleaned up whitespace, comments, brace style, etc.
Updated tdata reference.
2020-10-19 20:48:57 +02:00
55be58cc24 /summonW now supports summoning non-mob NPCs.
/npcr will now rotate gruntwork NPCs in-place instead of making separate
rotation entries that wouldn't have been loaded properly anyway.
2020-10-19 03:45:58 +02:00
JadeShrineMaiden
deb3e5b897
Added /minfo and /tasks (#137)
* /minfo returns your current active mission's: id, task id, task type, task objective marker id and enemy ids if applicable.
* /tasks returns all the active mission ids and task ids.
2020-10-18 23:02:51 +02:00
4a5857a126 QoL improvements.
* Use macros for extracting map numbers and player IDs from instance IDs
* Add docstrings to all commands
* Remove /test command
* Sync with tdata
2020-10-18 22:43:22 +02:00
bbd695cad1 Minor tweaks.
* The server now refuses to start if any JSONs fail to load
* Mobs now take height into account when losing aggro on a player
* Mobs now aggro on the closest player in range, rather then on the
earliest one to connect to the server of the ones in range
* /summonW now works in IZs and Lairs as well
* Lowered the extra height that mobs spawn at with /summonW to prevent
glitching problems
2020-10-18 04:17:52 +02:00
Gent
d4aed0abf4 Add support for unique instances 2020-10-15 11:46:53 -04:00
Gent
c1fd51b721 Expand gruntwork to instances
Add NPC instance gruntwork data

Add instance-related commands
- /instance (instance ID)
- /npci [instance ID]
2020-10-15 11:44:15 -04:00
5784e77654 Misc changes.
The first two fixes were caught by infer. The Big Bug(tm) remains
unfixed.

* Fixed the Leech nano power
* Fixed an unlikely nullptr dereference in ItemManager
* /toggleai now makes mobs retreat immediately, instead of waiting for
their next movement tick
* Static path mobs will now stop in place instead of retreating to
their spawn points when AI is disabled
* Changed the misleading config option name from "chunksize" to
"viewdistance", since it's actually only a third of the chunk size
2020-10-14 23:15:02 +02:00
599bbedd8c Implemented static paths for mobs (like Don Doom and Bad Max).
* Mobs now retreat to where they were when they were roaming; not their
spawn point
* /toggleai still sends them back to their spawn point however
* Fixed a bug where mobs would respawn where they were killed instead of
their proper spawn point
* Fixed mobs roaming despite simulatemobs being set to false
* Updated tdata submodule
2020-10-13 21:44:43 +02:00
f8d64234d7 Spawn mobs above ground to alleviate hill/building phasing issues. 2020-10-12 21:08:19 +02:00
f3b6f9619b added /help 2020-10-12 02:08:10 -05:00
Gent
1564cc7724 Make proximity NPC search a helper function 2020-10-10 23:18:01 -04:00
9f280c2c31 Validate arguments to /level and /summonW; fix retreatStep() bug. 2020-10-08 20:20:12 +02:00
0d0332e551 Added /toggleai command for easier mob placement and testing. 2020-10-07 20:38:32 +02:00
606384445c Added /summonW and /unsummonW gruntwork commands.
Also:
* Filled in the battery fileds in the REWARD_ITEM packets in
MissionManager.
* Removed redundant NPC_ENTER in npcSummonHandler()
2020-10-07 19:29:59 +02:00
Gent
5ed332d836 Make /npcr use the nearest NPC 2020-10-06 20:09:18 -04:00
Gent
42fc018097 Add chunk reload command /refresh 2020-10-06 18:00:17 -04:00
Gent
1b68b5e2e2 Add NPC rotation command /npcr 2020-10-06 17:59:33 -04:00
d4d0f388c4 Implemented saving gruntwork results to file.
* Monkey Skyway paths are now saved in a format compatible with
paths.json
* flush() is called on every periodic DB save in addition to the /flush
and /mss N export commands
* Monkeys now accept WIP routes
2020-10-06 21:53:21 +02:00
ce58411ff8 Added /population and /level commands.
Also made /mss an access level 30 command, for safety.
2020-10-05 02:33:30 +02:00
661070dc3a Cleaned up whitespace.
Incantation: sed -i 's/[ \t]*$//g' src/*.[ch]pp

Also switched BuddyManager from tabs to spaces using vim's :retab command.
2020-10-05 02:03:13 +02:00
131eb94919 removed stale comment 2020-10-04 12:52:16 -05:00
755bb75306 U8toU16 now respects buffer sizes 2020-10-04 12:50:58 -05:00
Gent
a9837d6c1b Finish MSS commands + convert stack to vector 2020-10-03 11:24:45 -04:00
Gent
47da895544 Add basic MSS gruntwork commands 2020-10-03 11:20:51 -04:00
a852c26e5e minor command refactor 2020-10-02 19:20:59 -05:00
316239dadc comments + better test command 2020-10-02 18:59:07 -05:00
f5939353b1 added basic command handler 2020-10-02 18:50:47 -05:00
f4db0830ba huge refactoring, chunking added 2020-09-17 17:45:43 -05:00
e03da83ff3 Rearranged the codebase a little.
* Deleted empty Player.cpp
* Moved the helper functions from the obsolete CNStructs.cpp into
main.cpp and deleted it
* Renamed CombatManager to MobManager, as that will likely become it's
main focus soon
2020-09-16 21:46:15 +02:00
131997f34f Cleaned up all whitespace issues.
The incantation was: sed -i 's/[ \t]*$//g' src/*.[ch]pp
2020-09-14 16:07:05 +02:00
14bc368073 Dynamically allocate the Player struct in PlayerView.
This way we're not always passing it around by value.
Note that the Player structs in CNSharedData are still
pass-by-reference. Will probably change this later.
2020-08-25 00:59:55 +02:00
Zenpock
1d792a21dd
Npc Warp implementation (#29)
* Update CNShardServer.hpp

* Update ChatManager.cpp

* Update ChatManager.hpp

* Update NPCManager.cpp

* Update NPCManager.hpp

* Add files via upload

* Update NPCManager.cpp

* Update NPCManager.cpp

* Update ChatManager.cpp

* Update ChatManager.cpp

* Update NPCManager.cpp

* Update NPCManager.cpp

Co-authored-by: CPunch <sethtstubbs@gmail.com>
2020-08-23 10:32:25 -05:00
88953541ef added INITSTRUCT to zero-out data 2020-08-22 19:26:18 -05:00
94b0dc724e major refactoring 2020-08-22 18:31:09 -05:00
Zenpock
4f10ee0505
MenuChat Added (#25)
* Update CNShardServer.hpp

* Update ChatManager.cpp

* Update ChatManager.hpp

Co-authored-by: CPunch <sethtstubbs@gmail.com>
2020-08-22 13:11:47 -05:00
7b085e9c8b added sanity checks 2020-08-20 18:50:30 -05:00
b8f7d2efc6 added comments to chatHandler() 2020-08-19 13:25:54 -05:00
e7b58c4b32 fixed formatting 2020-08-19 13:22:51 -05:00
8328ebf4f3 Chat Feature
Chat with other players, no swearing!!!
2020-08-19 18:47:25 +01:00
a17b72b0b3 Revert "Chat Feature"
This reverts commit 95e454232a.
2020-08-19 18:43:24 +01:00
95e454232a Chat Feature
It just works
2020-08-19 18:37:15 +01:00
47b76b422c added sanity checks 2020-08-18 19:11:31 -05:00