-
Notifications
You must be signed in to change notification settings - Fork 1
/
game_play.php
executable file
·42 lines (38 loc) · 1.43 KB
/
game_play.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
<?php
class GamePlay
{
private $fileIndex;
function __construct($stream_url, $stream_name, $stream_img, $stream_status, $game_name)
{
$this->streamURL = $stream_url;
$this->streamName = $stream_name;
$this->streamIMG = $stream_img;
$this->streamStatus = $stream_status;
$this->streamGameName = $game_name;
}
public function get_handler_id()
{
return 'twitch_handler';
}
public function generatePlayInfo($q)
{
return array(
PluginVodInfo::name => "$this->streamName - $this->streamGameName",
PluginVodInfo::description => "$this->streamStatus",
PluginVodInfo::poster_url => $this->streamIMG,
PluginVodInfo::series => array(
array(
PluginVodSeriesInfo::name => $this->streamName,
PluginVodSeriesInfo::playback_url => $this->streamURL,
PluginVodSeriesInfo::playback_url_is_stream_url => true
),
),
PluginVodInfo::initial_series_ndx => 0,
PluginVodInfo::initial_position_ms => 0,
PluginVodInfo::advert_mode => false,
PluginVodInfo::ip_address_required => true,
PluginVodInfo::actions => $q,
PluginVodInfo::valid_time_required => false
);
}
}