| OS X - Apps and Games Discussion of applications and games available for Mac OS X. |
| Post Reply | New Thread | Subscribe |
|
|
Thread Tools |
|
Guest
Posts: n/a
|
I own Diablo II: Lord of Destruction, but I hate having to supply the cd to load the game. I downloaded a no cd crack, but I find impractical having to open the .dmg file in my dekstop each time. Is is possible to write an Applescript that will sit in my dock with the Diablo II icon image, and open mount the .dmg (from another location, say Documents) and load the game?
Thanks in advanced! |
| QUOTE Thanks | |
![]() Member Since: Jan 12, 2005
Location: /home/sheffield/UK
Posts: 1,278
![]() Mac Specs: 12" 1Ghz PB 768Mb 10.4.5 30Gb Video iPod 40Gb 3G iPod 1Gb iPod Shuffle
|
![]() Apple, think different |
| QUOTE Thanks | |
![]() Member Since: Mar 09, 2004
Location: Munich
Posts: 9,075
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Mac Specs: Aluminium Macbook 2.4 Ghz 4GB RAM, SSD 24" Samsung Display, iPhone 4, iPad 2
|
|
| QUOTE Thanks | |
|
Guest
Posts: n/a
|
Ok, after some hours of research and lots of attention I sucesfully created this Applescript:
tell application "Finder" open {file "Macintosh:Applications iablo II Folder:nocd.dmg"}tell application "Diablo II (Carbon)" open end tell end tell Woohoo.. that was my first applescript ever. What I did was place the nocd.dmg inside the Diablo II folder, so it's well hidden in there. Then I just coded all that. But I still want to do a couple of things. 1. Set the nocd.dmg window to minimize upon being uponed. 2. Set a time lag between both actions, because Diablo II loads faster than the dmg mounts, so I have to click on the Diablo II window for it to load. But it works nonetheless. Any ideas how to do any of these? |
| QUOTE Thanks | |
![]() Member Since: Mar 23, 2009
Posts: 1
![]() |
Code:
tell application "Finder" open file "Macintosh:Applications:Diablo II Folder:nocd.dmg" repeat while (disk "<put in name of mounted disk image>" exists) = false delay 0.4 end repeat delay 0.5 close front window tell application "Diablo II (Carbon)" to activate end tell |
| QUOTE Thanks | |
| Post Reply | New Thread | Subscribe |
| Thread Tools | |
|
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
|
|
|
|
|||||||
Thread |
Thread Starter |
Forum |
Replies |
Last Post |
| Program hang on game launch | Popejewish | OS X - Apps and Games | 1 | 01-28-2009 04:21 PM |
| Addictive Flash Game | iWhat | Schweb's Lounge | 15 | 11-11-2005 01:50 PM |
| [ANN] New comprehensive AppleScript book | hanaan | OS X - Development and Darwin | 0 | 11-06-2004 07:28 PM |
All times are GMT -4. The time now is 01:10 AM.
Powered by vBulletin