sopyanx

add hotspot

Sep 2nd, 2019
503
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. :local send [:parse [/system script get tg_sendMessage source]]
  2. :local param1 [:pick $params 0 [:find $params " "]]
  3. :local param2 [:pick $params ([:find $params " "]+1) [:len $params]]
  4. :local param3 [:pick [:pick $params ([:find $params " "]+1) [:len $params]] ([:find [:pick $params ([:find $params " "]+1) [:len $params]] " "]+1) [:len [:pick $params ([:find $params " "]+1) [:len $params]]]]
  5. :if ([:len [:find $param2 " "]]>0) do={
  6.     :set param2 [:pick [:pick $params ([:find $params " "]+1) [:len $params]] 0 [:find [:pick $params ([:find $params " "]+1) [:len $params]] " "]]
  7. } else={
  8.     :set param3 ""
  9. }
  10.  
  11. :put $params
  12. :put $param1
  13. :put $param2
  14. :put $param3
  15. :put $chatid
  16. :put $from
  17.  
  18. /ip hotspot user add name=$param1 password=$param2 profile=$param3
  19. $send chat=$chatid text=("Username: $param2 Password: $param3 profile : $param3 Berhasil dibuat...") mode="Markdown"
RAW Paste Data