A toy implementation of the FusionFall Packet Protocol in Go
Go to file
CPunch c0ba365cf5 CNPeer/Service refactor
- each CNPeer is given a unique chan *protocol.Event to pass events to
the service.handleEvents() loop. this is now passed to CNPeer.Handler()
as opposed to NewCNPeer().
- service has basically been rewritten. handleEvents() main loop uses
reflect.SelectCase() now to handle all of the eRecv channels for each
peer
- new protocol Event type: EVENT_CLIENT_CONNECT
- Added service_test.go; blackbox-styled testing like the others.
TestService() starts a service and spins up  a bunch of dummy peers
and verifies that each packet sent causes the corresponding packet
handler to be called.
2023-11-29 19:57:45 -06:00
.github/workflows fix workflow event trigger 2023-11-26 17:00:37 -06:00
cmd moved 'core' to 'internal' 2023-08-23 18:16:24 -05:00
config added NPCs; added tdata submodule 2023-06-27 00:36:02 -05:00
internal CNPeer/Service refactor 2023-11-29 19:57:45 -06:00
login CNPeer/Service refactor 2023-11-29 19:57:45 -06:00
shard CNPeer/Service refactor 2023-11-29 19:57:45 -06:00
tdata@cc65dbb402 added NPCs; added tdata submodule 2023-06-27 00:36:02 -05:00
tools genstructs.py: refactor; use match/case statement 2023-11-22 16:02:00 -06:00
.gitignore removed test.db 2023-03-09 15:33:39 -06:00
.gitmodules added NPCs; added tdata submodule 2023-06-27 00:36:02 -05:00
build.sh Switched to redis/postgres, major refactoring 2023-06-22 01:53:38 -05:00
compose.yaml added NPCs; added tdata submodule 2023-06-27 00:36:02 -05:00
Dockerfile dockerfile: switch to scratch 2023-06-20 18:33:29 -05:00
go.mod test: started internal/db test cases 2023-11-21 13:58:59 -06:00
go.sum test: started internal/db test cases 2023-11-21 13:58:59 -06:00
README.md better readme 2023-08-23 18:38:14 -05:00

gopenfusion

A toy implementation of the Fusionfall Packet Protocol and accompanying services, written in Go.

Landwalker demo

An implementation of a landwalker server is located in login/ && shard/. This includes a functional login server and a dummy shard (supporting the minimum amount of packets necessary). There is minimal support for NPCs, and minimal support for player interaction (chat & player movement being mostly it).

Startup the environment using

$ chmod +x ./build.sh && ./build.sh
$ docker compose up

The environment consists of a shard service, login service, redis && postgres containers. redis is used to pass login metadata between the login and shard services, while postgres is just used to store player accounts and characters.

login server is hosted at 127.0.0.1:23000, just join from your favorite client

Generating structures

Dump and decompile the Assembly - CSharp.dll assembly from the fusionfall main.unity3d, using a tool like ilspycmd. The full output source can then be passed to genstructs.py script located in tools/, which will handle scraping constants and calculating structure padding. See the script for details on usage.