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
4
Question by luckruns0ut · Jun 28, 2013 at 04:30 PM · c#networkingphotondatabase

How can I create a database with a Photon Network Server?

I've been reading about Photon Networking in Unity recently and so far it appears to be a good package to use, but I was wondering whether a server-side database would be possible to create? I'd need a database to store account information such as a player's stats, money, anything that would be saved during login sessions. I heard that it is impossible to do such a thing with Photon but I remain unsure. Could anyone help with this? I've never handled a database before with any language, but I know how they work and it shouldn't be too hard to implement.

Thanks.

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
6
Best Answer

Answer by clunk47 · Jun 28, 2013 at 05:05 PM

You'd need to do some homework. I know in Unity, you can have a script communicate with a php script online in order to change values in an sql database. Check out Unity Serverside Highscores Tutorial for help learning this part. For that, I believe you need the Unity Wiki MD5 class. You would look at the WWW class to communicate with php scripts in this way. In order to run your standalone server with photon, you need to have a look at the Photon Server Reference. Hope this helps you get started.

Comment
Add comment · Show 6 · 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 luckruns0ut · Jun 28, 2013 at 05:13 PM 1
Share

How would I go about modifying that server to work with a database then?

avatar image clunk47 · Jun 28, 2013 at 05:42 PM 1
Share

Edited my answer to be a bit more detailed on where to look. Unity Wiki is having tech difficulties at the moment, but you can always look at the Photon Server Ref link for now.

avatar image AlucardJay · Jul 24, 2013 at 11:33 PM 1
Share

Heya Clunk47, I know the feeling. I was fed up with my accept rate being so low, especially with my answer being the only one on a question and not being accepted by the OP. But accepting your own answer doesn't give any karma (if it did, $$anonymous$$e would be double!), unless this is not true now with recent changes to the UA 'site. Let me finish going through your answers and accept the suitable ones for you.

=]

avatar image clunk47 · Jul 24, 2013 at 11:39 PM 1
Share

Ahh man I appreciate it!!! I wasn't really doing it just to get karma or bring up my accept rate, I was doing it to show others that there has been a resolution that works for this question. I wouldn't accept my own answer if I knew it was incorrect. But I DO greatly appreciate the help w/ my rate and karma! That's always a plus when people see my profile ;)

avatar image AlucardJay · Jul 24, 2013 at 11:43 PM 1
Share

No worries, going through them it is obvious you put a lot of time and effort (and code) in for the OP. Looks like I was too late for most of them, so am upvoting too. I find it amazing people upvote comments (and lolcatz and bloody memes on FB) but don't do it here for good answers. Havagood1

Show more comments

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

17 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

Related Questions

Switching weapons in PhotonNetwork 1 Answer

Photon Selfhost? 0 Answers

Unity3D Photon movement synchronization 0 Answers

Multiple Cars not working 1 Answer

Photon Authoritative Using MasterClient 2 Answers


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