Welcome, Guest. Please login or register.

Login with username, password and session length

 
Advanced search

1411505 Posts in 69374 Topics- by 58429 Members - Latest Member: Alternalo

April 25, 2024, 07:20:50 PM

Need hosting? Check out Digital Ocean
(more details in this thread)
TIGSource ForumsCommunityDevLogsVOS
Pages: [1] 2
Print
Author Topic: VOS  (Read 5349 times)
hexdie
Level 1
*



View Profile WWW
VOS
« on: March 05, 2017, 10:14:02 PM »

What is this?

I'm building a game which requires the player to interact with a virtual OS. At the moment, the goal of the game is to be a computer which belonged to someone and you explore it, as well as solve puzzles, to learn more about this person. I only have rough ideas of the story at this point. I started building this over the weekend and I plan to continue working on it.

Here's where the app is now (sorry it's not pretty):


The game is built with web technologies. The game has a client side, for UI, and a local server for rendering templates and handling system operations (like reading/writing files). The game is built this way for two reasons:

1) I wanted to leverage HTML and CSS for building a suitable UI.
2) I'm considering adding some sort of scripting system to the game, and I could leverage javascript easily for that purpose in this environment.
3) I'm a web developer by trade, so I know this stuff pretty well.


Progress so far

I've been able to run this game through my browser as well as a standalone application (using NW.js).

So far, I've done a good amount of setup work, built out the super rudimentary OS interface (background + taskbar), and worked out building the windows (this is where the majority of coding has gone so far). Each window holds an iframe, like this:


The source of the iframe contains a url to a html page on the local server. This means, the windows can load any arbitrary html code I give it, each of which will act as an application in the OS. The file at /static/apps/test-app/index.html looks like this:


I'm planning on some of these applications to be mini-games, probably built with phaser.js. Others will probably be more mundane, but important apps. I haven't quite planned it all out yet. One other aspect of these windows that I got working is the ability to independently move and resize these windows. This is from an earlier build, but I can confirm the recent versions are able to do this too.

« Last Edit: March 25, 2017, 02:07:37 PM by hexdie » Logged

rj
Level 10
*****


bad, yells


View Profile WWW
« Reply #1 on: March 06, 2017, 12:21:52 AM »

yes good
Logged

hexdie
Level 1
*



View Profile WWW
« Reply #2 on: March 06, 2017, 08:09:31 AM »

yes good

Thanks! Glad you dig it!  Grin
Logged

tpelham42
Level 0
**


Mercury Fallen


View Profile WWW
« Reply #3 on: March 06, 2017, 11:17:34 AM »

I can see some fun ideas coming out of this. Curious to see what the story/game play will be, but puzzle games are definitely something I enjoy. Smiley
Logged

Current Project: http://www.mercuryfallen.com
Find me on twitter: @tpelham42
hexdie
Level 1
*



View Profile WWW
« Reply #4 on: March 06, 2017, 12:14:58 PM »

I can see some fun ideas coming out of this. Curious to see what the story/game play will be, but puzzle games are definitely something I enjoy. Smiley

Thanks! Smiley I'll definitely share the story details once they become more concrete. The gameplay itself is pretty open at this point, but the idea now is that there will be a number of available apps and files available in the OS for players to search through and interact with, and those things will either contain puzzle clues, "keys" (like passwords), or generate a file that can be used to progress.
Logged

hexdie
Level 1
*



View Profile WWW
« Reply #5 on: March 06, 2017, 08:55:02 PM »

As a test, I loaded two of my old games into the OS (this game) and started them as applications. I'm able to play each of the games and they run simultaneously, and their windows are still movable.

I added options for the frame for setting the dimensions and whether or not the window can be resized. I also added the feature for the most recently clicked frame will be moved above all other frames.



Logged

hexdie
Level 1
*



View Profile WWW
« Reply #6 on: March 06, 2017, 11:41:47 PM »

Another quick update: I added close buttons to the frames for users to quit applications.

Logged

hexdie
Level 1
*



View Profile WWW
« Reply #7 on: March 08, 2017, 08:26:27 AM »

Another small update: Last night I finished up adding a frame maximize button. Currently it's covering up the taskbar at the bottom but I do plan on fixing that when I focus more on the taskbar (currently it's just a placeholder).

Logged

Pineapple
Level 10
*****

~♪


View Profile WWW
« Reply #8 on: March 08, 2017, 12:37:37 PM »

can we use this to replace shoddy OSes like windows 10
Logged
hexdie
Level 1
*



View Profile WWW
« Reply #9 on: March 08, 2017, 01:26:25 PM »

can we use this to replace shoddy OSes like windows 10

As long as you don't need your OS for any practical applications, then yes, it most definitely can!*
*an operating system is required to run this game.
« Last Edit: March 08, 2017, 02:48:55 PM by hexdie » Logged

Pineapple
Level 10
*****

~♪


View Profile WWW
« Reply #10 on: March 08, 2017, 03:16:41 PM »

all I use my OS for is to look at cat videos and post to dumb internet forums
Logged
hexdie
Level 1
*



View Profile WWW
« Reply #11 on: March 08, 2017, 08:24:38 PM »

I'm not sure I'll be able to implement a web browser within the OS because of cross-origin policies. If there is a solution to it, I haven't been able to find it yet. HOWEVER I can throw in some cat videos in there for you.
Logged

Pineapple
Level 10
*****

~♪


View Profile WWW
« Reply #12 on: March 09, 2017, 01:44:34 AM »

I'm not sure I'll be able to implement a web browser within the OS because of cross-origin policies. If there is a solution to it, I haven't been able to find it yet. HOWEVER I can throw in some cat videos in there for you.

what about a BBS client
Logged
hexdie
Level 1
*



View Profile WWW
« Reply #13 on: March 09, 2017, 10:50:19 AM »

what about a BBS client

Perhaps. It's something I don't know much about but apparently there are some javascript libraries for supporting it. So, who knows! Shrug
Logged

MaxTexeira
Level 0
**



View Profile
« Reply #14 on: March 09, 2017, 10:54:48 AM »

Please add Blue Screen of Death  Hand Any Key Hand Any Key

I love the concept! congratz  Gomez
Logged

hexdie
Level 1
*



View Profile WWW
« Reply #15 on: March 09, 2017, 12:19:51 PM »

Please add Blue Screen of Death  Hand Any Key Hand Any Key

That's definitely doable! (It wouldn't be the first time I've done it either) Smiley
Logged

hexdie
Level 1
*



View Profile WWW
« Reply #16 on: March 10, 2017, 09:32:51 PM »

I've been working more on my implementation of the windows. I want to make sure they are very responsive. I think I've gotten to a point where I'm happy with how they react to my input. I still want to add resizing to every corner, as well as resizing from each side, but for now I might leave it and begin implementing a start menu and the taskbar.

I've also managed to add this site onto its own server, and is accessible here:

TRY IT OUT

It's still incredibly barebones, but I wanted to share it because there's a small surprise here. Try pressing enter a couple times after opening it. Well, hello there!
« Last Edit: March 10, 2017, 10:38:31 PM by hexdie » Logged

Pineapple
Level 10
*****

~♪


View Profile WWW
« Reply #17 on: March 11, 2017, 04:14:12 AM »

Logged
hexdie
Level 1
*



View Profile WWW
« Reply #18 on: March 11, 2017, 11:15:49 AM »

You wish this had nude Tayne!
« Last Edit: March 11, 2017, 11:24:53 AM by hexdie » Logged

hexdie
Level 1
*



View Profile WWW
« Reply #19 on: March 11, 2017, 11:31:46 AM »

Update time! I've started working on the OS object, which is really just responsible for spinning up and managing all of the apps (each of those windows). I implemented a method of launch apps by just name alone. With the given name, the code builds a url to an app config file and downloads it, then configures and launches the window.

Here's an example of one of those app config files:



Here it is in action:



You can see the built url in that last attempt to launch an app, which failed. It just looks for /filesys/apps/{appName}/app-config.json. Eventually I'll add some code to handle when an app fails. I'm currently just detecting the app failure and just logging.
Logged

Pages: [1] 2
Print
Jump to:  

Theme orange-lt created by panic