r/learnprogramming • u/SteFo587 • 21d ago
How would I go on about creating a website emulator?
I want to create a Windows xp or vista emulator which runs in a browser for my final school project which I need for my diploma. The windows version doesn't really matter. I'm planning on using an open-source emulator so I don't have to code a completely new one. I have a little problem though. I don't know shit about coding.
0
Upvotes
28
u/-goldenboi69- 21d ago
I think you misunderstood the assignment
19
u/Sweet-Atmos532 21d ago
ok so this is a massive scope jump for a "dont know shit about coding" starting point. a browser based windows xp emulator is basically a full virtualization layer plus a javascript x86 interpreter plus a gui framework plus networking shims. that is not a final year school project that is a multi year engineering effort look at pcjs or v86 those are the open source browser emulators people actually use. pcjs runs dos windows 95 etc in the browser and the codebase is huge. v86 is more linux focused but same idea. you do not fork those and skin them for a diploma in a semester if you cannot write a hello world yet pick something you can actually finish. build a windows xp *looking* desktop in react or vue. file explorer that opens fake folders. notepad that saves to localstorage. a fake command prompt that runs a handful of built in commands. that teaches you state management routing components api design and looks impressive in a demo.
2
u/SwiftQuest 21d ago
Agree with the other comment, and one more thing to check with your teacher: a real XP or Vista emulator means running Microsoft's actual OS, which you'd need a licence for and can't just host on a public site. Also ask whether "emulator" has to mean it runs real Windows, or whether a look-alike desktop is fine. If it's the second, start with plain HTML, CSS and JavaScript: one draggable window, then a start menu, then a couple of small apps like notepad. You'll learn way more that way and actually have something working by the deadline.
2
u/Aggressive_Ad_5454 21d ago
There’s a thing called WASM that lets us run native-code programs (C, C++, etc) in a web browser. People have used that to port old school games like Id Software’s Doom to run in a browser.
WASM tooling is a pain in the neck, but we can do cool stuff with it.
I suppose you could boot up an OS with it. But, it has to be said, the file system would be sketchy AF.
2
u/lovejo1 15d ago
I think your assignment is likely just to make a web page that looks like windows.. surely..
Doing what you're asking would be actually impossible. You can't emulate everything, zero way of doing that even through wasm.
1
u/betarage 21d ago
That is possible but very difficult i think its better to focus on a very early version of windows like 3.1 or even 1.0 instead .or emulate some other retro systems like the apple 2 but even that is really hard.
1
u/akoOfIxtall 21d ago
Dude, this is not easy, not in the slightest, even for experienced people, if you don't even know how to code a simple console app how do you intend on doing anything at all with a fork of a huge codebase? So many things that are simpler and look cool too, three.js gives you a 3D renderer in the browser and I think it accepts blender files, there's a lot you can do with that, if it doesn't have to be in the browser, C# can make desktop apps to do pretty much anything on your computer using it's UI frameworks (wpf, xamarin or avalonia), idk maybe even game mods are acceptable? Idk about that but if they are, just pick a game you like and mod it to your heart's content, it's really fun.
Browser stuff Is usually easier because a lot is handled by the browser itself, but an OS emulator is just too much, and if you fork an existing one, what you plan on doing with a feature complete software that will justify you doing that? It's like renting a car and saying it's yours because you slapped a sticker on it, there's better projects out there that you can do without much coding experience, look up book of shaders, it's pretty neat
1
u/BMW_Adam 21d ago
That would be impossible for you, as you dont have any experience. Either use ai, but it wont be your project or you could maybe run it inside a linux machice as a vm, then have x server or something stream the feed to the website, but that isnt that much simpler either.
1
u/JGhostThing 21d ago
Why do you want to create a web site emulator, which is far beyond your current capabilities? You could easily download a real web server and have it run on Windows.