The Role of a Single Variable in an Application Source Code

What is the role of a variable? In case you don’t know about software design, or basics of programming, let me show to you what kind of a term it actually is. Variable has a type which defines what values it can have. It can be a number, a single character or combination of multiple characters. A variable can also be part of an array that has several variables that are of the same type. Objects have properties and every implementation of an object has a variable as a value to its properties. But we are not going to object oriented programming or modeling…at least not yet.

Together with other variables in a program variables form a state of the program. If you think about thing in any retro game console emulator there are so called “saved states”. This means actually what it exactly is. In Super Mario you have variable, which says in which world you are, which stage you are, were you are positioned in the actual level and, for example, how many lives you have left. So all these variables form the state. You with me?

One thing I wondered for several years especially when I wasn’t too deeply involved in actual programming and I was still trying to get my thoughts gathered was “how can you save the entire game when you are saving your game in any modern game?”. Of course you aren’t saving a full copy of the whole game. You are only saving these values of all these variables. You are saving the state in which the application currently is. And basically, this means text. How much would a text file consisting of, maybe, some hundreds of lines of variables and their values take space? Yeah, you figured it out…it wouldn’t take a lot of space. Not at all.

What does take space if any commercial modern game would be considered? Graphics, 3D models, the recorded sound effects and all of the dialogue of the game. They all take a lot of space. Especially when you think about today’s high quality screens with 4K pixels and high quality sound coming out of the selected audio device. Of course what takes also power is all this processing. The processing of code is done by processor of your computer. Graphics are processed with GPU (Grpahics Processing Unit). Today there is a need to maximize the use of a powerful GPU to process the data as efficiently as possible. The processor then works with the GPU and also the hard disk. We have already witnessed fast data processing of SSDs. SSD is short from Solid State Drive. Earlier we had hard disks called HDD (“Hard Disk Drive”). If you are really into computers and building setups you probably know that HDDs are a lot cheaper than SSDs. I mean, of course, the monetary expense of a unit of space. It is a lot more expensive to get a 256 GB of SSD space than it is to get this same space in a HDD.

Right now we are deep in the workings of a personal computer. All these facts I have already covered took me years to get into. It took me involvement. And mostly, it took a lot of time. I started getting in this, very deeply and by studying, back in 2008. That was the year I started studying first electronics and after two years I moved on to study computer science in an University of Applied Sciences. After I graduated back in 2016 I was having a hard time finding a job. After two years of looking for a job I found one as a customer servant. I have worked my way from there and now I work as an IT support person. And all this started from trying to figure out how the saved game system works in my favorite computer or video game. I think the game I was thinking about was Fallout Vegas.

The question made think deeply. How was the game able to save all this information to a small saved game file? I got the answer but it sure wasn’t an easy peace of a cake. I didn’t succeed very well in courses that dealt with a computer’s memory usage or how is magnetism, a physical phenomenon, handling all this data on a hard disk. But little by little…I got the whole picture. I finally got to combine all this information together. All this started by playing games.

Today, I find that there are several areas that are really interesting to me. If you want to learn some knowledge very deeply, like how computers actually work, you will have to use your past knowledge and experiences to guide your thoughts through it all as a process. Writing something “open” to yourself so that you understand what your mind is dealing and handling is one big key for understanding complex and theoretical matters. And teaching someone or having a conversation about the fact is very useful many times.

I don’t know a lot about actual electronics or how the architecture of a full computer work. Well, I actually know something about it. That isn’t however enough for me to solve every problem. This is also where search engines or even a tool like ChatGPT would come in handy. Of course you can look up information from books or your notes and study some more. Just try to remember to take it piece by piece. There is an old saying. It goes something like this: “nobody is a master as you are born”.

SteamOS – An Alternative to Windows

For a long period of time Windows has dominated the scene of playing games with a PC. There is always an alternative and that is Linux. If you have played video games on your personal computer you have most likely stumbled on Steam. It is Valve’s, yes, the company that brought Half-Life to us, brilliant piece of software turned as a game shop application for buying and installing and also maintaining your library of PC games.

There are of course other ways to get your favorite games delivered to you. I have to mention Good Old Games or GOG.com. Some of you might still be buying physical copies of games. You know, those optical discs. They might be CDs, DVDs, Blu-rays or even 4K Ultra HD Blu-ray discs. That is if you even have some sort of an optical drive in your personal computer.

Windows was my choice when I bought my desktop computer almost two years ago. I thought that for the way I use my PC it would be perfect. I have to mention that if you don’t get Windows on the system you are buying you are going to have to pay a lot to get it. I just checked the price of just the operating system Windows 11 and it was 145 euros. That all is just for the operating system.

Linux on the other side is free. It is also open source. What this means is that anyone can participate in making Linux better. I find this kind of comparison between Linux and Windows to be very interesting. In my current job I have had the pleasure to work a bit with PowerShell. This is a deep topic and I am going to just scratch its surface a bit. But let’s say that Linux is open and Windows is closed for what it comes to modifying the code that lies beneath the surface of the operating system.

But what about SteamOS? I can tell you that it is a Linux based operating system. It is free. And it has Steam installed on it. But what is that? I can already hear you talking about how Windows games aren’t compatible with Linux? Well, actually, now they are. Do you know what is “wine”? Let me, again, explain this a bit  further.

Wine is a tool that basically let’s you run software applications that were meant to be launched and run on Windows on Linux. This involves a lot of fiddling with settings and probably some deeper understanding about how software is commonly run on any platform or operating system. But the main point is that it indeed is possible to work with a game or application this way.

Now, when I made my decision of what is going to be my personal computers operating system, I thought a bit how am I going to use the computer. I wanted a machine that could be able to produce some documents so having office tools was important. I also wanted to be able to program on it. This actually works fine in both Linux and Windows. I am also a hobbyist musician as you may recall so it was important that my DAW would work and also that all my VST instruments and effects would be available. And last but not least, as I had a powerful device already, I wanted to be able to play latest PC games on this computer.

What was my choice? It was Windows. If I would have had to install and buy my operating system separately this would have meant that I would have had to buy a Windows license for 145 euros. The alternative would have been to install some Linux distro. Since SteamOS is currently free why not download it? It supports all of the games right?

Valve has had some success as it has brought a working market place and also a place for your gaming library for you the gamer. If you think about also Steam Deck you can clearly understand what is going on right here. Steam Deck is a very good and practical handheld gaming device. And it supports also Steam. I have been using Steam since I got my PC and that was about two years ago.

But would I go and trade my current and working system to SteamOS? I have to say that I am not right now yet ready for it. I am too concerned that I won’t have an opportunity to use my computer to other matters that aren’t about playing games. But I can say it is tempting. I have thought about testing SteamOS and maybe I will install it on some older PC someday.

Could PS2 Classic be Possible?

You might remember the release of PlayStation Classic. It might have been a disappointment. At least that was what everyone thought like about it a year after its release. I am pointing to a fact that its price dropped from the original 120 euros to as low as 20 euros. That was the lowest price I ever saw it sold for. I bought it for 40 euros. There might be a debate about do you have the right to hack the device.

PlayStation Classic had 20 games with it. Those games were not the best ones and there’s not even a debate. These games could have been better. There could have been more games included. There could have been better game pads included. But even with its flaws the system ended up in my living room after all. It definitely was worth of its low price at least for me.

But would it be possible that there would be some day a gaming console called PS2 Classic? We can start to think about how many good games would there exist on the system. Or we can talk about the system requirements of this device. If one PS2 game takes about 4,7 GB of space, and if there were 20 games released with it, they would require a space of 94 GB. Maybe there should be at least about 120 GB of space on the hard drive.

We can also think about how powerful the system should be considering about processor and graphics processing. There is already an emulator that you can run on your PC called PCSX2. It doesn’t require so much from GPU and CPU of your PC. You can run it on a even an older computer today. A while ago this wasn’t possible. We should thank the progression of computer related technology for that.

If these technical issues were finally solved and there would be a system released we can come back to the first issue I mentioned. There would be a maximum number of games. What would the games be and would every game be available for it? This could be a limitation. There were many good games that were released for PS2. Would there be only like 10 games on the system? Would it be possible to hack the system? Would you have to do it to make it reasonable to even buy the thing? And finally – how much would the thing cost and would it be different than just running (illegally) your favorite PS2 emulator on your home PC? After all since the games are in DVD format you can play them, or rip them, directly simply putting the disc in the tray of your PC after getting your hands on the BIOS some way.

I have to mention that this text has barely scratched the surface of this matter. After all it’s not so much about what the fans or tech hobbyists think about. It is about if it’s reasonable to release a system like this. Is it profitable? And is it worth the effort? If you have some deeper hardware knowledge or experience in circuit design or electronics you might understand something more deeper in this matter. I am not a specialist and these are only some of my thoughts about this matter.