Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- set a to display dialog "Choose action:" buttons {"Ping", "Install mods", "Cancel"}
- if button returned of a is "Ping" then
- set temp to display dialog "Choose what to ping" buttons {"MC server", "Google", "Cancel"} default button 1
- if button returned of temp is "MC server" then
- set server to display dialog "Insert server adress" default answer "nanajuu.dip.jp" buttons {"Ping", "Cancel"} default button 1
- set ping_result to (do shell script "ping -c 10 " & text returned of server & "|grep \"round-trip\"") as text
- display dialog ping_result buttons {"OK"}
- else
- set ping_result to (do shell script "ping -c 10 google.ru |grep \"round-trip\"") as text
- display dialog ping_result buttons {"OK"}
- end if
- else
- do shell script "cd ~
- mkdir mctemp
- cd mctemp
- jar xf ~/library/application\\ support/minecraft/bin/minecraft.jar
- cp -fR ~/mods ~/mctemp
- jar uf ~/library/application\\ support/minecraft/bin/minecraft.jar ./
- cd ~
- rm -rf ~/mods/*
- rm -rf ~/mctemp"
- say "success" using "Bells"
- display dialog "Success!" buttons {"OK"}
- end if
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement