I will no longer be working on this (most likely), and as incomplete as it is, I felt that this would have been wasted sitting as a private repo. Since this code is fairly old, you'll see some "severe" vulnerabilities for some packages used but all of that only pertains to development and won't affect production.
Key features:
- Guest players
- Server-side auto attacks (gain EXP/loot while offline!)
- Websocket based rather than HTTP polling
- Multi class/starting location
How to install: PHP 8.2, MySQL > 8 or MariaDB > 10.6, NodeJS 18, any modern version of Redis will work. Linux is a must since you will need PHP's pcntl.
Install soketi by running npm install -g @soketi/soketi
and cp soketi.json.example soketi.json
and run configure the values as you like and run soketi start --config=soketi.json
Grab your invisible reCAPTCHA v2 key too while you're at it since you'll need to put it in your .env
Now after you've done your composer update
you'll want to install Laravel Horizon php artisan horizon:install
and run it using php artisan horizon
Once again, I've nuked the development database containing pre-configured values unfortunately.
You're going to need to create a MOTD
row in the server_settings
table and create a couple of starter locations ID'd 1-4 and a coupon mobs for those locations too. If you accidentally already entered the game, just do a quick php artisan cache:clear
and it should be good
We'll now be at the home screen
If you're a spammer with a negative social credit IP address, you'll see this when you try to get in as a guest
Complete the captcha and you'll be greeted with the character screen
Very feature in-complete but hey, your game is already better than Lyrania.
Alternatively, if you want a "feature complete" but very old PBBG code, you can take a look at To Lands Unknown