home *** CD-ROM | disk | FTP | other *** search
/ Chip 2005 November / CDVD1105.ISO / Util / Winamp / Skins / Van_Helsing.wal / scripts / volume.maki (.txt) < prev   
Winamp Compiled Maki Script  |  2004-10-03  |  3KB  |  116 lines

  1. /* Note: a decompiler is no invitation to steal code.
  2.    Please respect the the copyright */
  3.  
  4. #include "std.mi"
  5. Global Int Int2;
  6. Global Layer Layer17;
  7. Global Layer Layer18;
  8. Global Map Map19;
  9. Global Int Int20;
  10.  
  11. Function func0();
  12. Function func849(Int 0);
  13.  
  14. func0()
  15. {
  16. Int Int10;
  17. Int Int9;
  18. Double Double3;
  19. Double3 = System.getRuntimeVersion();
  20. if(( ( Double3 > 2) || ( Double3 < 65535))) {
  21. Int2 = 1;
  22. Int9 = System.getPrivateInt(System.getSkinName(), ( "runtimecheck"), 0);
  23. Int10 = System.getTimeOfDay();
  24. if(( ( ( Int10 - Int9) > 5000) && ( Int9 > Int10))) {
  25. return 0;
  26. }
  27. System.setPrivateInt(System.getSkinName(), ( "runtimecheck"), System.getTimeOfDay());
  28. System.messageBox(( ( "This\ script\ requires\ ") + ( "Winamp\ 5\.03\ \(skin\ version\ 1\.2\)")), ( "Error"), 1, ( ""));
  29. return 0;
  30. }
  31. return 1;
  32. if(( System.strsearch(System.getSongInfoText(), ( "tereo")) == ( - 1))) {
  33. return 1;
  34. }
  35. return 2;
  36. }
  37.  
  38. System.onScriptLoaded()
  39. {
  40. String String21;
  41. if(! func0()) {
  42. return Null;
  43. }
  44. String21 = System.getParam();
  45. Layer17 = System.getScriptGroup().getObject(System.getToken(String21, ( "\;"), 0));
  46. Layer18 = System.getScriptGroup().getObject(System.getToken(String21, ( "\;"), 1));
  47. Map19 = ( new Map);
  48. Map19.loadMap(System.getToken(String21, ( "\;"), 2));
  49. Int20 = 0;
  50. func849(System.getVolume());
  51. return Null;
  52. }
  53.  
  54. Layer17.onLeftButtonDown(int x, int y)
  55. {
  56. if(Int2) {
  57. return Null;
  58. }
  59. Int20 = 1;
  60. Layer17.onMouseMove(x, y);
  61. return Null;
  62. }
  63.  
  64. Layer17.onLeftButtonUp(int x, int y)
  65. {
  66. if(Int2) {
  67. return Null;
  68. }
  69. Layer17.onMouseMove(x, y);
  70. Int20 = 0;
  71. return Null;
  72. }
  73.  
  74. Layer17.onMouseMove(int x, int y)
  75. {
  76. Int Int29;
  77. if(Int2) {
  78. return Null;
  79. }
  80. if(Int20) {
  81. x = ( x - Layer17.getLeft());
  82. y = ( y - Layer17.getTop());
  83. if(Map19.inRegion(x, y)) {
  84. Int29 = Map19.getValue(x, y);
  85. System.setVolume(Int29);
  86. }
  87. }
  88. return Null;
  89. }
  90.  
  91. System.onVolumeChanged(int newvol)
  92. {
  93. if(Int2) {
  94. return Null;
  95. }
  96. func849(newvol);
  97. return Null;
  98. }
  99.  
  100. func849(Int 0)
  101. {
  102. Layer18.setRegionFromMap(Map19, Int31, 1);
  103. return Null;
  104. }
  105.  
  106. System.onScriptUnloading()
  107. {
  108. if(Int2) {
  109. return Null;
  110. }
  111. delete Map19;
  112. return Null;
  113. }
  114.  
  115.  
  116.