Compare commits
2 Commits
cfd06a31bd
...
3546f779b7
Author | SHA1 | Date |
---|---|---|
Christopher Latza | 3546f779b7 | |
Christopher Latza | 303a682eb1 |
|
@ -53,10 +53,11 @@ while(TRUE)
|
||||||
echo "Sending start info to discord...";
|
echo "Sending start info to discord...";
|
||||||
$result = file_get_contents($DiscordWebhook, false, stream_context_create($startOptions));
|
$result = file_get_contents($DiscordWebhook, false, stream_context_create($startOptions));
|
||||||
echo "done.\n";
|
echo "done.\n";
|
||||||
|
|
||||||
|
$lastOnlineTime = time();
|
||||||
system("rtmpdump -r ".$StreamURL." -m 15 -o /dev/null");
|
system("rtmpdump -r ".$StreamURL." -m 15 -o /dev/null");
|
||||||
|
|
||||||
if(($lastOnlineTime + 60) < time())
|
if(($lastOnlineTime + 10) < time())
|
||||||
{
|
{
|
||||||
echo "Sending end info to discord...";
|
echo "Sending end info to discord...";
|
||||||
$result = file_get_contents($DiscordWebhook, false, stream_context_create($endOptions));
|
$result = file_get_contents($DiscordWebhook, false, stream_context_create($endOptions));
|
||||||
|
|
Loading…
Reference in New Issue