fearofshorts
Member
Well, I was hoping that the system had been designed to deal with both of those scenarios. Could someone please explain what happens with the appdata folders when an app is updated and what happens with duplicates?
The developer who creates the PND decides on an unique ID. So if he chooses "test" or "foo" or "abc123" then there could be collisions; there are no checks for collisions (because how could there be? How does libpnd decide wich PND is the "righteous" owner of the appdata folder?)WizardStan said:You mean if someone creates "AwesomeGame" and then someone ELSE creates "AwesomeGame", can it handle them both?fearofshorts said:Oh yeah, quick question: will there be a unique identifier for each PND sold/downloaded at the appstore?
I'd hate to end up with duplicate appdata folders.
Or someone creates "AwesomeGame" as "AwesomeGame.pnd" and then updates it with "AwesomeGameV2.pnd" will they both use the same appdata directory?
dflemstr said:So you should choose a good ID if you want to avoid collisions. Maybe not "!K§$%JMRGTWEKRP&JK" but for common names append your username ("quakemod-dflemstr") and for uncommon names just leave it ("vladivostok")
todd said:dflemstr said:So you should choose a good ID if you want to avoid collisions. Maybe not "!K§$%JMRGTWEKRP&JK" but for common names append your username ("quakemod-dflemstr") and for uncommon names just leave it ("vladivostok")
I thought the java solution to namespaces was a reasonably elegant solution to this problem: e.g., com.domainname.packagename
I +1 this too. But you have to remember that most users don't have a company backing them or a home page, so I'd suggest that users have the option to use "se.dflemstr.mygame" or "org.dflemstr.mygame" etc even if they don't own that domain... (That's how I prefix my Java/Scala packages btw)BWoodson said:todd said:dflemstr said:So you should choose a good ID if you want to avoid collisions. Maybe not "!K§$%JMRGTWEKRP&JK" but for common names append your username ("quakemod-dflemstr") and for uncommon names just leave it ("vladivostok")
I thought the java solution to namespaces was a reasonably elegant solution to this problem: e.g., com.domainname.packagename
I think this is a good idea as well. It works well for Java (and the Cocoa Framework on OS X). I also think it would be important to set something like this up as the standard in the documentation before too many people start creating stuff for Pandora so it's learned (and hopefully followed) from the start.
A package is just a unique identifier with rules, in so far as they're strings. The Identifier code can exist exactly the same as it does now, and a "best practices" for how to create said identifiers can come up at any time without breaking anything.dflemstr said:I +1 this too. But you have to remember that most users don't have a company backing them or a home page, so I'd suggest that users have the option to use "se.dflemstr.mygame" or "org.dflemstr.mygame" etc even if they don't own that domain... (That's how I prefix my Java/Scala packages btw)
And the names will be unintuitive for the average Joes who want to find an apps "appdata" folder...
And what about collaborative projects? Don't want to have the username included in that case...
Anyways, make a poll about it! (in the dev corner)
dflemstr said:I +1 this too. But you have to remember that most users don't have a company backing them or a home page, so I'd suggest that users have the option to use "se.dflemstr.mygame" or "org.dflemstr.mygame" etc even if they don't own that domain... (That's how I prefix my Java/Scala packages btw)
And the names will be unintuitive for the average Joes who want to find an apps "appdata" folder...
And what about collaborative projects? Don't want to have the username included in that case...
Anyways, make a poll about it! (in the dev corner)
The reason I asked the fearofshorts to clarify is because the two questions are mutually exclusive problems that need to be solved differently. You can't solve both of them; either two PND files have the same identifier so you assume they are the same game and use the same appdata directory, or assume they are different games that have unfortunately used the same identifier and therefore get different appdata. I was pretty sure I knew which way you solved them, but I didn't want to pipe in with an answer unless I knew what he was actually asking for.skeezix said:AS to:
"You mean if someone creates "AwesomeGame" and then someone ELSE creates "AwesomeGame", can it handle them both?
Or someone creates "AwesomeGame" as "AwesomeGame.pnd" and then updates it with "AwesomeGameV2.pnd" will they both use the same appdata directory?
"
Yes, of course we thought about it; we're professionals here. Spare time sure, but we're not idiots