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
1
Question by SunnyChow · Feb 12, 2014 at 02:20 AM · serverconnectionreal time

real time connection: HTML <-> server <-> unity

i know it's quite crazy but this is what i want to make. I want users to use their mobile to visit a webpage, and use this webpage to control an unity application in real time. You can count it as some kind of exhibition so the amount of computers installed this unity application is limited. Do you have any ideas how to do it?

There is a way I figured out but i don't like it. I have to make the server as a web server. The html side sends/loads data with json. The unity side sends/loads data with WWW. I think it's slow and probably counted as DoS.

If you can make it to HTML <-> Unity, it will be even better.

Comment
Add comment · Show 2
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 Wobbegong · Feb 12, 2014 at 03:00 AM 2
Share

The way I'd do it is have the website communicate with a server application, and have the server application communicate with Unity by using the .net sockets. It's not the easiest solution, but it is stable, secure, and offers a very high level of control. HT$$anonymous$$L<->Unity would be quite insecure I would think.

avatar image SunnyChow · Feb 12, 2014 at 04:06 AM 0
Share

Did you write it from scratch? Is there tool or library for this?

1 Reply

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

Answer by SunnyChow · Nov 27, 2014 at 07:43 AM

I got the answer myself.

It's Node.js+socket.io+express.io for server and SocketIOClient for Unity. The client can use normal web browser to do real time interaction through WebSocket. The server can be set in a real server or the computer that runs the application.

That's all the keywords you need if you want to do this kind of application.

Comment
Add comment · Show 1 · 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 08031992 · Oct 15, 2016 at 03:27 AM -1
Share

Hey @SynnyChow, I know this questtion is verry old but i hope you can still see my comment here and give me some help.

As your answered, you found the solution for this question by using Node.js+socket.io+express.io for server and SocketIOClient for Unity, could you please give me some source code and the documents that could tell me how to do this?

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

How connect client to server when ip is private ? 2 Answers

Networking Issue: Cannot connect to server 1 Answer

Master / Client - When to close connection ? 1 Answer

Unity Network make Server and Connect 0 Answers

Server closing after hide VDS window 0 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