New To Mac-Forums?

Welcome to our community! Join the discussion today by registering your FREE account. If you have any problems with the registration process, please contact us!

Get your questions answered by community gurus Ľ Advice and insight from world-class Apple enthusiasts Ľ Exclusive access to members-only contests, giveaways and deals

Join today!

 
Start a Discussion
 

Mac-Forums Brief

Subscribe to Mac-Forums Brief to receive special offers from Mac-Forums partners and sponsors

Join the conversation RSS
OS X - Apps and Games Discussion of applications and games available for Mac OS X.

Applescript to load a game + no cd crack


Post Reply New Thread Subscribe

 
Thread Tools
fernando87
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
inflexion

 
inflexion's Avatar
 
Member Since: Jan 12, 2005
Location: /home/sheffield/UK
Posts: 1,278
inflexion will become famous soon enough
Mac Specs: 12" 1Ghz PB 768Mb 10.4.5 30Gb Video iPod 40Gb 3G iPod 1Gb iPod Shuffle

inflexion is offline
why not just have an alias in your dock to the .dmg then launch the game?



Apple, think different
QUOTE Thanks
Aptmunich

 
Aptmunich's Avatar
 
Member Since: Mar 09, 2004
Location: Munich
Posts: 9,075
Aptmunich has a brilliant futureAptmunich has a brilliant futureAptmunich has a brilliant futureAptmunich has a brilliant futureAptmunich has a brilliant futureAptmunich has a brilliant futureAptmunich has a brilliant futureAptmunich has a brilliant futureAptmunich has a brilliant futureAptmunich has a brilliant futureAptmunich has a brilliant future
Mac Specs: Aluminium Macbook 2.4 Ghz 4GB RAM, SSD 24" Samsung Display, iPhone 4, iPad 2

Aptmunich is offline
try doing it with automator!
QUOTE Thanks
fernando87
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:Applicationsiablo 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
MusashiAharon

 
Member Since: Mar 23, 2009
Posts: 1
MusashiAharon is on a distinguished road

MusashiAharon is offline
How about this?

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
Shash

 
Member Since: Apr 06, 2009
Posts: 2
Shash is on a distinguished road

Shash is offline
Hi. Can i ask where you got a certain crack from? i've been looking everywhere for one, and yes my cd is 100% legit.
QUOTE Thanks
Shash

 
Member Since: Apr 06, 2009
Posts: 2
Shash is on a distinguished road

Shash is offline
haha woops only just realised this thread is 3 years old...
QUOTE Thanks

Post Reply New Thread Subscribe


« Ads or ad space popping up in header of safari | What Files to Exclude in Time Machine? »
Thread Tools

Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off
Forum Jump

Similar Threads
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 07:12 AM.

Powered by vBulletin
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
X

Welcome to Mac-Forums.com

Create your username to jump into the discussion!

New members like you have made this community the ultimate source for your Mac since 2003!


(4 digit year)

Already a member?