Re: Project organisation advice needed
Re: Project organisation advice needed
- Subject: Re: Project organisation advice needed
- From: Jean-Daniel Dupas <email@hidden>
- Date: Wed, 14 May 2008 18:53:49 +0200
Le 14 mai 08 à 18:28, Rakesh Vidyadharan a écrit :
I am in the process of developing my first ObjC/Cocoa application (a
simple game). I would appreciate some advice on distributing the
game data files with the application. I am thinking of placing the
data files under a files/games directory in the package. I will
also need to allow players to save an in-progress state for
reloading later. For that I am thinking of a files/saved directory
in the package. A problem with software updates comes immediately
to mind if I place the saved games within the package.
Anyway, the first question is how to add a directory tree (files/
games/xxx) to my Xcode project? I see a Resources node in Xcode.
Is that where I would add my data files? If yes, how do I convince
Xcode to impose a directory structure. It looks like I cannot force
a particular directory structure (although I can live with that if
necessary). Also what would be path to reference these files from
my application?
The second question would be what would be the best place for saved
in-progress files? ~/Library/Caches/..., ~/Library/Application
Support/ come to mind. The only problem I have is that I will need
to port the game to iPhone/iPod Touch and since I have neither I
have no idea whether a similar directory structure is available on
those devices. I realise that this information might be under NDA
and hence non disclosable, but if it is not I would appreciate some
advice here as well.
Thanks
Rakesh
You should NEVER change the application bundle at runtime (that is
after distribution). It will break signature and it's may not work
when user does not have permission to modify the application.
All answers are in the documentation. See Resources and Bundle
Programming Guides.
http://developer.apple.com/documentation/Cocoa/Conceptual/LoadingResources/MOSXResources/chapter_2_section_1.html#/
/apple_ref/doc/uid/10000051i-CH3-SW1
And see also "Where to Put Application Files" in the File System
Overview.
http://developer.apple.com/documentation/MacOSX/Conceptual/BPFileSystem/Articles/WhereToPutFiles.html
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden