Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 13 Next capture
2021 2022 2023
1 capture
13 Jun 22 - 13 Jun 22
sparklines
Close Help
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
avatar image
0
Question by tomekkie2 · Jun 17, 2014 at 07:03 AM · webplayerplayerprefsurl

PlayerPrefs when moving the webplayer

The PlayerPrefs settings are associated with the webplayer url.

Suppose I were going to move the webplayer to another url.

If I move - is there a way to access old PlayerPrefs settings by webplayer located on new url?

Comment
Add comment
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

1 Reply

· Add your reply
  • Sort: 
avatar image
1
Best Answer

Answer by HarshadK · Jun 17, 2014 at 07:48 AM

I'm afraid not!

Because Unity stores PlayerPrefs with URL for the same reason the browser stores cookies as domain specific. And that reason is Security.

There is no in-built feature provided in Unity to support your need as it may compromise the security. So you are left with only one option which is to find a loophole and exploit it to employ a hack which may or might not work in all scenarios and will only be usable till Unity does not patch it. AFAIK, there is no currently known hack for what you are looking for. So you have no luck with Unity's PlayerPrefs.

To solve the issue of carrying forward player preferences, one way would be to store the player preferences in a database on a server by yourself. Then you can easily migrate that database to your new domain which will allow you to keep all previous player preferences. But for this you need to handles the storing and retrieving of player preferences by yourself. And you also need to introduce an update of existing version of game which will take current player preferences from the system of user and store them in your database.

Comment
Add comment · Show 4 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image meat5000 ♦ · Jun 17, 2014 at 09:52 AM 0
Share

$$anonymous$$arma Bug

You are totally right. I've tried deselecting the answer. No loss to you. Reselecting, no gain.

Upvoting Questions seems to also be broken, $$anonymous$$arma-wise.

@tomekkie2 You lost 2 $$anonymous$$arma when I tested the button here. (Over) compensated you in another thread.

avatar image HarshadK · Jun 17, 2014 at 09:59 AM 1
Share

I guess I can safely say, this recent maintenance is now costing users. Now how am I gonna pay my bills? ;-)

avatar image tomekkie2 · Jun 17, 2014 at 10:16 AM 0
Share

thanks, @meat5000.

avatar image tomekkie2 · Jun 17, 2014 at 10:25 AM 0
Share

When storing the playerprefs on server database, you have to do it together with device identifiers like obtained from SystemInfo.deviceUniqueIdentifier.

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this Question

Answers Answers and Comments

21 People are following this question.

avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image

Related Questions

Copy/Paste from WebPlayer or save as cookie 1 Answer

Updating txt from an url (webplayer) 0 Answers

PlayerPrefs - Error in webplayer 1 Answer

Load image from url in Webplayer 1 Answer

How many variables can I store using PlayerPrefs 1 Answer


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges