承接 spiregg/riot-api-datadragon 相关项目开发

从需求分析到上线部署,全程专人跟进,保证项目质量与交付效率

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

spiregg/riot-api-datadragon

最新稳定版本:3.0.0

Composer 安装命令:

composer require spiregg/riot-api-datadragon

包简介

Riot DataDragon API wrapper for PHP8

README 文档

README

Version v1.0.0

Build Status Test Coverage Packagist Packagist Support Project

Table of Contents

  1. Introduction
  2. Downloading
  3. DataDragon API

Introduction

Welcome to the DataDragon PHP library repo! The goal of this library is to create easy-to-use library for anyone who might need one.

Here are some handy features:

  • Profile icon URL and HTML embed generating
  • Champion splash image URL and HTML embed generating
  • Champion loading image URL and HTML embed generating
  • Champion icon URL and HTML embed generating
  • Sprite image URL and HTML embed generating
  • Spell, passive, item and summoner spell icon URL and HTML embed generating
  • Runes reforged icon URL and HTML embed generating
  • Static resource (champions, spells, items, runes, ...) loading and processing

Please, refer mainly to the wiki pages. This file contains only general introduction to library features.

Downloading

The easiest way to download and use this library is via Composer. If you are not using Composer yet, you should start right now!

While having Composer installed on your machine it takes only composer require "dolejska-daniel/riot-api-datadragon:^1" command to get the library ready to roll!

For additional information about downloading and initial setup, please see the wiki pages.

DataDragon API

How easy is it to work with static images? For instance, to get loading screen art of Orianna?

Source:

echo DataDragonAPI::getChampionLoading('Orianna');
echo DataDragonAPI::getChampionLoading('Orianna', 7);

Output:

<img alt="Orianna" class="dd-icon dd-loading" src="https://ddragon.leagueoflegends.com/cdn/img/champion/loading/Orianna_0.jpg">
<img alt="Orianna" class="dd-icon dd-loading" src="https://ddragon.leagueoflegends.com/cdn/img/champion/loading/Orianna_7.jpg">

Render:

Orianna Dark Star Orianna

...a bit of nostalgia?

Source:

DataDragonAPI::iniByVersion('0.151.2');
echo DataDragonAPI::getItemIcon(3132);
echo DataDragonAPI::getItemIcon(3126);
echo DataDragonAPI::getItemIcon(3138);

Output:

<img alt="3132" class="dd-icon dd-item" src="https://ddragon.leagueoflegends.com/cdn/0.151.2/img/item/3132.png">
<img alt="3126" class="dd-icon dd-item" src="https://ddragon.leagueoflegends.com/cdn/0.151.2/img/item/3126.png">
<img alt="3138" class="dd-icon dd-item" src="https://ddragon.leagueoflegends.com/cdn/0.151.2/img/item/3138.png">

Render:

Heart of Gold Madred's Bloodrazor Leviathan

...or to display icon of champion and its spells based on its object from API?

Source:

// ...

$orianna = $api->getStaticChampion(61, true);
echo DataDragonAPI::getChampionSplashO($orianna);

foreach($orianna->spells as $spell)
    echo DataDragonAPI::getChampionSpellIconO($spell);

Output:

<img alt="Orianna" class="dd-icon dd-icon-champ" src="https://ddragon.leagueoflegends.com/cdn/8.24.1/img/champion/Orianna.png">

<img alt="OrianaIzunaCommand" class="dd-icon dd-spell" src="https://ddragon.leagueoflegends.com/cdn/8.24.1/img/spell/OrianaIzunaCommand.png">
<img alt="OrianaDissonanceCommand" class="dd-icon dd-spell" src="https://ddragon.leagueoflegends.com/cdn/8.24.1/img/spell/OrianaDissonanceCommand.png">
<img alt="OrianaRedactCommand" class="dd-icon dd-spell" src="https://ddragon.leagueoflegends.com/cdn/8.24.1/img/spell/OrianaRedactCommand.png">
<img alt="OrianaDetonateCommand" class="dd-icon dd-spell" src="https://ddragon.leagueoflegends.com/cdn/8.24.1/img/spell/OrianaDetonateCommand.png">

Render:

Orianna OrianaIzunaCommand OrianaDissonanceCommand OrianaRedactCommand OrianaDetonateCommand

For more, please see the wiki pages. More usage examples for DataDragonAPI can be found here.

Other Riot APIs

Library Description Latest Version Stable Version
All APIs (metapackage) GitHub Latest Release GitHub Release PHP Version
League of Legends API GitHub Latest Release GitHub Release PHP Version
Teamfight Tactics API GitHub Latest Release GitHub Release PHP Version
Legends of Runeterra API GitHub Latest Release GitHub Release PHP Version
Valorant API GitHub Latest Release GitHub Release PHP Version

统计信息

  • 总下载量: 863
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 0
  • 点击次数: 3
  • 依赖项目数: 1
  • 推荐数: 0

GitHub 信息

  • Stars: 0
  • Watchers: 0
  • Forks: 6
  • 开发语言: PHP

其他信息

  • 授权协议: GPL-3.0-or-later
  • 更新时间: 2023-03-19

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固