OSX Desktop Icons And Shortcuts?

Ask for help with ScummVM problems

Moderator: ScummVM Team

thill2708
Posts: 1
Joined: Thu Jan 03, 2008 2:27 am

OSX Desktop Icons And Shortcuts?

Post by thill2708 »

Hey, I'm trying to create a shortcut to specific games (like I have on my linux laptop), which use the high resolution icons. For the life of me I can't figure out how to do this, and can't find it online. On linux, I just have a desktop launcher that runs ~/games/scummvm monkey1, and I have the icon set accordingly. Can you do this on OSX?

User avatar
clone2727
Retired
Posts: 1592
Joined: Fri Jun 09, 2006 8:23 pm
Location: NJ, USA

Post by clone2727 »

If you compile it, you can make an .icns file (which comes with the XCode tools). But, to come up with an icon that you can just see, here's a trick I usually do (not too sure if it's 100% perfect or proper, but it works):

Show the info of the icon you want to use, and also of ScummVM. Then, click on the icon that you want to use and press cmd+c. Finally, click on the ScummVM icon and press cmd+v.

I think this really is only temporary, and doesn't transfer to other systems when you copy it. Well, just my two (Lincoln) cents anyway :)

User avatar
criezy
ScummVM Developer
Posts: 698
Joined: Sat Sep 23, 2006 10:41 am
Location: West Sussex, UK

Post by criezy »

What you sugest is to change the application icon. I don't think this is what thill2708 wants. From what I understand he wants a shortcut to the ScummVM application that takes a command line argument to start a given game and he wants to set the icon of this shortcut. I don't think you can do that this way on a Mac (that's a shame as you can do it on Linux and Windows and it is imho a nice feature).

thill2708, here is the solution I propose:
1) Create a text file containing the following text:

Code: Select all

#!/bin/sh
/Applications/ScummVM/ScummVM.app/Contents/MacOS/scummvm monkey1 
This is a shell script. You might need to change the path to the ScummVM application depending where you have install it.

2) You need to tell the OS to open this file with the Terminal application (show the info of the file and in the Open with section select Terminal.app) and you can change the icon at the same occasion using the way described by clone.

The drawback of this method is that it will open a Terminal window when you start the game. If you want the window to be closed when you quit the game you will need to change the default window settings for the Terminal application (and this is more complicated than it should be).

Edit: and don't forget to change the permission of the shell script so that it can be executed.
Last edited by criezy on Fri Jan 04, 2008 8:52 am, edited 1 time in total.

User avatar
clone2727
Retired
Posts: 1592
Joined: Fri Jun 09, 2006 8:23 pm
Location: NJ, USA

Post by clone2727 »

Ah, he wanted an icon for the shell script. Oops :P

Thanks criezy.

einar
Posts: 2
Joined: Fri Jul 25, 2008 1:18 pm

Post by einar »

The "Open With" part is not required if you give the file a name ending with .command, i.e. "Monkey Island.command".

bobablob
Posts: 102
Joined: Thu May 25, 2006 9:05 pm

Post by bobablob »

The most seamless way to do this is with an Applescript. That way you don't need Terminal to launch every time you click on the icon.

Open Script Editor

Type the following:

do shell script "[path]/ScummVM.app/Contents/MacOS/scummvm monkey"


Save As [Name]. Change File Format to Application Bundle and Check Run Only.

If you want to use a High-Res Icon, just open up the bundle in Finder and replace the default icon with the one you want to use.

dr.zeissler
Posts: 24
Joined: Mon Jan 01, 2007 5:53 pm

Post by dr.zeissler »

bobablob wrote:The most seamless way to do this is with an Applescript. That way you don't need Terminal to launch every time you click on the icon.

Open Script Editor

Type the following:

do shell script "[path]/ScummVM.app/Contents/MacOS/scummvm monkey"


Save As [Name]. Change File Format to Application Bundle and Check Run Only.

If you want to use a High-Res Icon, just open up the bundle in Finder and replace the default icon with the one you want to use.
sorry, i don't understand this. can you explain it ?

i want to create a *.app wich includes all:
- scummvm
- the game
- the hiresicon

What has do be done to do that.

Thx
Doc

User avatar
Longcat
Posts: 986
Joined: Sat Sep 23, 2006 3:15 pm

Post by Longcat »

learning how to program?

why can't you just create a shortcut?

dr.zeissler
Posts: 24
Joined: Mon Jan 01, 2007 5:53 pm

Post by dr.zeissler »

a shortcut of what ?...scummvm ?

all games scumm can run have no binary and so it is nonsense to make a shortcut of folders or whatever. sure i can make a shortcut of "scummvm" but whatfor ?

i can always use scummvm and choose the game out of the added list, but i want to have only one icon per each game and start it directly by doublecklick without starting scumm and choosing out of the list.

Doc

User avatar
Longcat
Posts: 986
Joined: Sat Sep 23, 2006 3:15 pm

Post by Longcat »

if you add the games shortname (monkey island = monkey, Goblins 1 = gob1, etc.) like it say's in the above post, ScummVM will execute the game itself IF you have already added the game in.

therefore, no, you do not need to execute anything other then ScummVM itself. it knows where to find the games folder.

sorry, but you will have will have to be a bit more spesific about exactly what you need explained, because it's all up there.

dr.zeissler
Posts: 24
Joined: Mon Jan 01, 2007 5:53 pm

Post by dr.zeissler »

Jonatan wrote: if you add the games shortname (monkey island = monkey, Goblins 1 = gob1, etc.) like it say's in the above post, ScummVM will execute the game itself IF you have already added the game in.

therefore, no, you do not need to execute anything other then ScummVM itself. it knows where to find the games folder.

sorry, but you will have will have to be a bit more spesific about exactly what you need explained, because it's all up there.
Thank You Jonatan,

first of all I use a mac with os 10.5.5.

It is difficult to explain what I want, so I show you what I did with games running in DosBox.

Normally you start "dosbox", mount a folder for "C:" and start the game by typing it's binary. You can use a frontend where all your games are already listed und start them with doubleclick.

I use the tool "boxer" and if you read, what this does, you will know, what I want to do with games that use scummvm.

http://boxer.washboardabs.net/
(boxer packages!)


Thx
Doc

User avatar
Longcat
Posts: 986
Joined: Sat Sep 23, 2006 3:15 pm

Post by Longcat »

yes, well, I still don't see what your problem is...

just start Script Editor, put in the line like it says with the game shortname for whatever you want ScummVM to start and save it as an application bundle.

clem
Posts: 2185
Joined: Mon Oct 31, 2005 11:14 am

Post by clem »

I think he wants a frontend/tool which creates these shortcuts automatically from the games stored in the ScummVM config file.

User avatar
Longcat
Posts: 986
Joined: Sat Sep 23, 2006 3:15 pm

Post by Longcat »

well, I don't know of any such tool.

dr.zeissler
Posts: 24
Joined: Mon Jan 01, 2007 5:53 pm

Post by dr.zeissler »

Deleted for violating the forum rules

Post Reply