Talishar is a browser-based platform to play Flesh and Blood. It is a fan-made FABTCG project not associated with Legend Story Studios.
Visit Talishar.net to get playing Flesh & Blood in your browser right now!
This is the back end client for Talishar.net - completely separate from the front end. In order to test Talishar locally, you will need to install the front end project.
Learn more about the Talishar-FE project here: Talishar-FE Learn more about the CardImages project her 9E7A e: Talishar-FE
- Docker
- Talishar-FE
Easier to do on *nix OS than on MS OS. It's important if you want to run ad-hoc scripts like zzCardCodeGenerator.php to have Talishar-FE and CardImages repositories located in the same directory as Talishar.
The docker-compose file is set up to mount the ../Talishar-FE directory into the container. In order to generate new cards and images, those are generated in ../CardImages directory.
First clone the repo:
git clone https://github.com/Talishar/Talishar.git
Into the directory we go:
cd Talishar
Run the script to do the setup and start the docker containers
bash start.sh
- NOTE: If you're on windows, the newline characters might mess up this script. It's only two lines so you can just run them manually in Windows Powershell or git Bash:
cp -n HostFiles/RedirectorTemplate.php HostFiles/Redirector.php
docker compose up -d
The containers are running in detached (background) mode. If you need to stop them:
bash stop.sh
or
docker compose down
- As noted in the Quickstart Guide below you need a unique Redirector file setup. You can customise it, it's required, but it's not checked into the repo. So the script makes a copy of the Redirector file before launching the containers.
- The stop script just stops the containers by calling
docker compose down
- After the first time making the Redirector file, you can bring the docker containers up and down using
docker compose up
anddocker compose down
and whatever else you're used to.
- Xdebug is added to the container and can be configured through the
docker/docker-php-ext-xdebug.ini
file. The xdebug port is9003
. You can use the Xdebug helper browser extension to set breakpoints and debug the code. You can also attach to the debugger from your IDE. - The
idekey
allows you to filter out requests to the Xdebug server. Theidekey
is set toPHPSTORM
by default. You can change this to anything you want. Just make sure it matches theidekey
in your IDE settings.
- Create a PHP Remote Debug configuration in PHPStorm
- Check to Filter debug connection by IDE key and set the IDE key to PHPSTORM (or whatever you've changed this to in the xdebug configuration)
- Open up the
...
for the Server and create a new Server - Set the Host to
0.0.0.0
and the port to9003
(or whatever you've set the xdebug port to) as well as the debugger to Xdebug - Check the
Use path mappings
and map the root of the project to the root of the container/var/www/html/game
- Now you should be able to run this configuration, and it will wait for a connection from the xdebug server in the container. You can set a breakpoint somewhere in the code and it should stop there when you make a request to the server.
- Xdebug halts execution and can cause issues in the files where we have infinite loops. You can skip these files in PHPStorm by going to
Settings -> Languages & Frameworks -> PHP -> Debug -> Skipped Paths
and adding the paths to the files you want to skip as well as to theSettings -> Languages & Frameworks -> PHP -> Debug -> Step Filters -> Skipped Files
. - OPCache is included to speed up performance, but it can have issues with Xdebug. You can always disable OPCache in the ini file
- Install the PHP Debug extension
- Create a launch.json file in the .vscode directory
- Add the following configuration to the launch.json file:
{
"version": "0.2.0",
"configurations": [
{
"name": "Listen for XDebug",
"type": "php",
"request": "launch",
"port": 9003,
"pathMappings": {
"/var/www/html/game": "${workspaceFolder}"
}
}
]
}
- Set a breakpoint in the code
- Start the debugger by selecting the
Listen for XDebug
configuration and clicking the green play button
If you would like to contribute, be sure to join the discord to chat with fellow contributors.
All artwork and card images © Legend Story Studios.
Talishar.net is in no way affiliated with Legend Story Studios. Legend Story Studios®, Flesh and Blood™, and set names are trademarks of Legend Story Studios. Flesh and Blood characters, cards, logos, and art are property of Legend Story Studios.