New games every week!
The Box - Part One Blog
17th October 2017


"Hello World" claims the title of the box.
-=-=-

The code in Main.cpp is 3 lines long, and if I'm honest, I could easily compress that into one single line, by removing the newlines around the brackets.

The code requests an Alert.
Alert is held in AGAW_Win.cpp, since it's a Windows specific alert box, and uses a string converter which is held in AGAWCore.cpp, to convert the std:string to a wchar... Because.. Well.. C and Strings!! Grrr!

All three .cpp files are working neatly together.

The compiler is called with an additional parameter that includes AGAW_Win
AGAW_Win then includes Windows.h, and AGAWCore
AGAWCore then includes iostream.

Hopefully I can continue in this manner, in that I can write target specific versions of the AGAW_"Target" files, and then mix them in with the AGAWCore using the compiler's CLI command.

I'm hoping that all the different c++ compilers will let me specify includes as I go!!
If not, I'll need to do a bit of rejigging in order to include the initial file, or maybe even do a little hand-tweaking to get it going properly.

Either way, day one is a success.
It doesn't DO much, but it is indeed a success!

It took AGES to remember how to do all of that, and I'm still not 100% sure I'm doing it right, but for now I've got an exe out of it, and that's good enough for me.

.exe Filesize Watch : 398Kb
It was 16Kb until I added the #include iostream which bulked it up a teensy wee bit!
Views 197, Upvotes 25  
2018 Framework
New games every week!
Site credits : Jayenkai put all his heart and soul into everything you can see on this site.
(c) Jayenkai 2023 and onwards, RSS feed 3

Blog - The Box - Part One - AGameAWeek