This is a small app that allows a user to compare games from two different league of legends profiles in one screen
- Clone the repo from https://github.com/dakotawashok/loldashboard.git
- Make a new table in your local database for the app
- Copy the .env.example into a .env file and enter your database credentials
- Run
composer install
from the project root directory - Run
php artisan key:generate
from the project root directory - Run
php artisan migrate:install
from the project root directory important Make sure you run this from inside the virtual machine you're using - Run
php artisan migrate
from the project root directory important Make sure you run this from inside the virutal machine you're using - Run
npm install
from the project root directory - Optional if you feel like having a nice looking URL like I do, make a new record in your hosts file
- Optional if you feel like having a nice looking URL like I do, change the APP_URL constant in your .env file to whatever you made the URL in step 8
- Optional Set up your vhost/apache .conf file if you need to. Make sure to restart apache after this step
- Download the zip from https://github.com/kevinohashi/php-riot-api
- Unzip the zip you just downloaded, and move it over to the ./Vendor/ folder
- In the
./vender/riotapi/php-riot-api.php
file, replace INSERT_API_KEY_HERE with your actual riot api key - Run
npm run watch
and go to your URL you set up and voila, you're good to go!
Since Riot comes out with updates to their game fairly often, sometimes the json files stored in ./public/jsonfiles/
get outdated. To counter this, I've made a quick little script that goes to their datadragon service and updates the json
files that we have. From the project root directory, run:
php artisan updatestaticfiles {--update}
The --update option also goes into the javascript mixin file and changes the riot_api_version constant to the most up to date version from their website.
You might have to remove a line of code in the ./vendor/riotapi/php-riot-api.php
file. It's line 381 and it should
read echo("sleeping for".($interval - $timeSinceOldest + 1)." seconds\n");