Commit Graph

229 Commits

Author SHA1 Message Date
b79bc56b31 Implement NPC spawning.
Protected by a simplified GM system. Either everyone is a GM (local
servers) or nobody is (public servers).
2020-08-25 04:28:42 +02:00
9aa9b76826 Made the random characters level 36.
They are meant to make testing faster, after all. No point in
restricting them from fully testing items.
2020-08-25 04:17:47 +02:00
113ce0af07 Load the NPC and warp JSON files according to the config file.
NPC data was being read from the config, but ignored.
2020-08-25 03:45:04 +02:00
6f1a72ca0f Shut Computress up.
Setting all bits in the first use flags disables tutorial messages.
2020-08-25 03:42:52 +02:00
d964a83d6d Respawn points work now.
Note that some of them weren't present in clientnpc and will need to be
manually added later.
2020-08-25 03:34:53 +02:00
d025b611a1
Merge pull request #35 from dongresource/work1
Avoid excessive copying of large Player struct
2020-08-24 19:05:24 -05:00
2f1358c124 Potential solution for the tutorial problem.
Will need to be tested on the public server.
2020-08-25 01:57:53 +02:00
c1b6ae8466 No need to unpack zero-length packet structs.
Also fixed formatting and added subheading to README.md.
2020-08-25 01:08:02 +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
c5dacb4958 Removed CRs from .gitignore and an outdated comment in config.ini. 2020-08-25 00:11:54 +02:00
fb993f0c5d Added .vimrc configured for the 4 spaces style. 2020-08-25 00:11:54 +02:00
6d3868349d removed debug output in keepAliveTimer 2020-08-24 16:12:49 -05:00
16bca39dae added simple timer system to CNShardServer 2020-08-24 16:11:40 -05:00
Onii-chan
afbf309c7e
Add player revive, vehicle mount/dismount and more (#33) 2020-08-24 16:04:56 -05:00
28ad1a0c25 fix windows support for sockets 2020-08-24 13:23:28 -05:00
JadeShrineMaiden
ff5f3966e3
Sanity checks + Starting level changes (#31)
* Sanity checks + Starting level changes

- Item movement handler checks to make sure items aren't moved from equipment slot to equipment slot.
- Item give command checks to make sure an out of bounds item is not spawned (Below iType 0 or above iType 8)
- Players now begin at level 36, consequently the item give command does not level you up now.

* Sanity Check

- Prevents out of bounds item movement by comparing it to AINVEN_COUNT.
2020-08-24 03:07:51 -05:00
55add82843
Merge pull request #32 from dongresource/work
-Wall, #pragma once, nanoSummonHandler() cleanup, verbosity levels
2020-08-23 16:57:58 -05:00
e99feb03d5 Add verbosity levels. 2020-08-23 23:09:31 +02:00
431448ffb7 Merge branch 'master' of https://github.com/OpenFusionProject/OpenFusion 2020-08-23 15:10:00 -05:00
8105d0aa88 properly handle socket errors in recieving packets 2020-08-23 15:09:51 -05:00
acf358ef51
Merge pull request #30 from CakeLancelot/clion-gitignore
Update .gitignore for CLion
2020-08-23 13:03:10 -05:00
CakeLancelot
0a8e96ebc4 Update .gitignore for Clion 2020-08-23 12:58:08 -05:00
756074cc62 Remove redundant initialization in nanoSummonHandler(). 2020-08-23 19:46:51 +02:00
51a8cc8bdf Silence -Wall warnings. 2020-08-23 19:19:12 +02:00
651ccba932 Replace ifdef guards with #pragma once
tl;dr this has potentially significant compilation speed benefits.
2020-08-23 19:14:54 +02:00
1281fdaaf0 Add -Wall to Makefile. 2020-08-23 18:30:23 +02:00
561a809f33 load warps into memory in NPCManager::init 2020-08-23 11:26:25 -05:00
0d27412d81 added getNearbyPlayers 2020-08-23 10:42:37 -05: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
d6b96389be added sanity checks to nanos 2020-08-22 22:15:27 -05:00
dongresource
6129c0b4e2
Players can now see eachother's nanos. (#28) 2020-08-22 19:52:54 -05:00
c9bf3d1896 restored default config.ini 2020-08-22 19:27:08 -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
0ff1f74cd3 fixed inet_ntoa warnings 2020-08-22 14:02:58 -05:00
35b424c531 fixed warnings for VC++ 2020-08-22 13:38:27 -05:00
2072bdcff7 updated appveyor 2020-08-22 13:29:38 -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
cd9fb6ec25 added sanity check to exitGame() 2020-08-22 13:08:37 -05:00
Onii-chan
56bf0db20d
Added more nano features (commands, equip & unequip, powers) (#26)
* Revert "fixed window build"

This reverts commit b94f602537.

* Revert "Revert "fixed window build""

This reverts commit dac4457ed2.

* Add nano power feature

* Update CNShardServer.hpp

* Update CNShardServer.hpp

* Test: Add nano power feature

Nano powers are set to the first power in its selection by default.

* Update NanoManager.cpp

* Test: More nano features

* Update NanoManager.hpp

* Update PlayerManager.hpp

* Update PlayerManager.cpp

* Updated indentations

* Update PlayerManager.cpp

* Add DEBUGLOG()

Co-authored-by: CPunch <sethtstubbs@gmail.com>
2020-08-22 13:02:08 -05:00
11fed7db10
Merge pull request #27 from dongresource/defines
Enumerate all packets (+misc FF defines), print packet names, verbose printing
2020-08-22 12:50:16 -05:00
35c622d8a2 Add support for verbose logging. 2020-08-22 19:39:13 +02:00
43f2def80b Report unhandled packets in string form. 2020-08-22 19:19:46 +02:00
0ac600e223 Extracted all packet ids to a single, definitive enum.
It also contains other constant values that might be relevant at some
point.
2020-08-22 17:25:42 +02:00
FinnHornhoover
5f65a84b02
Fix unhandled exception in NPCManager (#24)
* fixed PROTOCOL_VERSION not being defined

* handle exceptions in NPCManager init
2020-08-22 01:46:52 -05:00
78c493b461 switched default ip in config.ini 2020-08-21 23:37:09 -05:00
f71e1349c1 temp fix for U16toU8 edgecase 2020-08-21 22:11:04 -05:00
cff382a8ce sets a limit for sendData() 2020-08-21 21:32:22 -05:00
bbd6c5b532 moved header libraries 2020-08-21 21:03:12 -05:00
JadeShrineMaiden
ab6df26f92
Disabled GM mode (#22)
Temporarily disabled, players can now use item commands without GM mode.
2020-08-21 19:38:10 -05:00