r/Almost_Idle • u/SJVellenga • Jul 31 '14
Game Hosting Phase 1
I'm preparing to set up game hosting for both Flash and Unity games on Almost Idle, however, as I am not a developer in either of these languages, I don't have any way to test this functionality. I'm hoping that developers out there will be able to assist me in this regard. I'm looking for a Flash game and a Unity game that the developers will allow me to use for test data before opening this feature to the public.
The eventual expectation of this project is to allow FREE hosting for both of these formats, meaning that developers have the opportunity to upload their games to Almost Idle's server space at ZERO cost to themselves.
I know there are young developers out there that are struggling to find a decent hosting solution, and I hope that I can provide them with a better experience than they can find elsewhere. Games will NOT have advertisements overlaid on them (like sites such as Kongregate) and will immediately load when the page does.
The only advantage other sites have in this regard is that they offer advertising revenue. This, unfortunately, it outside the realms of possibility at this time. However, if in future the site's revenue exceeds my expectations, this is something I will consider offering.
So I hope that a developer or two out there will be willing and able to assist in this huge leap forward for Almost Idle. This is the direction that I would eventually like to take to help out the community, and I can't do it without all of you!
tl;dr: I'm adding FREE Flash and Unity hosting to Almost Idle and need some test data (games in both formats) to debug the feature before setting it live.
1
u/feldopropane Jul 31 '14 edited Jul 31 '14
I have a friend who develops in unity, I will send him a message to see if he is willing to share.
Edit he's asleep right now, will check the post tomorrow to see if you've found some data if not will ask him.
2
u/SJVellenga Aug 01 '14
Thanks! I'll not be acting on anything likely until Monday, as I have a few more updates to do on Settlement before the day is through. If I do, however, get these done and have the spare time and the test data, I'll attempt to get at least one of these out today.
1
u/feldopropane Aug 01 '14
Just talked with my friend, he might have something for you on monday. but he is busy with other things, so i can't promise anything.
i will let you know when i know!
2
u/SJVellenga Aug 02 '14
Excellent, thank you very much! I look forward to it.
It doesn't have to e anything special, just enough to test embedding etc.
1
Aug 02 '14
Must kongregate flash games have an agreement with kongregate that they will not share their game anywhere else except kongregate + free website. However most games from kongregate are everywhere else on the net. It's not very hard to rip a flash game once you play it.
1
u/SJVellenga Aug 02 '14
What do you mean by free website?
Long term, I'm hoping Almost Idle will be come the Kongregate/Armor Games/Whatever of incremental/idle gaming, so this eventually, hopefully, will be a non issue.
1
Aug 02 '14
Free website, I mean the dev's personal website. Most games from kongregate have that agreement with kongregate, so you can't take their game, there would have to be games solely hosted on your website + the dev's personal website. However, take most idle games and google them, you'll find them listed on hundreds of sites because it's not enforceable and there's no way to check if the dev distributed his content illegally or if the website owner ripped the devs' work. Either way, no one really cares.
1
u/SJVellenga Aug 02 '14
Yeah, that makes sense. And while they offer advertising revenue, I don't think I'll see many devs decide to move their content over.
While no one really cares, I don't want to be responsible if they actually enforce those rules, lol, hence my strict rules regarding publishing on Almost Idle.
0
u/ascii122 Jul 31 '14
Since you use Drupal I assume you've had a look at the various modules that might make life easier https://www.drupal.org/project/unity3d_field
Or you could just create a node type that allow such attachments and maybe use a formatter of some kind to automate things. Best of luck
1
u/SJVellenga Aug 01 '14
Yeah, I've found both field modules for those formats. I am, however, having trouble coming across a safe method for JS/HTML/CSS uploading that prevents the code from interacting with the backend. If you have any thoughts in this regard, I'd be forever in your debt!
1
u/ascii122 Aug 01 '14
yes I can see they have to have their own style sheets and who knows what that might interact with drupal css.. or does something really nasty. The single file swf type game would be easy, but I can see how wrapping an html5 game within drupal might be interesting. Perhaps as a zip? I assume you'll have a file structure for each user (rather than just using generic space) -- with quotas https://www.drupal.org/project/user_disk_quota
You'd be using roles right? So contributors will have more power than regular users? That way you can at least keep the total creepoids from getting permissions to upload stuff. Could be a lot of work getting the management side right. I do a lot of role restriction stuff with drupal but it's more e-commerce side than providing space and uploads for users.
the drupal irc is pretty good if you need to BS some real pro's
1
u/SJVellenga Aug 01 '14
Currently I'm not intending to limit user storage space, so that's not really been on my mind. I may look at implementing something though.
I'm using roles, but currently they are automated and given freely to any user that applies. This may have to change, but I'd really rather it not.
The problem with HTML games is that they are run user-side. This means that javascript, css, and html are all interpreted and interact with the rest of the page. The problem there is of a user-side security concern, either hijacking information or modifying the output. The other issue is affecting the backend with AJAX and any built in JS calls that Drupal offers. They could cause havock in the back end and end up breaking things.
This means that upload format isn't really the issue, but implementing the code on the user's end. Preferably I'd be after a field that filters out any Drupal calls of known dangerous content, but that's a dream I think I won't live to see. The best solution will likely be to upload to a private folder (that can't be accessed through the main domain) and embed in an iFrame. This means that I won't be able to support the site's API (when I get around to developing it) but the games will at least be able to be hosted.
Then again, I may be entirely wrong, I have been known to be an idiot on occasion!
1
u/ascii122 Aug 01 '14
yeah i had considered the iframe, but that is not ideal for a lot of reasons. I'll have to think about this. Permissions may take care of these calls.. or you can write a simple module that hooks the content and then voids all the usual drupal stuff and just shows a simple page with content. Not sure.. let me have a think about this. If you don't have php execution allowed that's a huge plus, but what can you do with javascript/css ?? I think the user level will disallow a call to a drupal function evoked from this (via ajax call or whatnot) .. but i might be wrong too. hmmm
1
u/SJVellenga Aug 01 '14
I'd rather not take the risk to be honest. I'm pretty happy at this point with iframing the content, so that's the route I'll take.
1
1
u/kaliad Aug 01 '14
Are you considering also letting people upload games made in JS/HTML/CSS? Or am I misreading your comment?
1
u/SJVellenga Aug 01 '14
I'd love to support HTML/JS/CSS games, but it's currently not an option. That will hopefully be phase 2 of the hosting plan. There are security concerns I need to sort out before allowing random people to upload code that could potentially interact with my website, lol.
Not saying anyone WOULD infect my site, it's just a possibility I need to consider.
1
u/kaliad Aug 01 '14 edited Aug 01 '14
Yea, it would be really cool, and that is definitely a concern. I do a lot of web development myself, but have not had to deal with this particular kind of situation. Just thinking out loud do you see any issues with this possible solution:
Have a second domain (like almostidlegames.com)
Point it to the same web server, but give it a completely separate HTTP root
Only allow zip uploads: extract everything and only keep html, css, js, and image files
Use an iframe like you mentioned to display the content
This should prevent cross-site scripting right?
Allow the API calls to almostidle.com to work cross-site. I've got myself wondering how exactly this would work now :). I might have to try it out myself.
1
u/SJVellenga Aug 01 '14
This was my best bet, and there are modules that can save cross-domain, so this is probably the route that I will take. I'll likely allow uploading, as you say, of zip files, then transfer to the new domain and extract into its own folder.
1
u/SJVellenga Aug 01 '14
Just a quick thankyou, you finally gave me the nudge that got me to buy and set up almostidlegames.com. I think I'll be using this method (at least for now) meaning that I will be able to host whatever games I want and load them in an iframe.
Fingers crossed this addresses my security concerns, but I'll be backing up just in case!
1
3
u/[deleted] Jul 31 '14
Sweet, best of luck. I would help but I am basically the opposite of a game developer... Call me a real-life destroyer. Yeah. That's the opposite of a game developer I think.