Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. We have updated the language to the Editor Terms based on feedback from our employees and community. Learn more.
    Dismiss Notice
  3. Join us on November 16th, 2023, between 1 pm and 9 pm CET for Ask the Experts Online on Discord and on Unity Discussions.
    Dismiss Notice

Creating a website to host my Unity games.

Discussion in 'General Discussion' started by smob, Dec 9, 2014.

Thread Status:
Not open for further replies.
  1. smob

    smob

    Joined:
    Sep 30, 2013
    Posts:
    8
    Hey All,

    I have created a few unity games now and I'm looking to build a website to get all of these games in one place. The issue is, I know very little about web development and I was wondering if someone here could point me in the right direction...

    What I am looking to create is a website, say mygames.com (or whatever), that someone could go to, login and be able to click on a tile to launch one of my games (web build). I have been looking into ASP.NET, but honestly I'm not sure if that is the best solution.

    I'm looking for simplicity, payment processing is something I probably won't worry about just yet, I just want a site where people could login and play my games. Any advice would be greatly appreciated.

    Thanks,

    Mike
     
  2. randomperson42

    randomperson42

    Joined:
    Jun 29, 2013
    Posts:
    974
    WordPress is pretty easy.
     
    GarBenjamin likes this.
  3. Seth-McCumber

    Seth-McCumber

    Joined:
    May 26, 2013
    Posts:
    141
    Don't go ASP.NET, not a good choice.
     
  4. smob

    smob

    Joined:
    Sep 30, 2013
    Posts:
    8
    Alright so I've seen WordPress before, not very familiar with it but from what I hear it isn't very hard to learn how to use. Does WordPress have the ability to have static HTML pages (like the web build that is produced from Unity)?
     
  5. GarBenjamin

    GarBenjamin

    Joined:
    Dec 26, 2013
    Posts:
    7,441
    You can set a static front page. The other pages can be made to look like they are static (meaning the url is not ending with a param like &p=47).

    If you install probably best to install in your root directory not the default which uses a "blog" subfolder. Been several years since I was into website development so I forgot about that when I set up my new site this past weekend using WordPress:
    http://www.GarsGames.com

    Not much there yet but shows you can make it basically however you want. I spent about 3 hours designing a custom WordPress theme, uploading, installing and then adding the pages and bit of content you see there now.

    If you click on a link it will show GarsGames.com/blog/PageYouVisited because I installed in that default blog directory. Not a huge deal but I'd prefer it to not be there. So keep that in mind when you install WP.
     
    Last edited: Dec 9, 2014
  6. Neoku

    Neoku

    Joined:
    Oct 27, 2014
    Posts:
    261
    You can use Ruby on Rails or any PHP framework as Yii, CakePHP, Codeigniter, etc, if need a more fast solution you can use Joomla.
     
  7. randomperson42

    randomperson42

    Joined:
    Jun 29, 2013
    Posts:
    974
    Yes, for all intents and purposes you can make static web pages with WordPress.
     
  8. Aazadan

    Aazadan

    Joined:
    Jun 21, 2014
    Posts:
    14
    I have a website where I host my current projects as a portfolio. A basic setup is really easy to create. With the web build you'll get two files, an html page and the Unity build. All you need is FTP access upload both of these files to their proper directories (the html file into your project directory, the Unity file to wherever you want to store it). If it's in a different directory you just need to change the file path in your html file. For example in the HTML file of my most recent project it's line 59
    Code (csharp):
    1. u.initPlugin(jQuery("#unityPlayer")[0], "yeswecan.unity3d");
    The end part just needs to be adjusted to the correct file path if it's not in the same directory and to get to the game you just link to the html page.

    You can create a pretty simple login system with a MYSQL database of logins/passwords (and add some new columns for paying accounts later if you want) and use PHP to build the login. I haven't read over everything in this page but it looks like it covers what you're trying to do there. Basically you create an account creation page, a login page, and a header on each webpage so that can only be accessed if the login session is valid.

    Beyond that it's just HTML/CSS work, using the pregenerated html file for the webbuild the body (the part you see in an html document) begins at about line 119. As others said Wordpress could do that for you if it's not something you're comfortable with but websites like w3schools give pretty good tutorials as to what to do. If you want to minimize the number of pages to maintain (an external style sheet can only do so much, you still need to format each page... which becomes exponentially more work as you add pages if you change the layout) one route to go would be to load your webplayer through AJAX which lets you load the contents of one webpage into another without refreshing the page. Doing that you could have empty pages with just your Unity player that load into a single webpage that contains all of your navigation.

    There's a bunch of other methods too, this is just the first that jumps to mind from someone that doesn't use WordPress or similar sites and someone who can publish to a web build but isn't overwhelmingly familiar with the mechanics of the Unity webplayer. (Not that WordPress is bad, it's very useful for companies that don't want to retain a coder for website management... I just prefer to get my hands dirty on personal stuff)
     
  9. Meltdown

    Meltdown

    Joined:
    Oct 13, 2010
    Posts:
    5,796
    Why rebuild the wheel??

    Rather submit your game to one of the thousands of online gaming websites that already have an API for what you want to do, and of course most importantly, traffic.

    People aren't going to find your site, there are tons of established sites in the search results.

    People aren't going to magically come to your site and play your games after you build it, without a huge marketing spend, which would most likely make your UA costs much higher than your ARPPU.
     
  10. smob

    smob

    Joined:
    Sep 30, 2013
    Posts:
    8
    Could you provide some examples of sites that offer this?
     
  11. Meltdown

    Meltdown

    Joined:
    Oct 13, 2010
    Posts:
    5,796
    Miniclip
    Kongregate
    Chrome Web Store..

    Or just type in games or browser games in Google
     
    dogzerx2 likes this.
  12. Dustin-Horne

    Dustin-Horne

    Joined:
    Apr 4, 2013
    Posts:
    4,568
    There's absolutely nothing wrong with ASP .NET and comments like this that don't provide substance are not helpful. I personally do all of my development and hosting using ASP .NET (primarily MVC).

    That being said, a *nix server is probably going to be a cheaper option for you. You could spin one up through GoDaddy or some other host provider pretty cheaply. A Windows server will cost you a bit more. However, what are your strengths? I choose IIS hosting solutions and .NET because I'm a .NET developer. I can customize, support, do whatever I need with it. If you have no development experience at all and want something that will be an effective content manager for you, then you might look at WordPress as suggested before.

    Also, think about what you want in the future. If you want to add payment processing in the future and need to heavily control and customize that then WordPress might not be the best solution for you. However, it's easy to setup and get going so it may be the ideal solution for now and you can transition to something else later.

    One thing I could caution you to do... if you use WordPress make sure you use a plugin that will translate everything to SEF URL's (SEF = Search Engine Friendly). That way if you build a custom solution later you can easily utilize the same URL structure or setup some rewrite rules for them. This will be especially important if you build backlinks and search results into your site.

    So I've probably not really answered your question but I really didn't mean to. I wanted to present you with options and have you start thinking about the considerations of what you'll choose. That's important... you need to pick what's right for the end result you're after.
     
  13. Meltdown

    Meltdown

    Joined:
    Oct 13, 2010
    Posts:
    5,796
    Not a good choice for what? And why do you say that?
     
  14. smob

    smob

    Joined:
    Sep 30, 2013
    Posts:
    8
    Thanks everyone for the replies, I think I've got plenty of information now to get started... I've got some thinking to do.

    You've all been a great help.

    Thanks,

    Mike
     
  15. GoesTo11

    GoesTo11

    Joined:
    Jul 22, 2014
    Posts:
    604
    I've been thinking about learning some ASP .NET for web development mostly because of C#. Is learning C# for Unity a good head start for ASP .NET? Where would you recommend starting? I have access to Microsoft Azure services for the next 3 years so the extra cost of a server isn't an issue for now.
     
  16. Dustin-Horne

    Dustin-Horne

    Joined:
    Apr 4, 2013
    Posts:
    4,568
    Well yes, for learning c#. Depends on how deep you want to go. ASP.net is a lot like unity. It's and API/framework/engine that you code against. You'll definitely want to understand some of the underpinnings of http and definitely want to learn about good web security practices. Once you get comfortable with it, you'll want to concentrate on learning good development patterns and methodologies.

    I would recommend starting with mvc as it naturally makes it easier to practice better separation of concerns and makes things inherently more testable which gets even easier when you start learning good dependency injection strategies.
     
  17. GrapeApeGodzilla

    GrapeApeGodzilla

    Joined:
    Mar 20, 2015
    Posts:
    14

    Thanks man. Was thinking on the line of creating a website as well to host my unity games, but what you said makes sense. Looking to create a google developer account and a yahoo one as well. Wanted to go mobile, but I am running into issues with Android SDK and really can't understand deploying my game to the apple store. So, I am going web until I can get the Android to work and I get help with understanding deploying on the iTunes app store.
     
  18. shanduke

    shanduke

    Joined:
    Aug 2, 2016
    Posts:
    1
    Is this page still alive? Anything new under the sun?
     
  19. I_Am_DreReid

    I_Am_DreReid

    Joined:
    Dec 13, 2015
    Posts:
    361
    A yahoo account???
     
  20. imaginaryhuman

    imaginaryhuman

    Joined:
    Mar 21, 2010
    Posts:
    5,834
    I think based "I know very little about web development" as given by the OP, I would say ANY programming-language-based option is really WAY over their head. Having to learn asp or php or ruby? I mean... that's quite a learning curve. If you're new to websites and maybe can't even write html on your own, I would suggest finding a hosted site solution where they give you editable templates/templating and a nice back-end admin area for content management and stuff.... I mean you could do this with wordpress but its really a blogging platform that people try to mangle into something more. I use Shopify.com which is a really nice modern, easy to use, easy to learn, well documented hosted platform with server-side templating IF you need it... and many pre-built (and many free) templates that you could tweak. You can get a 'dormant' plan with no shopping cart for $10 a month or so and then upgrade to $29/mo shopping cart option later when you're ready. Its a total ecommerce solution and has apps/plugins and stuff for like digital downloads and all that. Of course there are others, this might not be the best fit, but I like it a lot. And avoid having to learn to program right off the bad, that's really way too advanced for someone who is just starting out.
     
  21. N1warhead

    N1warhead

    Joined:
    Mar 12, 2014
    Posts:
    3,884
    It's a year and 3 months old sense last active. Learn to start paying attention Mr. Necro.
     
    Ryiah, Martin_H and Dustin-Horne like this.
  22. Ryiah

    Ryiah

    Joined:
    Oct 11, 2012
    Posts:
    20,150
    Almost one year and eight months since the OP even logged into this site.
     
  23. N1warhead

    N1warhead

    Joined:
    Mar 12, 2014
    Posts:
    3,884
    Must have given up haha. (Mommy, making games is willy willy hard) lol.
     
  24. GoesTo11

    GoesTo11

    Joined:
    Jul 22, 2014
    Posts:
    604
    Or he is busy making games instead of visiting forums. :D
     
Thread Status:
Not open for further replies.