login  Naam:   Wachtwoord: 
Registreer je!
 Scripts:

Scripts > Overige > Mirc > Advertisement dialog

Advertisement dialog

Auteur: Rumbaar - 08 september 2004 - 22:01 - Gekeurd door: Dennisvb - Hits: 4026 - Aantal punten: (0 stemmen)




Script is dus niet zelf gemaakt 
Script door by Rumbaar

Code:
  1. dialog advert {
  2. title "ADVERTISEMENT DIALOG"
  3. size 10 110 297 143
  4. option dbu
  5. icon Pictures\obiwan.ico, 0
  6. edit "", 1, 13 18 20 10, limit 3 center
  7. edit "", 2, 41 11 183 24, multi autovs vsbar
  8. check "Standard", 3, 225 11 45 9, left
  9. check "Action", 4, 225 19 45 9, left
  10. check "Whisper", 5, 225 27 45 9, left
  11. button "On", 6, 271 12 20 10
  12. button "Off", 7, 271 25 20 10
  13. button "Close", 100, 118 129 37 12, ok cancel
  14. edit "", 12, 13 47 20 10, limit 3 center
  15. edit "", 13, 41 40 183 24, multi autovs vsbar
  16. check "Standard", 14, 225 40 45 9, left
  17. check "Action", 15, 225 48 45 9, left
  18. check "Whisper", 16, 225 56 45 9, left
  19. button "On", 17, 271 41 20 10
  20. button "Off", 18, 271 54 20 10
  21. edit "", 19, 13 77 20 10, limit 3 center
  22. edit "", 20, 41 70 183 24, multi autovs vsbar
  23. check "Standard", 21, 225 69 45 9, left
  24. check "Action", 22, 225 77 45 9, left
  25. check "Whisper", 23, 225 85 45 9, left
  26. button "On", 24, 271 70 20 10
  27. button "Off", 25, 271 83 20 10
  28. edit "", 26, 13 107 20 10, limit 3 center
  29. button "On", 27, 271 100 20 10
  30. button "Off", 28, 271 113 20 10
  31. check "Whisper", 29, 225 115 45 9, left
  32. check "Action", 30, 225 107 45 9, left
  33. edit "", 31, 41 100 183 24, multi autovs vsbar
  34. check "Standard", 32, 225 99 45 9, left
  35. text "Interval", 33, 6 11 35 8, center
  36. text "Min(s)", 34, 7 27 35 8, center
  37. text "Interval", 35, 7 40 35 8, center
  38. text "Interval", 36, 6 70 35 8, center
  39. text "Interval", 37, 6 100 35 8, center
  40. text "Min(s)", 38, 6 56 35 8, center
  41. text "Min(s)", 39, 6 86 35 8, center
  42. text "Min(s)", 40, 6 116 35 8, center
  43. box "Preferences", 41, 2 2 293 126
  44. text "-=[ Kenobi Version 4 ]=-", 42, 2 131 114 8, disable
  45. }
  46.  
  47.  
  48. ;Start Up
  49. ;Set initial default settings for the dialog
  50. On *:Dialog:advert:init:*: {
  51. dll $mdx SetMircVersion $version
  52. dll $mdx MarkDialog $dname
  53. dll $mdx SetFont $dname
  54. dll $mdx SetColor $dname
  55. dll $mdx SetFont $dname 33,34,35,38,36,39,37,40,42 14 50 Georgia Bold Italic
  56. dll $mdx SetColor 33,34,35,38,36,39,37,40,42 text $rgb(67,110,238)
  57. if (%advert1tim != $null) { did -ra advert 1 %advert1tim } | else { did -ra advert 1 5 }
  58. if (%advert1msg != $null) { did -ra advert 2 %advert1msg } | else { did -ra advert 2 Enter Message Here!! }
  59. if (%advert1 == $null) { did -c advert 3 }
  60. if (%advert1 == std) { did -c advert 3 }
  61. if (%advert1 == act) { did -c advert 4 }
  62. if (%advert1 == ntc) { did -c advert 5 }
  63. if (%advert2tim != $null) { did -ra advert 12 %advert2tim } | else { did -ra advert 12 5 }
  64. if (%advert2msg != $null) { did -ra advert 13 %advert2msg } | else { did -ra advert 13 Enter Message Here!! }
  65. if (%advert2 == $null) { did -c advert 14 }
  66. if (%advert2 == std) { did -c advert 14 }
  67. if (%advert2 == act) { did -c advert 15 }
  68. if (%advert2 == ntc) { did -c advert 16 }
  69. if (%advert3tim != $null) { did -ra advert 19 %advert3tim } | else { did -ra advert 19 5 }
  70. if (%advert3msg != $null) { did -ra advert 20 %advert3msg } | else { did -ra advert 20 Enter Message Here!! }
  71. if (%advert3 == $null) { did -c advert 21 }
  72. if (%advert3 == std) { did -c advert 21 }
  73. if (%advert3 == act) { did -c advert 22 }
  74. if (%advert3 == ntc) { did -c advert 23 }
  75. if (%advert4tim != $null) { did -ra advert 26 %advert4tim } | else { did -ra advert 26 5 }
  76. if (%advert4msg != $null) { did -ra advert 31 %advert4msg } | else { did -ra advert 31 Enter Message Here!! }
  77. if (%advert4 == $null) { did -c advert 32 }
  78. if (%advert4 == std) { did -c advert 32 }
  79. if (%advert4 == act) { did -c advert 30 }
  80. if (%advert4 == ntc) { did -c advert 29 }
  81. }
  82.  
  83. On *:Dialog:advert:sclick:100: { splay on.wav }
  84.  
  85. ;Advertising Part
  86. On *:Dialog:advert:sclick:3: { did -u advert 4 | did -u advert 5 | splay on.wav }
  87. On *:Dialog:advert:sclick:4: { did -u advert 3 | did -u advert 5 | splay on.wav }
  88. On *:Dialog:advert:sclick:5: { did -u advert 3 | did -u advert 4 | splay on.wav }
  89. On *:Dialog:advert:sclick:6: {
  90. if ( $did(1) == $null) { dialog -m error error | splay on.wav | halt }
  91. set %advert1tim $did(1)
  92. msg1
  93. if ($did(3).state == 1) { .timeradv1 0 $calc($did(1)*60) /amsg %advert1msg | set %advert1 std | splay on.wav | echo -a 8,4-=[ 4,1 Advertisement 1 via Standard On 8,4 ]=- }
  94. if ($did(4).state == 1) { .timeradv1 0 $calc($did(1)*60) /ame %advert1msg | set %advert1 act | splay on.wav | echo -a 8,4-=[ 4,1 Advertisement 1 via Action On 8,4 ]=- }
  95. if ($did(5).state == 1) { .timeradv1 0 $calc($did(1)*60) /mnotice1 | set %advert1 ntc | splay on.wav | echo -a 8,4-=[ 4,1 Advertisement 1 via Whisper On 8,4 ]=- }
  96. }
  97. On *:Dialog:advert:sclick:7: { .timeradv1 off | splay on.wav | echo -a 8,4-=[ 4,1 Advertisement 1 Off 8,4 ]=- }
  98. On *:Dialog:advert:sclick:14: { did -u advert 15 | did -u advert 16 | splay on.wav }
  99. On *:Dialog:advert:sclick:15: { did -u advert 14 | did -u advert 16 | splay on.wav }
  100. On *:Dialog:advert:sclick:16: { did -u advert 14 | did -u advert 15 | splay on.wav }
  101. On *:Dialog:advert:sclick:17: {
  102. if ( $did(12) == $null) { dialog -m error error | splay on.wav | halt }
  103. set %advert2tim $did(12)
  104. msg2
  105. if ($did(14).state == 1) { .timeradv2 0 $calc($did(12)*60) /amsg %advert2msg | set %advert2 std | splay on.wav | echo -a 8,4-=[ 4,1 Advertisement 2 via Standard On 8,4 ]=- }
  106. if ($did(15).state == 1) { .timeradv2 0 $calc($did(12)*60) /ame %advert2msg | set %advert2 act | splay on.wav | echo -a 8,4-=[ 4,1 Advertisement 2 via Action On 8,4 ]=- }
  107. if ($did(16).state == 1) { .timeradv2 0 $calc($did(12)*60) /mnotice2 | set %advert2 ntc | splay on.wav | echo -a 8,4-=[ 4,1 Advertisement 2 via Whisper On 8,4 ]=- }
  108. }
  109. On *:Dialog:advert:sclick:18: { .timeradv2 off | splay on.wav | echo -a 8,4-=[ 4,1 Advertisement 2 Off 8,4 ]=- }
  110. On *:Dialog:advert:sclick:21: { did -u advert 22 | did -u advert 23 | splay on.wav }
  111. On *:Dialog:advert:sclick:22: { did -u advert 21 | did -u advert 23 | splay on.wav }
  112. On *:Dialog:advert:sclick:23: { did -u advert 21 | did -u advert 22 | splay on.wav }
  113. On *:Dialog:advert:sclick:24: {
  114. if ( $did(19) == $null) { dialog -m error error | splay on.wav | halt }
  115. set %advert3tim $did(19)
  116. msg3
  117. if ($did(21).state == 1) { .timeradv3 0 $calc($did(19)*60) /amsg %advert3msg | set %advert3 std | splay on.wav | echo -a 8,4-=[ 4,1 Advertisement 3 via Standard On 8,4 ]=- }
  118. if ($did(22).state == 1) { .timeradv3 0 $calc($did(19)*60) /ame %advert3msg | set %advert3 act | splay on.wav | echo -a 8,4-=[ 4,1 Advertisement 3 via Action On 8,4 ]=- }
  119. if ($did(23).state == 1) { .timeradv3 0 $calc($did(19)*60) /mnotice3 | set %advert3 ntc | splay on.wav | echo -a 8,4-=[ 4,1 Advertisement 3 via Whisper On 8,4 ]=- }
  120. }
  121. On *:Dialog:advert:sclick:25: { .timeradv3 off | splay on.wav | echo -a 8,4-=[ 4,1 Advertisement 3 Off 8,4 ]=- }
  122. On *:Dialog:advert:sclick:32: { did -u advert 30 | did -u advert 29 | splay on.wav }
  123. On *:Dialog:advert:sclick:30: { did -u advert 29 | did -u advert 32 | splay on.wav }
  124. On *:Dialog:advert:sclick:29: { did -u advert 30 | did -u advert 32 | splay on.wav }
  125. On *:Dialog:advert:sclick:27: {
  126. if ( $did(26) == $null) { dialog -m error error | splay on.wav | halt }
  127. set %advert4tim $did(26)
  128. msg4
  129. if ($did(32).state == 1) { .timeradv4 0 $calc($did(26)*60) /amsg %advert4msg | set %advert4 std | splay on.wav | echo -a 8,4-=[ 4,1 Advertisement 4 via Standard On 8,4 ]=- }
  130. if ($did(30).state == 1) { .timeradv4 0 $calc($did(26)*60) /ame %advert4msg | set %advert4 act | splay on.wav | echo -a 8,4-=[ 4,1 Advertisement 4 via Action On 8,4 ]=- }
  131. if ($did(29).state == 1) { .timeradv4 0 $calc($did(26)*60) /mnotice4 | set %advert4 ntc | splay on.wav | echo -a 8,4-=[ 4,1 Advertisement 4 via Whisper On 8,4 ]=- }
  132. }
  133. On *:Dialog:advert:sclick:28: { .timeradv4 off | splay on.wav | echo -a 8,4-=[ 4,1 Advertisement 4 Off 8,4 ]=- }
  134.  
  135. ;aliases
  136. alias advert { dialog -m advert advert }
  137.  
  138. alias msg1 {
  139. var %msg1 = 1
  140. %advert1msg = ""
  141. :nextline
  142. if ($did(2,%msg1) == $null ) return
  143. %advert1msg = %advert1msg $did(2,%msg1)
  144. inc %msg1
  145. goto nextline
  146. }
  147.  
  148. alias msg2 {
  149. var %msg2 = 1
  150. %advert2msg = ""
  151. :nextline
  152. if ($did(13,%msg2) == $null ) return
  153. %advert2msg = %advert2msg $did(13,%msg2)
  154. inc %msg2
  155. goto nextline
  156. }
  157.  
  158. alias msg3 {
  159. var %msg3 = 1
  160. %advert3msg = ""
  161. :nextline
  162. if ($did(20,%msg3) == $null ) return
  163. %advert3msg = %advert3msg $did(20,%msg3)
  164. inc %msg3
  165. goto nextline
  166. }
  167.  
  168. alias msg4 {
  169. var %msg4 = 1
  170. %advert4msg = ""
  171. :nextline
  172. if ($did(31,%msg4) == $null ) return
  173. %advert4msg = %advert4msg $did(31,%msg4)
  174. inc %msg4
  175. goto nextline
  176. }
  177.  
  178. alias mnotice1 {
  179. set %m1 1
  180. set %mnick1 $nick($active,%m1)
  181. if (%mnick1 == $null) { halt | unset %except1 }
  182. if (%mnick1 == %except) { inc %m1 | goto next }
  183. if (%mnick1 == $me) { inc %m1 | goto next }
  184. if (%mnick1 != $me) { notice %mnick1 %advert1msg }
  185. inc %m1
  186. goto next
  187. }
  188. alias mnotice2 {
  189. set %m2 1
  190. set %mnick2 $nick($active,%m2)
  191. if (%mnick2 == $null) { halt | unset %except2 }
  192. if (%mnick2 == %except) { inc %m2 | goto next }
  193. if (%mnick2 == $me) { inc %m2 | goto next }
  194. if (%mnick2 != $me) { notice %mnick2 %advert2msg }
  195. inc %m2
  196. goto next
  197. }
  198. alias mnotice3 {
  199. set %m3 1
  200. set %mnick3 $nick($active,%m3)
  201. if (%mnick3 == $null) { halt | unset %except3 }
  202. if (%mnick3 == %except) { inc %m3 | goto next }
  203. if (%mnick3 == $me) { inc %m3 | goto next }
  204. if (%mnick3 != $me) { notice %mnick3 %advert3msg }
  205. inc %m3
  206. goto next
  207. }
  208. alias mnotice4 {
  209. set %m4 1
  210. set %mnick4 $nick($active,%m4)
  211. if (%mnick4 == $null) { halt | unset %except4 }
  212. if (%mnick4 == %except) { inc %m4 | goto next }
  213. if (%mnick4 == $me) { inc %m4 | goto next }
  214. if (%mnick4 != $me) { notice %mnick4 %advert4msg }
  215. inc %m4
  216. goto next
  217. }
  218.  
  219. dialog error {
  220. title "Time Interval Error"
  221. size 220 110 100 35
  222. option dbu
  223. icon Pictures\obiwan.ico, 0
  224. text "You have not specified a time interval", 1, 2 2 98 8, center
  225. text "Please enter a time and press On again", 2, 2 10 98 8, center
  226. button "Close", 3, 30 20 37 12, flat ok cancel
  227. }
Download code! Download code (.txt)

 Bekijk een voorbeeld van dit script!
 Stemmen
Niet ingelogd.

 Reacties
Post een reactie
Lees de reacties (3)
© 2002-2024 Sitemasters.be - Regels - Laadtijd: 0.056s