
Building a self-contained game in C# under 8 kilobytes - grujicd
https://medium.com/@MStrehovsky/building-a-self-contained-game-in-c-under-8-kilobytes-74c3cf60ea04
======
MStrehovsky
My tweet has the "friend" link that should avoid the Medium paywall (sorry):
[https://twitter.com/MStrehovsky/status/1213034748848807937](https://twitter.com/MStrehovsky/status/1213034748848807937)

------
thrownaway954
insane... absolutely insane and what a wonderful article. love it when the
author shows step by step how they get to their goal. You have really know all
aspects of the programming language and ecosystem in order to do what this
dude did. i'm impressed.

~~~
gregmac
Even with a lot of knowledge, I suspect a lot of this still took a lot of
trial-and-error. For example:

> Turns out that besides the obvious minimum that a managed developer would
> expect, there’s also a minimum that the CoreRT compiler needs to compile the
> input. > Let’s skip to the chase and add what’s needed:

There's under a hundred lines here, but figuring it out by (re)running the
compiler to get one error at a time would probably take a few hours.

If the author happens to read this: How long did it take to figure this all
out? And great job!

I'll definitely be referring back to this for some upcoming work I'm doing
where minimizing the footprint would be useful (not to this extreme of course
but there's some gems in here for sure).

~~~
MStrehovsky
I spent more time doing the Snake logic than adding the soup of weird things
around it to make it small.

I had the weird things lying around from when I did an EFI boot application in
C# last year:
[https://github.com/MichalStrehovsky/zerosharp/tree/master/ef...](https://github.com/MichalStrehovsky/zerosharp/tree/master/efi-
no-runtime)

I won't lie - being one of the architects of the CoreRT ahead of time compiler
helped too :)

------
svnpenn
Its not self contained...

[https://github.com/MichalStrehovsky/SeeSharpSnake/issues/1](https://github.com/MichalStrehovsky/SeeSharpSnake/issues/1)

