GabuEx / my-little-investigations

Source for the game executables for My Little Investigations, a MLP:FiM fan game.
MIT License
47 stars 10 forks source link

Bigger changes #37

Open MaddTheSane opened 9 years ago

MaddTheSane commented 9 years ago

Let's begin working on having a better OS X version…

GabuEx commented 9 years ago

Hey, sorry for taking so long to get to this - I was super busy when this first went up such that I couldn't have a look at it, and then it kind of fell off my radar. This does look pretty good - I just have a few questions and comments based on my look through it:

  1. If I'm reading the changes to localApplicationSupportDirectory, this changes things such that instead of using NSApplicationSupportDirectory, it uses the resources directory inside the .app? If so, that's awesome; that's pretty much exactly what I was thinking of doing (I was considering doing pretty much this, but then you did it before I dove into that) and was curious if that was the correct thing to do.
  2. I see that you've added an additional cases path in the user directory in addition to the global cases path. I'm wondering why that is - it was my intention to have all cases just be global, as it seems like there's no reason to have cases be per-user, and that could result in there being multiple copies of files several hundred MB in size, which seems suboptimal.
  3. Given that you've switched over to just use Info.plist for the version string retrieval (which makes perfect sense), I don't suppose you were able to test WriteNewVersion() in some way with this change? It seems like things should just work since it explicitly retrieves the current contents, replaces the version number, and then writes out the XML representation of the properties, but I'm just wary of that blowing away something in Info.plist. If not, don't worry about it, but I figured I'd ask.

That's about all that I can think of. Thanks so much for doing all this. :) It's really invaluable to get help from someone who knows OS X so much better than I do (which is to say, at all).

MaddTheSane commented 9 years ago

1: Yes. Also, many modern OS X games have their contents within the app bundle. 2: I decided to have cases moved to the user's directory because it's generally a bad practice to modify a bundle's contents, one reason is because someone might not have the right permissions to modify it. This won't be a problem with single-user set-ups, but would have issues if multiple users are set up. There is a folder at /Users/Shared which might be a better option. I'll look into using that instead. 3: I have not tested it, but I do know my NSDictionaries.

GabuEx commented 9 years ago

This all sounds good. Wasn't aware that modifying an .app's contents was considered bad practice, though after thinking about that I can see why. If there is a specific shared folder where cases could go, I'm all for that. I'd say this is pretty much ready to be merged once that's done. :)