summaryrefslogtreecommitdiff
path: root/plugins/Watrack/docs/wat.php
diff options
context:
space:
mode:
authorVadim Dashevskiy <watcherhd@gmail.com>2012-10-08 18:43:29 +0000
committerVadim Dashevskiy <watcherhd@gmail.com>2012-10-08 18:43:29 +0000
commit864081102a5f252415f41950b3039a896b4ae9c5 (patch)
treec6b764651e9dd1f8f53b98eab05f16ba4a492a79 /plugins/Watrack/docs/wat.php
parentdb5149b48346c417e18add5702a9dfe7f6e28dd0 (diff)
Awkwars's plugins - welcome to our trunk
git-svn-id: http://svn.miranda-ng.org/main/trunk@1822 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/Watrack/docs/wat.php')
-rw-r--r--plugins/Watrack/docs/wat.php28
1 files changed, 28 insertions, 0 deletions
diff --git a/plugins/Watrack/docs/wat.php b/plugins/Watrack/docs/wat.php
new file mode 100644
index 0000000000..d15049dd72
--- /dev/null
+++ b/plugins/Watrack/docs/wat.php
@@ -0,0 +1,28 @@
+<?php
+
+include_once 'const.php';
+
+function mbot_load()
+{
+ mb_SchReg("ex/1min","* * *",'every_1min',1,1);
+}
+
+function every_1min()
+{
+ $songinfo = 0;
+ if(mb_SysCallService(MS_WAT_GETMUSICINFO, WAT_INF_ANSI,
+ mb_SysGetPointer($songinfo))!=WAT_PLS_NORMAL)
+ return 0;
+
+ $artist_pos = mb_SysGetNumber($songinfo+wato_artist, 4);
+ $artist = mb_SysGetString($artist_pos);
+
+ $title_pos = mb_SysGetNumber($songinfo+wato_title, 4);
+ $title = mb_SysGetString($title_pos);
+
+ $newtext = "mp3: $artist - $title";
+
+ mb_MsgBox($newtext, "MBot", 4);
+ return 0;
+}
+?> \ No newline at end of file