Posts

Showing posts from 2017

Ending the month of "geek"

So it has been a fairly busy month for me. I am writing this a little early as I expect to be busy with none tech stuff this week. The month of “geek” is nearly over. That is the month where I just investigated whatever I wanted. I think it was a response to have kept myself quite focused the past few months. In the last post I mentioned I would be setting up a few scripts to automate as much as possible in my day to day computer usage at home. This actually only took a couple of evenings and do I wish I had done it before. Certainly paying dividends. The other task I wanted to do was take a look at Rust. I love learning programming language and was slightly worried I might loose the project based focus I am trying to build. My limited knowledge of rust also indicated that it might actually be a good tool to use for coding projects. It seemed to be ticking all the boxes. I wrote my first medium article about it here . About a week ago I decided to not use it

Practice game 2 - called finished.

So I called practice game 2 finished. This was the space invader clone I was working on. I say called as it wasn't really finished. I had a few game enhancements to do and a reasonable amount of polish to add. I hadn't added support for game controllers, sound effects,  or building for the web. I did add an entity system, bitmap graphics, animations and improved the event system. Build times where pretty quick full rebuild less than a second. The need for graphics meant learning a little aseprite along with writing a script for packing together the results onto a sprite sheet. The animations where described in a text file. I would like to put all game constants in a text file and have them updated whenever the file is saved. There is a ton of other little improvements to be  had. While I could have hacked together a space invader clone very quickly, the goal of practice it to learn and improve. Hence some experimentation and trying to do things in a way  that could be r

Practice game 2

Practice game number two is going to be a space invaders clone. Again it is something I could produce in a short period of time as it is a well know problem. I am not taking this route as I want to experiment with ideas and add a little bit to the game "library" that is very slowly amassing. Library has quotes around it as the library and game code live in the same directory. They only differ inside my brain... I spent some time working on a entity component system. Yes an over kill for space invaders but I wanted to get back into the mindset of using one. |It was kind of fun coding that up. Having finally reached the point of needing some graphics I did a tour of applications that could create pixel art. Initially I though I could use Krita but it doesn't allow cut and pasting into the same layer. I want a cut and paste workflow for my 8 by 8  pixel art.  Krita is not really designed for this. Then I thought gimp but I didn't enjoy the UI. Some more searchi

The Linux Command Line

I am gradually reading "The Linux command line" by William Shotts. He has been kind enough to provide it as a free download from his site. It is also available from No Starch Press should you want a dead tree copy. Google is your friend for links :) I have been reading the free online version so am not sure on the differences. It is one of those areas that I have been guilty of never spending the time to learn, I would occasionally learn via osmosis to solve a particular task. So felt I had a reasonable grasp of bash. But there are a lot of holes in my knowledge and this book is gradually filling them. It is a good read and free, if you touch bash you should probably read it, that is unless you are an expert. Reading this book is motivated by wanting to create a comfortable and efficient environment to code in at home. The requirements for work and home are different. I am much more likely to change languages at home and I have much more control over what get aut

Pratice game finished.

Yesterday marked a nice point in 2017. I finished a small game. Well it is more a practice game meant to get me back into coding at home, rebuild my SDL experience and let me lay down a work flow that I am happy with. By any standards the game it terrible. I have written better implementations in Javascript in an evening. But that is not the point. I am happy because it is complete :) This game is not that relevant the other bits are. I feel at home coding with nvim and using the shell to "automate the boring stuff". I want to talk about the fledgling process I have in place to make dev at home nice as I am quite happy with it. But it has only been a month or so and the real test is whether I find myself continuing to use way of coding or whether I flip back to an IDE. On time will give that answer. So this post is a Yay coding at home seems to be in a good place at the moment. August is going to be a busy month family wise, plus it is the month I need to up my mile

Changing my editor to nvim

So I have been spending a bit of time with my tooling at the moment. Previously I was using visual studio code on Linux as my main editor and meson/ninja for building. For the small projects I do at home this set up works quite well. With the exception of rename refactoring I don't miss the features of a more full IDE. Again for small projects, I might change my mind if I was working on a million line C++ project at home. At home I drift from using a desktop PC to a, now aging, laptop and back again. It has no rhyme or reason to it. Using an editor like VS code on a laptop is slightly annoying and I have fairly big hands and those cursor keys are all scrunched together. I am not a fan of touch pads either for anything more than browsing. The natural progression here is to not use the cursors keys. To me that means a return to vim. I actually decided to use neovim because of the built in terminal integration. Of course, other than playing with it I have not used it in anger.

Fast iteration

It is fair to say I am pretty obsessed with fast iteration cycles at the moment. It was a motivating reason I relooked at coding in C. I found I enjoyed coding in C but sometimes miss the algorithms that exist in C++’s STL.  It really depends on the task. What I realise I had not thought about much is getting fast iteration speeds by leaving behind system levels languages. Using something like Java, Kotlin or  C#. All compile pretty quickly and I  get some superb tooling with them. Of course it means leaving behind memory efficient data structures.   For some projects this would be not a bad idea. I have had the urge to create a few small games and started to write one in C++. It only occurred to me tonight every time I do this I fail.  The only times I  have successfully release anything to the public I have been using  Java. Weird but true. I should also blog more :)

The month that was June 2017

And I am back. I have been bouncing around some what in where I put things in terms of longer form blog posts. So now I bounce back to one of my old blogs. So to update I am sort into programming in C at the moment. I have been working on a mini interpreter. Really it comes about from a curious thought. How much of a program can I write in C that a full rebuild takes at most 250 milliseconds. That is the duration it takes for a C++ hello world program, using std::iostream, to compile and link. At the moment the interpreter is really only at the features of a calculator and takes about 80 milliseconds to build. I know it is a pretty weird thing to do but curiosity got the better of me. This month I have also started to spend a reasonable of time practicing drawing. I discovered http://www.drawabox.com and have been doing some of the exercises there. So far my ability to draw a box has improved. If I am honest, at certain times, I find the grind of practicing a little boring.