Wednesday 24 October 2012

Sorry

I has been a long time since I updated this, I have been working flat out to release five games this November. Just to make things slightly harder i have decided to also learn flash programming as well.
I have included some example here just let you know how far I have come in one day.


Admittedly I have been following online tutorials, but the code makes sense even if the syntax doesn't. So back to it, folks.

Wednesday 26 September 2012

Always, learning.

I decided to take the plunge, I am awful with computer graphics, fine with a pencil and paper but never really got on with computer graphics, hence, pixelh8.

But I am trying out new graphic software to see what all the fuss was about and it is incredible I am only on day four of using it, I have been spending about an hour a day working through some internet tutorials and / or just picking random pictures from the net to vectorize, it is simple to use, but difficult to master but I really enjoy it.

There has been loads of, oo0O0o00oo that is how they did that moments and that is quite nice.

This little guy was found on the net, so I copied the style using skills I had learned over the last couple days.

This was a tutorial I found on the net, this is what I made from it.

This zombie was originally sketched out on paper and was then converted to vectors.
I don't profess to being a graphic artist by any stretch of the imagination, but using vector art software is great fun, so it is time to start saving my pennies for when the demo runs out!

Enjoy.

Monday 9 July 2012

Pushing Notifications, Pushing Myself

A lot of people know I make games, I do an awful lot of coding, but I don't do Internet stuff, I just don't until now. The mysterious, or maybe now so mysterious tweet. "Is this working?" via iOS on my timeline signifies this change, as I have just implemented the Twitter API in to "Cross Side" allowing people to tweet me for help and tweet their achievements in the new game due out shortly. It is like a 3D OCARBOT, but perhaps even more infuriating.

Now all I need to do is bring in Game Center and Facebook and we are ready to rock.

Friday 22 June 2012

He is his fathers son


My 10 year-old-son son came running out of school today, and very excitedly explained to me he had been learning Scratch at school. He explained on the bus ride home what he had been learning and what he would like to do, so as soon as we got in we loaded up Scratch and started a new program. He did say "but it is not real programming is it?" because we were using Scratch which I explained "no, it is real programming, it is visual programming" and he was happy with that, I think it maybe validated what he was doing, not that it needed it.

He knew how to make a Sprite move around the screen but not how to control it, so I simply took him through controlling the sprite using ifs and sensing blocks. Needless to say he was ecstatic, he knew from that moment on he could make a game. If he could control it, he could give the character a goal.

We also added a key which when you collect it, it dis-appears and re-appears randomly on the screen. We decided that we needed an obstacle so we decided that it needed a timer. So that is what we will do tomorrow, I am really pleased he has taken an interest in programming and really pleased I can be there to help him.

Thursday 21 June 2012

To AR or not to AR?


Here is the final video for a Augmented Reality (AR) project I have been working on with a local school, it was good fun, hard work for me having to build 4 game engines, but it was worth it.

I have been a bit ambivalent towards AR as I have often seen it as a imagination destroying prescribed narrative driven product placement entity, I didn't like it. I kept seeing toys that came to life and interacted with other toys in the "product range" to force children down a specific narrative, which usually lead to the purchase of more toys to continue.

When I was a lad I made up my own stories, a Stormtrooper was once a giant city destroyer, destroying the LEGO peoples towns, who then had to take refuge in the giant "Millenium Falcon" city. With several AR toys this type of scenario would be an "incompatible experience".

So AR, I didn't want to be a part of it, until, I learned I could use it so the children I was working with could create their own narratives/games/ interactions. They were now the creators of the story, using technology to tell it, instead of being told it. I like AR like this, well in all fairness I like all technology to be like this.

I am glad I did this project and tackled an area I didn't particularly like the idea of, as we have achieved some great results, now what should we do next?

Sunday 17 June 2012

Old Dogs, New Tricks


Everyone knows I am old school, I code old school even in Xcode I do everything programmatically and usually in one class, it works, it is just old school. However recently I have been playing with Scratch which is a visual object orientated programming language. One of the great things about Scratch is that you can get an object to simple detect if it is touching another colour, it saves loads of code for object collision. I have also been tinkering with loads of visual stuff like Augmented Reality, image and shape detection, so I have been analysing the content of pixels a lot recently. So I just thought why not code that in to a game engine of my own, I know people have been doing it for ages, but I am old school.

I would usually code a level like this"Old School" 2D array from "OCARBOT" Level 1.













However now it just looks like this. Instead of looking at the LEVELGRID it just analyses the colours of the pixels around the character. If it detects the color (Red: 66 Green: 0 Blue: 8, the slightly reddish black around the platforms) below the character, under the feet, it stops the character from falling. If it detects it to the left or right it prevents you from moving in that direction. It means I can move a character with better collision detect and a hell of a lot less code.

The example image above "OCARBOT Processing" with the new detection implemented, it plays the same just uses loads less code and is faster.

It also means I can do something awesome, very awesome, but that is for another time.

Like I said, "Old Dog, New Tricks"

Wednesday 13 June 2012

Been coding all day

I have been pretty much coding since I woke up this morning and I am very happy with the results. I have been coding the AR Games for the Springfield Junior Project. There are four games that use Augmented Reality, Mixed Reality or just the camera for recognition. This is the first game "Bunny Maze" the code and the graphics for the demo was by me, the graphics for the final and the design will be by the students. The code has been done for a while just been optimizing it a bit today.
The second is "Zombie Football" where zombies invade a pitch and you have to dispatch them with your football skills, we will put in the graphics tomorrow. The big white block is the footballer, the little rectangles that slowly get bigger as they move towards you are the zombies. There is a power bar to help you continuing scoring despite the zombie apocalypse, so lets set how many you can get with three lives, while the hordes chase towards you.
I have two more to do "Animal Rescue" and "Trap the Dead", but I am going to have a break now.

The Humble Bundle V

Just a quick blog about this and then back to work teaching kids (9-year-olds) how to make Augmented Reality games. This might seem strange me blogging about this, on a blog predominantly aimed at how purchasing an expensive Mac Book Pro effects my productivity, I decided to talk about a collection of games I have recently bought. I have to though, it is great.

I recently purchased the Humble Bundle V, I had seen previous bundles and been tempted in the past but this collection was just too good to pass up, I think the tipping point for me was the "Limbo" soundtrack, I already have "Limbo" on the XBOX 360 and hold it in the highest regard, it is an awesome, unsettling and beautiful game. There was also "Bastion" and "Braid" both games had been released to critical acclaim, I however hadn't gotten around to them yet, and now as a treat, I decided it was the right time. I had just done a major chunk of work on the Creative Computing Club and had some money to treat myself with $15 to be exact.

There are several other games in the bundle, but if I am honest I didn't know much about them, it is not to say they are no good, they are brilliant, I just hadn't heard of them. There is Psychonauts by Double Fine, I had just bought "Double Fine Happy Action Theatre" for my 3-year-old for the Kinect and it is easily the best "game" we have had on Kinect system, everyone in the family has been playing it, so we knew "Psychonauts" would be good. Super Brothers: Sword & Sorcery EP has this wonderful and bizarre animation and graphics style which make it unforgettable, and I love the way it is sectioned in chapters of play. "Braid" is outstanding, you have to play it and get infuriated with it to know what I mean, it is a challenge but well worth it, it is like a melancholy 2D Portal. I haven't played the others yet but judging by the quality of these, I will be very happy.

You can download the games in several ways directly or through "Bit Torrent", so I downloaded "Bit Torrent" and did it that way to take the strain off of the Humble servers, it was a little slow but it meant I could do my work online at the same time.

In the end I downloaded them all for PC, my Mac Book Pro is for game development and "work". But to my horror, my PC just wasn't up to playing "Limbo", it doesn't have the "shader" graphics card capability, (my PC makes music it is not really concerned with graphics), it is not the games fault, my PC is crap.

In the end I got them for the Mac as well, how good is that, not only can you buy all these games in a wonderful collection, you get them for PC and Mac (I think Linux too), and the soundtracks, I love game soundtracks, one day maybe somebody will ask me to make a game soundtrack, ok yeah I did "OCARBOT" and that was great, but one day hopefully I will do another.

So just to recap, you get excellent games, in the format you need, some of the soundtracks too, you can decided how the money you send gets shared between, the developers, the charities and the people who organise this wonderful thing.

So there, I was happy with what I had bought, and having them installed on my Mac was ok, so long as I just dipped in and out of games and didn't get too distracted and I am pretty good with that kind of discipline, and then it happened "Super Meat Boy" along with "Lone Survivor" was added to the bundle, I love "Super Meat Boy", I really do the fast and infuriatingly diffulct (for me) game play is a must experience. So the best games bundle I ever bought just got better.

This "system" putting great games together is wonderful and I strongly recommend this bundle of games, in a lot of cases they re-affirm just how thoughtful and introspective games can be. I came for the horrifying ambient "LIMBO" soundtrack and I stayed for the comic bloodshed of "Super Meat Boy", and I got to rewind it all and do it again with "BRAID". I got to see and discover a load of other very talented games developers and hear a lot of excellent music.

I sincerely hope the charities make a ton of money from this, I hope the game developers make a ton of money so they can make a living and make more wonderful games and I hope the organisers make a ton of money so they too can carry on the good work they do.

Well done to all involved.

Any questions, comments, abuse tweet me on twitter @pixelh8

Saturday 9 June 2012

You're great, but I am not convinced I love you

So I did get my son an Android 4.0 tablet for his tenth birthday (see previous blog), admittedly I was bit nervous as I hadn't seen it in the flesh, just reviews and videos online etc. So I was relieved when it turned out to be pretty good especially for the price, it surfs the net, he can play games, watch BBC iPlayer and even Skype. There are a few issues, and these might sound dreadful at first but they aren't that bad, we'll start with the worst.

The SD card slot wasn't aligned properly so I had to pop it open to retrieve a micro sd card that disappeared into nowhere, much to my sons horror, I had his new tablet in pieces on the second day. But is all sorted and works wonderfully, he can now put his homework stuff on a micro sd card and in to the tablet. I am quite used to popping things open for minor repairs, it was a simple matter of taking the back case off getting card out and putting it back together, only better.

The battery life isn't great 4-6 hours tops and it seems to go down even if it isn't being used.

A few games purchased from the Android Market don't work at all. How foolish of me to expect a marketplace dedicated to providing products for a specific type of device, would actually have software that works on those devices. These are paid for games by major games companies and they don't work, that is awful. This is why I don't make Android apps, because there are too many possibilities, too many opportunities to go wrong.

He however loves it, absolutely loves it, Angry Birds (all), Wheres My Water? Cut The Rope, Fruit Ninja, he can play on the websites he likes because it has flash, you can add a keyboard and mouse to do even more.

So yay, I am pleased with it although not totally in love with the device, I am too used to the iPad 2, with software you pay for to work, I am gutted that I can't use flash though.

Wednesday 30 May 2012

A dilemma, possibly.

I have recently set up a Creative Computing Club for the 12-16 year old age range and it is going great with some excellent results and feedback from both parents and students. There is however a dilemma , possibly, they are all boys. I know this is a common situation for computing in general, but my 7-11 groups are always 50/50 boys and girls and the situation on the Games Design degree is certainly improving. The thing is, I was actually taught to code by two women, and have worked with and met some amazing women in technology so I never see gender as an issue. I judge people on their output, not gender.

I really want to run an adult Creative Computing Club, I have received loads of emails asking for it, I am just concerned it may go the same way as the 12-16 group. I simply don't have time to run a fourth gender specific Creative Computing Club, so here is what I plan to do.

I will run one off day sessions for the adult Creative Computing Club, each session will be a self contained course. That way there is no long term commitment by the group once the session is over they can choose whether to return to the next one or not. If they don't feel they fit in or feel uncomfortable it is only for one day. I know, that sounds kind of terrible "don't worry if you feel uncomfortable, it is only for a day" but it is the only solution I can think of at this stage.

I really want Creative Computing Club to be as inclusive as possible, I want everybody coding and creating, and this is the only solution I could think of.

Any comments would be great.

Saturday 26 May 2012

Social Computing.

I posted a comment on Twitter today "My eldest boy is 10, it is about time he got a laptop and earned himself a living." partly in jest, I don't really expect him to earn a living but partly because I do want him to develop his computing skills (if he wants to). I have a big family two ten year old girls, the two boys one nine and the other three so they have to share the tech between them. Despite (me) his dad running all over the country and sometimes the world teaching computing and and technology, he (my nine year old) gets very little time to develop his skills, beyond that of quickly dipping into this or that website or game on the computer. My house is a home not a computer network.

I have never been a pushy dad, my career is my career, what ever they want to do with their lives is fine so long as they are happy and safe, so I have never really pushed them towards computing. I let them try stuff out but have never been pushy to the extent of teaching them everything I know about computers before breakfast. They could, be involved in all kinds of mad technology stuff, they know about it and get to hear about it usually at dinner, but one of them likes athletics and music, one likes all things creative, the boy likes archaeology and they youngest will be a rock star (I should know).

So why am I buying him a laptop if he just wants to dig up the past?

Firstly, well (this is ironic a parent saying this) "all of his friends have one". They use it to converse, play games online, and he misses out quite a bit socially because that is where a lot of the lads his age spend their time. I don't think it is particularly a bad thing at their age they want to be social but don't have the opportunities to be, or at least not on their own. School all day, home, fed, homework, bed and loop, not much time for socialising except for the weekend and that is often taken up by socialising with the family. He does not have a mobile phone of his own.

Secondly, he isn't that great with technology, he can use all the gadgets in the house but not to any great depth, we live in a very technology driven world. I don't think it would be a bad thing if he was more digitally literate, again, that is if he wants to be. At least this way he will have the tools to be.

Thirdly, he can do his homework on it, I know he can I checked with his teacher.

Fourthly, there are a lot of great things on iPlayer that he will miss as we only have the one TV in our house, and with the kids having such different tastes it will help him watch things that he is interested in. "The Man Who Discovered Egypt" was a prime example.

Fifthly, he is good at mathematics, and I mean really good, this the parent part kicking in, there are loads of cool practical things you can do with a computer and mathematics. Obviously.

Finally, if he ever wants to learn any of the things that I can teach him he will have the appropriate tools to do so.

I got a comment back about how he might withdraw socially (I am paraphrasing) because he has a laptop, which completely confused me. I don't see computers as solitary devices to sit at, for me they are all about interacting with other people who aren't physically near you, so what if they are a million miles away. All the activities I do with computers and technology are aimed at bringing people together, that is not in spite of technology but because we can with technology. My teaching of computers, done in a group, creative computer club is a group, my music tech work is a group. So yeah that completely confused me, it didn't annoy me or upset me, just confused me.

He also "might lock himself away" (paraphrasing again), good, I did that to plan my world domination and that worked out rather well. People need time away from others to develop their skills, to make mistakes without constantly being watched and scrutinized. I don't think he will become any less social or confident, take him anywhere and witness him join in the conversation or haggle for a better price or deal on something he wants to buy. (He will haggle with store managers, he is ten, he gets that from his mum).

So he is going to get a laptop,

It will however be severely locked down (sorry son), but it will be filtered, crippled, no P2P, no filesharing. He gets embarrassed when I preach about the damage files-sharing does to some independent artists (I don't care about the major companies they tend to produce mediocre crap anyway) especially in front of his mates. So yes it will be locked down, but ironically give him more freedom.

Maybe he'll write a blog about his machine?

Saturday 19 May 2012

OCARBOT EDU Update

So I have been working on the Game Britannia presentations, making them special and bigger and creating an entirely new talk about how I managed to make OCARBOT. The session is a behind the scenes look at making a video game and because I did everything for OCARBOT it is a first hand account. The session ends with the students trying out the new free OCARBOT EDU version for PC which only has fifteen of the fifty levels but it comes with a level editor. I am really pleased how it is turning out, it still has a few bugs, but keeping a few of them as talking points is important too.

Admittedly most of this work is being done on "HAL" the Windows desktop but the presentation which is being made alongside of it is on the MacBook Pro, that way I can flick between the two quickly. The preparation for the sessions has taken me from dawn to dusk to do but they are done and I look forward to running them at Games Britannia later in the year. It's 21:44 that's it for me for today.

Friday 18 May 2012

Augmented Reality Games

So I am now starting to do prototypes for the Springfield Junior Augmented Reality Games, I now have a 3D maze whose perspective changes with the AR Marker. I now have to map a cute bunny rabbit on to the red square and put some carrots around the maze. I have learned so much from this project is unbelievable, and no I couldn't have done this without my old crappy laptop.

Wednesday 16 May 2012

Augmented Reality Masks

So I am finally happy with the Augmented Reality Masks for tomorrows workshop, just as well really. I had the code working ages ago I just needed to draw some cool pixel art masks.

So we have a Lion, Robot, Vampire and a smiley face.




The Vampire. 
 Umm, I don't really have anything else to write except...
I'm happy about how they have turned out.








Tuesday 15 May 2012

Still Augmenting Everything

I should probably be asleep but I am having too much fun with AR at the moment and I need to test something out for the Springfield workshop on Thursday. The plan is for part of the lesson is to get the kids to try on an AR mask, by placing an AR marker on their forehead. I started by drawing the shapes but soon realised I could get better and quicker results by just adding a texture to a shape. I am quite pleased with the results.
I think that will be it for tonight though, I'll make some other masks tomorrow like zombie, a monkey and maybe another. It should be quite fun to see their reactions as they try on the different masks.

The best part about it is the image is textured on to a 3D object so as they turn at an angle so does the mask. So it gives real depth to the mask as you move around. Again this is something I could in no way do with my last laptop.

Saturday 12 May 2012

Augmenting Everything

Been so super busy with planning for the Creative Computing Club and the Springfield Junior Workshops I have enlisted the help of my son to try things out for me. Having the Mac has sped things up no end to create the downloadable resources for the club, I am able to switch between multiple bits of text and presentation software to get things done. I am also able to dip in and out of the work around the hectic week.
So although I haven't made anything new, I have made a lot of resources to make the things I do accessible.

Thursday 3 May 2012

No this is AR Reality, not our reality.

So today I will be teaching students how to design applications using Augmented Reality, a crazy idea I know, but I think they will cope with it rather well. I had never done any AR projects before and I have a policy that if I don't know how to do it, I will either learn how to do it first or explain to the students that we will be learning together. Although last night I managed to complete several proof-of-concept applications using AR, I still think I will be learning a great deal with the students.


I have twelve students I have never met, A presentation on AR, I have three ideas we could use as a starting point and I have a lot of enthusiasm for the project, I think that is all I need. It has already been a learning experience for me i.e. last night I learned about QRCodes here is mine for my website. Again this is a project I couldn't have done with my old laptop, it just wouldn't have been able to cope with it. I am excited and I will blog later about how we adapt the ideas I have into applications using the students designs.

I will be using QR Codes instead of AR markers (which are fairly similar) for the project that way we can that way we can cover more areas in the sessions.

Thursday 26 April 2012

Dear ICT you are an alcoholic.

ICT has a bad name, it probably doesn't need me to refer to it as an alcoholic as well, but I have good reason to. We all care about ICT, but it has been a little neglected and has had some pretty difficult changes in recent years. It can be a little aggressive, defensive, stubborn, but deep down in its heart it means well. It is a friend who's company we have enjoyed in the good times, but we need it to sober up and realise, it has a problem.

I love computing, ICT, IT whatever you want to call it. It is so much a part of my life that describing it as a separate thing seems strange to me. If I make music I make it on the computer, if I send a a letter I do it via email on the computer, if I want to communicate and idea, learn something, experience something I often do it via a computer. Technology is the means by which I can do all the various work I do and that technology at this stage is a computer in its various forms. It wasn't always so; it used to be a sheet of manuscript paper for writing music, paper, envelope and a stamp for sending a letter, the technology has simply changed, but that is not a problem. It is the way we view that technology. When and who decided that a computer was something so marvellous that it needed its own subject? This might sound strange coming from me, some one who uses computers so much in everything that I do, but that is exactly the point. We do use computers in everything we do, not all of us but certainly a lot of us. If that is the case then why is it so segregated from the rest of the curriculum?

ICT doesn't need a separate lesson, subject of part of the curriculum, does a pencil? They are the same, they are both just technology. Can you imagine A level “Pencil studies”. I'm sorry I joke, maybe it is to lighten the mood, distract from the real problem, just for a little while.

I can hear people already furiously shouting/typing/communicating all probably on a computer “but what about programming?” and I would suggest is something different altogether. Look at it like this if ICT is like learning to use a pencil, computer programming is making that pencil. Not all of us need to make pencils, not all of us need to make software, but a lot of us use them both, they are however just the technology. It might even amuse some of you to learn that I actually learnt computer programming with a paper and pencil on train, without a computer in sight.

I know not all schools and teachers use ICT so separate from everything else, but a lot of them still do, and it is those who are the problem, it is those who need to realise that it is a problem.

ICT needs to be brought back in, merged, welcomed and accepted in to the other subjects. It doesn't need to take over, it just needs a place, it needs to be a part of something again. ICT has a bad name and is at risk, of being a loner, losing the people who care about it, losing its job and losing its meaning, but it doesn't have to be that way.

Matthew C. Applegate / Pixelh8

Clearly, I have been busy.

I have been very busy working on an idea which will be announced tomorrow, the project was funded by a private company but the are happy for me to disclose it, that is the whole point of it. It is and idea to share. I know what will happen as with EVERYTHING I release and it infuriates me. I will upload the work, release a video about it and I will get a comment something like this. "I have been thinking about doing something exactly like that". I hate these kinds of comments, I really do. So I am going to say it in the most polite way right now, I don't care. I just don't care. I am really pleased with it and it is done, maybe the reason you didn't do what you thought about doing is that you spent all your time commenting on videos? It sounds harsh I know, but I am really only interested in what people have done. I don't want to know about what people are planning to do unless they are ready to do it. Let me be clear I don't hate the people who post the comments, I just hate the fact they have not done what they had the idea to do. Does that make any sense?

Sunday 15 April 2012

We weren't playing around.

Inspired by seeing the wonderful viral video "Caine's Arcade" a group of kids have decided to have a go for themselves and roped me in to help. The group is made up of three 9-year-old children one boy and two girls. The words and phrases inside of the "" quotation marks are things that the kids themselves have discovered and said aloud to the group. We started off by having a brief discussion in the morning about some of the ideas they had for arcade machines, to keep the project manageable we are going to let each participant build two arcade machines maximum, this will also help limit the budget. Planning it all out in their "Arcade" diaries, the group decided by themselves that one diary is going to be about the "tactics" that arcade machines use to convince you to spend and keep your money, one is about the "mindstorms" or brainstorming ideas for the machines and the third is about the "Arcade" which is the detailed plan and components list for each of the machines. I wanted them to plan out these rough ideas first in their diary before the next stage which was actual field research.

I explained to them as researchers either for purely academic or commercial situations a group like this would apply for funding to do the research, research costs money, parts cost money traveling and lunch costs money. So after they presented their approximate ideas I announced that the children had successfully been awarded a £15 research grant plus travel and food expenses to travel to see a "proper" arcade in action. Needless to say they were very excited. I briefed them before we left that although we had our initial ideas, they may change over time, I asked them to think about how they spent their money (how much and on what machines), I asked them to ask me to take pictures of interesting things they find. I asked them to step back and think while playing these games what makes them fun, this last one is incredibly tricky but this is how I did it. I quite simply only allowed them access to £1 of change at a time after they had spent that they had to ask for more change and we would have a discussion about the machines we had played on as a group. I gave them no rules, they could play on whatever they wanted (except for the gambling 18+ machines) but interestingly they focused on a certain type of game or price of game, they two 2p machines. The classic "penny pusher" or variations of. It certainly makes the £5 playing/research money go further.

This is what we learnt from playing on the 2p penny pusher.

1) The toys over hanging the edge which are about to fall in to the prize slot also help hide an extended "sneaky hidden" ledge which helps keep the prize from being won as long as possible.

2) Down each side of the pusher there are ledges which allow coins to fall in to the machine releasing the tension of the coins and prevent the prizes from being pushed forward. The money that falls down these channels is kept by the arcade, and not returned to the player.

This is what we learnt from playing on the claw crane.

1) Despite having perfectly grabbed a toy, their is a chance that the machine will "drop it on purpose" or have a grabber to weak to pick up the item or what Wikipedia cites as "Payout percentage: Cranes equipped with this setting have onboard programming which cause the claw's grip parameters to be continually adjusted to achieve a pre-set payout percentage, usually specified with respect to the value of the prizes inside". After successfully managing to grab a Yoshi 10 ten times in a row we noticed that the machine claw "seemed to loosen" at the same time every time, so much so we stopped watching the Yoshi and watched the motor.

2) The higher the price 20p or 30p the "better" the prize

This is what we learnt from Arcades in general

1) Some arcades get you to change your "real money" in to tokens, possibly because they know you might "get bored", and they still get to keep your money as you can't change back small amounts of tokens.

2) The prizes or amounts of prize tickets you get from the "actually fun" games are smaller.

3) You need an awful lot of tickets to get even a small prize.

4) We spent £20 in total on a trip to the arcade (I also had £5), we earned 341 prize tickets, a dolphin keyring and some stickers. We are saving the tickets for our second visit to the arcade later in the year.

We didn't come away from the experience thinking that all arcades are evil money grabbing places, actually it made it even more interesting knowing all these systems were in place, it certainly didn't stop us spending money in them. Looking at it from the perspective of making your own arcade as a project and thinking of it more as a business it raises interesting question about how we should run our own. Should our focus be on fun or on prizes? Could we offer better prizes? We are also planning to visit Tim Hunkin's arcade in Southwold to see a very different take on how to run an arcade and what to put in it.

There is going to be lots in this project which will span the summer holidays, lots of technology and hopefully lots of fun. Any questions just ask me on Twitter @pixelh8

Monday 9 April 2012

Future Retro

Just as I did with the BBC Micro (see blog) I have done with the ZX Spectrum. I have made a simple little sample playing keyboard from some sounds from my sample library. Unfortunately last year my hard drive died which had samples from hundreds of different machines, so in order to do this project I had to get the ZX Spectrum and +2 out of the loft. They are in plastic containers so they will pretty much last forever and just to extend that life I have recorded them and put them in an App "ZXSynth" which will hopefully be on its way to you soon. I can't believe how "buzzy" the sound was from the +2 but after coming to terms with it, I realised that is why I am doing it instead of imitating or emulating the sound. All done now, I might do the Atari 800 next :)


Here is the source code for the notes

10 PLAY "O3C&#C&D&#D&E&F&#F&G&#
G&A&#A&B&O4C"

For the Bass
10 PLAY "UX2000W0O3C&#C&D&#D&
E&F&#F&G&#G&A&#A&B&O4C"

For the SFX
10 BEEP (RND*50), (RND*0.5)
20 GOTO 10
30 REM CHANGE To -50 and 0.01 for
other random sounds.

Have fun. Can't remember what I did for the Drums so you'll have to work that out.

Thursday 5 April 2012

I Have Turned Myself Around

So, for whatever reason I needed to get a small accelerometer working off of an Arduino Nano (and wasn't allowed to use a Wii Motion+), the setup needed to be small, so I grabbed one of these MMA7361 accelerometers of the net (Don't know if that is who I bought it from but that is the one I bought) and wired it up.

RED 3v3 & AREF to 3v3, ORANGE A1 to X, GREEN A2 to Y, YELLOW A3 to Z, BLUE D2 to SL (SLEEP), BLACK to GND.

The code was borrowed off of various forums and tweaked for my specification the best being the one shown below (tweaked slightly) taken from the Arduino forum here.

Needles to say it works, it is just a matter of working out what numbers I need etc, it is good fun waving things around like a lunatic while staring at a screen late at night, I recommend it. The image was made in Fritzing and tweaked in Photoshop CS5 as they didn't have the exact accelerometer in the library.

//ACCEL

int x_avg[10];
int y_avg[10];
int z_avg[10];

int x_axis = 0;
int y_axis = 0;
int z_axis = 0;

int slp_pin = 2;
int i;

void setup()
{
Serial.begin(9600);
analogReference(EXTERNAL);
pinMode(2, OUTPUT);
}

void loop()
{
digitalWrite(slp_pin, HIGH);

for (i=0; i<10; i=i+1)
{
x_avg[i] = analogRead(1);
y_avg[i] = analogRead(2);
z_avg[i] = analogRead(3);
}

for (i=0; i<10; i=i+1)
{
if (i == 0)
{
x_axis = x_avg[i];
y_axis = y_avg[i];
z_axis = z_avg[i];
}
else
{
x_axis = x_axis + x_avg[i];
y_axis = y_axis + y_avg[i];
z_axis = z_axis + z_avg[i];
}
}

Serial.print("x-axis");
Serial.print("\t");
Serial.println(x_axis/10);

Serial.print("y-axis");
Serial.print("\t");
Serial.println(y_axis/10);

Serial.print("z-axis");
Serial.print("\t");
Serial.println(z_axis/10);

Serial.println("");
delay(1000);
}

Wednesday 4 April 2012

Rock the Square Wave Bass Synth

So today I spent tinkering with the good old Arduino and the tone() function which is great fun it is simple to set up and it goes beep. I have however decided to merge it with the serial function in Processing turning the computer keyboard in to a musical one. This code was hacked to together from the various tutorials on the Arduino and Processing sites.

You'll need a 8ohm Speaker (I used a 0.5w one) and 100ohm resistor, I have connected it to pin 8 just like in the diagram which I made using Fritzing.

There are two chunks of code one for the Arduino and one for Processing. You'll need to make sure you computer is sending stuff down the right serial port so it might take a bit of fiddling, before it all works. After installing the software on the Arduino you can check it is working by opening the Serial Monitor and typing either c,d,e,f,g,a,b or C.

The code works like this, Processing takes a key press i.e. "a" and sends the byte "c", the Arduino interprets this and plays the correct tone after receiving it. If nothing is being pressed and "Q" is sent, I use this code for loads of different projects. I didn't want to include too much in this example I leave it up to you to clutter.

Processing code // KEYSEND

import processing.serial.*;

Serial myPort;

void setup()
{
size(200, 200);
String portName = Serial.list()[0];
myPort = new Serial(this, portName, 9600);
}

void draw() {
background(0);

if (keyPressed == true) {

if (key == 'a') {
myPort.write('c');
}

else if (key == 's') {
myPort.write('d');
}

else if (key == 'd') {
myPort.write('e');
}

else if (key == 'f') {
myPort.write('f');
}

else if (key == 'g') {
myPort.write('g');
}

else if (key == 'h') {
myPort.write('a');
}

else if (key == 'j') {
myPort.write('b');
}

else if (key == 'k') {
myPort.write('C');
}

}

if (keyPressed == false) {
myPort.write('Q');

}
}

Arduino Code // SERIAL TONES

#include "pitches.h"

byte val = 0;
int serByte = -1;
int count = 0;

int melody[] = {NOTE_C1, NOTE_D1,NOTE_E1, NOTE_F1, NOTE_G1,NOTE_A1, NOTE_B1, NOTE_C2,0};
byte names[] ={'c', 'd', 'e', 'f', 'g', 'a', 'b', 'C', 'Q'};

int noteDurations[] = {4, 4, 4, 4, 4, 4, 4, 4 };

void setup() {
Serial.begin(9600);
}

void loop() {

serByte = Serial.read();
if (serByte != -1) {
val = serByte;

}
for (count=0;count<=9;count++) {
if (names[count] == val) {
if (count<8){

int noteDuration = 1000/noteDurations[count];
tone(8, melody[count],noteDuration);

}
else {

noTone(8);
}

}
}


}

Arduino Code / pitches.h
//You'll need to make a new tab and call it pitches.h

#define NOTE_C1 33
#define NOTE_D1 37
#define NOTE_E1 41
#define NOTE_F1 44
#define NOTE_G1 49
#define NOTE_A1 55
#define NOTE_B1 62
#define NOTE_C2 65

Monday 2 April 2012

I'm busy

I haven't been blogging the exploits of my new computer recently, not because it isn't useful or the novelty has worn off. Quite the opposite I have been so busy I haven't written anything. The ability to work wherever I am means quite simply that I am working wherever I am. Currently I am juggling three papers for conferences for my PhD and this isn't a problem, whenever an academic epiphany comes to me I can simply open the MacBook and add it, whenever I want to add to a game I am working on I can. I have had to turn off the computer every couple of days to let it rest, Firefox seems to crash every couple of days, that is every couple of days, not three times an hour like the PC net-book did. I can do everything I need to do from this computer and now I have Windows 7 running on it I can use all my video and audio software that I prefer from my PC. Cross Side for the iPhone is coming, three papers are coming, I can't complain.

Tuesday 20 March 2012

When September comes,

I am a little concerned most of the ICT / IT teachers I have talked to have little or no clue as to what changes are planned for the curriculum later this year. There has been a lot of talk about programming (great), creative computing (woohoo) and some talk about embedding computing in to every lesson (could be good). Computers have for the most part invaded almost every aspect of our lives, which is both good and bad so why not use it to teach, if it helps. I only teach creative computing; animating, coding, game design, music and so on, I do not teach you how to do things like word processors or presentations and certainly not spreadsheets or databases. I am only interested in creativity. Sure you can write a great novel in a word processor, but that's something different all together. I know that I will be busy in September, trying to help as many local teachers as I can, I think this is really important to do so, to get the next generation ready to make incredible things.

I have been asked by several conferences to help teach some of these skills to teachers, and that is fine. Even though I do have to earn a living myself and it is hard when you are self-employed, I realise I can't teach all the kids myself.

I was asked about 10 things to do/avoid so here is five of each. These are to do with programming /game development. These are my own personal views and are not intended as a guide.

Do

1) Do have a go yourself first, play the games, read the magazines, research the culture, nothing wrong with an adult playing a video game. I met a teacher recently who didn't know what a "sprite" was. I told her, I need to have a lesson with you first if not, your gonna lose their confidence. We did, it was fine, but it might have been a disaster.

2) Do code, it is great. Personally I enjoy solving coding problems better than some games. Bringing something new to life, I feel is better than blowing something up.

3) Do try alternatives, some programming languages just fit better with different people, try Processing, Scratch and Small Basic. They are all free and great to start with. There are hundreds of others, eventually you learn how to learn languages and can swap between several in one day.

4) Do talk to your technician. Your IT technician is your friend, there seems to be a lot of tension between teachers and IT techs, I even went to help at a conference to help ease these tensions. My hunch is the techs are bored sorting out paper jams and other menial tasks, talk to them about coding and watch their eyes light up, they probably know quite a bit and probably love to help. I have a brilliant one at the school I work at regularly and I certainly couldn't do everything I do without his help.

5) Do encourage them (the students) to be creative (and silly), some of the best learning come from the silliest code, it was brilliant to make a random word generator or to put Rick Astleys head on a bad guy in a maze game, they had to learn to code if they wanted to join in and be silly, and they did.


Don'ts

1) Don't buy anything. Until you and the kids have tried it first. I am so tired of seeing teachers and techs bullied at conferences in to buying substandard crap that no one else would. Be assertive get a demo, or take me along.

2) Do use what you have, differently. Got a projector have a different student display his work on a wall in a hallway for others to see, it could be code or a drawing, or my favorite a virtual fish tank with fish made by students. Got a BBC Micro or Commodore 64 bring it in talk about the history, get students to time how long it takes to load up a game. Ok that was another Do.

3) Do Re-create games, you don't have to create entirely new things to learn from, it is always good to re-create classic games. You do this with books and films, video games are art and they need to be discussed in the same way.

4) Do encourage students to talk about games, chances are they will, do context analysis on the cover art, the cut scenes, the storylines.

5) Do use free software, it means the students are more likely to go home and carry on the work themselves. There are tons of awesome free software programs out there

I hope these help.

Below is the source code for a simple maze game, it would take me around two to three hours to teach it to a teacher and fully explain how it works, you''ll need Processing to load it. Processing is free, comes with loads of examples, can run off a memory stick, technicians like that and it has a huge online community of artists and coders who use it professionally. I have annotated as best I can to help out beginners.

//THE MAP OF THE SCREEN
//99 SOLID BLOCK
//97 EXIT
//o NOTHING

int SCREENGRID [] [] =
{
{
99, 99, 99, 99, 99, 99, 99, 99, 99, 99
}
,
{
99, 0, 99, 97, 0, 99, 0, 0, 0, 99
}
,
{
99, 0, 99, 99, 0, 0, 0, 99, 0, 99
}
,
{
99, 0, 99, 99, 99, 99, 99, 99, 0, 99
}
,
{
99, 0, 0, 99, 0, 0, 0, 99, 0, 99
}
,
{
99, 99, 0, 99, 0, 99, 0, 99, 0, 99
}
,
{
99, 99, 0, 0, 0, 99, 0, 0, 0, 99
}
,
{
99, 99, 99, 99, 99, 99, 99, 99, 99, 99
}
,
};

//CHARACTER X AND Y LOCATION
int CHARX = 1;
int CHARY = 1;

//THIS RUNS AT THE START OF THE PROGRAM
void setup()
{
//10 BY 8
size (320, 320 );
CHARX=1;
CHARY=1;
}


//THIS RUNS IN A LOOP
void draw()
{
background (125);

//DRAWS ITEMS ON THE GRID
for (int y = 0; y < 8; y++) {
for (int x = 0; x < 10; x++) {

//IF IT'S A SOLID BLOCK DRAW IT
if (SCREENGRID[y][x]==99) {
fill(255);
rect (x*32, y*32, 32, 32);
}

//IF IT'S AN EXIT DRAW IT
if (SCREENGRID[y][x]==97) {
fill(0, 0, 255);
rect (x*32, y*32, 32, 32);
}
}
}

//IF THE GOOD GUY IS ON TOP OF EXIT RESTART GAME
if (SCREENGRID[CHARY][CHARX]==97) {
setup();
}

//DRAW GOOD GUY AT ITS CURRENT LOCATION
fill(255, 0, 0);
rect (CHARX*32, CHARY*32, 32, 32);
}


//IF A KEY IS PRESS AND THEN RELEASED IT IS CHECKED
void keyReleased() {
if (key == CODED) {
if (keyCode == UP) {
if (SCREENGRID[CHARY-1][CHARX]!=99) {
CHARY--; // MOVE UP
}
}

if (keyCode == DOWN) {
if (SCREENGRID[CHARY+1][CHARX]!=99) {
CHARY++; // MOVE DOWN
}
}

if (keyCode == LEFT) {
if (SCREENGRID[CHARY][CHARX-1]!=99) {
CHARX--;// MOVE LEFT
}
}

if (keyCode == RIGHT) {
if (SCREENGRID[CHARY][CHARX+1]!=99) {
CHARX++;// MOVE RIGHT
}
}
}
}

Sunday 18 March 2012

Simple Yet Effective

Having this computer has today allowed me to be semi-social and build a level editor for "Cross Side", allowing me to try out levels before hard coding them into the game. Making a level editor makes level design easier and in turn may allow me to make better and possibly more levels. So I am very pleased with that. Although the editor can't handle all the objects that are in the game, it certainly will help with the basic layout.

Saturday 17 March 2012

Poly Wants A Chronic

I think is fair to say I am Polychronic, I can swap between several tasks over the course of the day, although I do make plans they are usually only rough guides or reminders of the work I am not really interested in doing. Tonight I have been researching for a paper I a writing and although this is no complex task for a computer to do, i.e. surfing the net for papers for the literature review, just as I was about to shut down the computer I realised I had about 15 .pdfs open in Preview, Open Office Writer, Firefox (20+ tabs), Thunderbird, Twitter App, Stickies, Finder (several windows). This would have been impossible on the old netbook, but because this machine could, I wrote a 1000+ words in 3 hours without having to reset my computer or close loads of things. So there.

Friday 16 March 2012

Just for the Record(s)

Having a MacBook has allowed me to dip in and out of the code for "Cross side" quickly repairing the records table for the game, allowing me to focus on the other work in my day. I am very pleased, knowing that the records table is done as when it comes to May I can purely focus on the level design.
So I am pleased, short but sweet.

Wednesday 14 March 2012

"Red Token" Tangible Music Interface


Here is a simple tangible musical interface programmed in Processing, using a webcam and some gaming chips. The sounds are made from samples I made on a BBC Micro, you can get them from my website at here. I have always been a fan of of "I eat beats" and "Beat Machine" and many more interfaces that can be found here and even though this is very similar to a lot of them, it was a good experience and good fun to make. Loads of people make chocolate cake and it's still pretty good. It was nice to go from simply detecting colour the other night to doing something with that colour in only a few hours in total. "Red Token" was a simple proof of concept for a much larger project that will be developed over time. Today my Mac has been justified.

It Read Red

So now this code can can also detect the colour Red across differentiating light quality, when it sees Red, it says "RED" in whatever box it is in. I am getting close to the final idea and will hopefully be able to let you know what it does besides confirm that Red is Red and it is Red is where I put the Red items. So yeah, good stuff.

Tuesday 13 March 2012

And Then It Got Really Good

So a night of coding, this only a few hours later from my last blog. I have now managed to detect which colours are being picked up by the webcam , break them down into RGB and then label them. I am not gonna give anything away here, but there is clearly a grid on the screen. I am so pleased that I can do this kind of thing as it opens up a whole new world for me. I will blog and provide source code for the project once it is done. Very excited.

Pixelh8 goes pixelated

Inspired by James Alliban's incredible visual work I have decided to start tinkering with the visual side of Processing more, but from scratch. Instead of tweaking existing code I have begun to write it after working my way through the tutorials. I have never really been interested in the visual side of things but now I have a powerful enough computer I have begun exploring it. Tweaking code is always a good way to learn, but you get a real sense of achievement when you are able to bring your own idea to life, no matter how simple it is. Annotated source code below.



//PIXELATE
//By Pixelh8

//Imports capture library
import processing.video.*;
//Calls the captured image myCapture
Capture myCapture;

void setup()
{
//Size of output screen
size(200, 200);
//Name, size and fps of capture screen
myCapture = new Capture(this, 200, 200, 30);
}

void captureEvent(Capture myCapture) {
//Captures the image
myCapture.read();
}

void draw() {
//Displays image so it can be scanned
image(myCapture, 0, 0);
//Check value of pixels and draws 10X10 rectangles in those colours
DETECT();
}

void DETECT()
{
for (int y = 0; y < 20; y++){
for (int x = 0; x < 20; x++){
//Tests colour of pixels
color c = myCapture.get(x*10,y*10);
//Sets colour to the colour of the pixel
fill(c); stroke(c);
//Draws the rectangles that colour
rect(x*10,y*10,10,10);
}
}

}

Sunday 11 March 2012

Best of Both Worlds

So today I did something strange, I gave a 128GB space to Windows 7 Professional on my MacBook Pro. It suddenly dawned on me, that because I can run Boot Camp, by buying a Mac your actually buying two computers it is wonderful. I can now potentially develop for Windows Phone 7 and XBOX 360, iPhone, iPad all from one machine. It also means I can transfer all the PC software I own over to the new machine. So I can today justify the new machine by saying I didn't just buy a Mac, I bought two computers for the price of one.

I think however I will primarily be using Lion as it does most things I need it to do, using Windows 7 for the Microsoft specific projects, it also means I can teach those things on this computer too.

I must however to remember to keep a backup of things as if I am using this laptop for everything, it puts a lot of eggs in to one basket.

Saturday 10 March 2012

A Midnight Snack

Just after writing yesterdays blog, just after midnight, I loaded up Xcode again (wow twice in one week) and I started level planning. It was easy to do, I didn't have to swap cables to my monitor and load up the Mac mini, I just clicked Xcode and away I went. I think I will progress through this faster than previously thought, I made three levels in 15 minutes.

Friday 9 March 2012

IRL

So today I got to use the laptop to teach with, it was very useful, I was able to have about fifty million programs running at once without it breaking a sweat, breaking down or just not responding. Teaching needs to be flexible and be able to respond to questions with answers quickly to maintain the student's attention, I was able to do this today. A student of mine finished his TIC TAC TOE game and was able to move on to hardware, via the Arduino the Mac was able to have everything sorted to teach him in around 20 minutes. For me it was the "I don't need to worry, because my computer is more than capable of doing that, so I can definitely teach that today" feeling of confidence. Therefore although this blog is short as I covered most of this here , the laptop today is certainly justified.

Thursday 8 March 2012

You Can't Get There From Here

I think it is fair to say I am happy with my new laptop. I was meant to go out tonight but in all fairness I was too tired to travel again after teaching all day. Fortunately the new laptop has allowed me to sit on the couch, be sociable and start coding "Cross-side" again.
I have had a demo on my iPhone for ages now I just need to design the levels, the game engine is completely done. "Cross-side" is a spin-off from "OCARBOT" set in the same world but a very different puzzle game altogether.

It is ridiculous I have finished the engine for "OCARBOT" for the XBOX360 and "Cross-side" for the iPhone/iPad I just haven't "finished" it. They are just sitting there on my computers. I have the month of May to finish them. On May the 1st I have the last bit of work I have to do for my PhD this year after that for a month I have nothing planned. So hopefully I will get one of these released.

So today my computer is justified by allowing to get starting on "Cross-side" again once I virtualise Windows or Boot Camp it I can start work on finishing OCARBOT PC, EDU and XBOX 360.

Tuesday 6 March 2012

Pretty Lights

So the MacBook Pro arrived yesterday, I was out all day so i didn't get to use it til around 7pm. It like all new machines needed rigorous installing of software to be useful. So the very first thing I installed was Processing, then Arduino, then Open Office, then Thunderbird, then Firefox, then Unity, then updated OSX so I could install XCode 4.3. It only took about 2 hours in total.
My emails were moved over from the old machine, my Firefox was synced with all other machines, it was ready for creating it was ready for research. I also installed Steam because it could and so now it was also ready for gaming. It runs Lion so it took a little getting used to with the mission control / launchpad things but it is all fine now.

The hardest thing for me to grasp is that I can do everything I need to, from one machine.

Today I will be using it for the first time in a workshop. I have already made something with it in Processing for kids to use use in a light and colour workshop being run by a local home educators group. I was only asked around 10:30pm last night if I could and by 12 I was going to bed having made an interactive webcam light colour thing. So I just need to get the coloured gels out of the loft and get some flashlights / torches so the kids can create images with their movements set up the projector and so already the Mac would have been put to good use. I would not have been able to do this on the little old netbook the processor just would not have been able to handle it. The kids would have literally been in the dark.

Friday 2 March 2012

A Funny Thing Happened of the way to the Fridge.

I use computers a lot, all day, everyday. I make things a lot, all day everyday. I make music, animation, software and I teach all of these things, all on a computer of some kind. I have however always had a strange approach to this in that I always used either old, secondhand or cheap equipment often donated to me. I won't lie it made things harder, it was a challenge, using older and out of date hardware/software was often frustrating. Despite my love of technology I couldn't justify a buying computer, especially a top of the range computer for just me. I use computers until they die, until they catch on fire and then I use their parts to build "new" machines that eventually catch on fire.

Last year I bought a netbook an xxxx xxxxxx xxx, it was cheap at around £200 it was clearly approaching the end of it's commercial appeal the online retailer was pushing the newer model. It strangely appealed to me so I bought it, it was a mistake, it was awful, I bought it for giving presentations, checking email and browsing the Internet. It couldn't even do this very well the machine would often crash maybe once an hour. xxxxxxx x, I like the way the advertising campaign used "everyday" people to take credit for it, perhaps that way xxxxxxxxx could deny responsibility for it. I couldn't even change the desktop image.

The other day this awful machine, which would often start with the words "not responding" decided that the LCD would just die, just before I was about to teach kids about web apps. Maybe the idea was too much for it, too new, it just couldn't handle it. Fortunately, I was able to plug it into an external monitor and the kids still enjoyed learning about web apps. I was so angry this this piece of crap stumbled along all of its life and then died, and I bought it new.

I had a chat to a lot of other people about the PC / Mac debate and I have always been ok with both, they are just tools. I have a Mac mini it has never failed me, I have built huge art installations with it and coded apps with it, it runs open office, it works with my printer. I have a brilliant Dell desktop I have made albums on it, decoded mysteries from World War II its not very portable but it works most of the time. I could never justify spending a lot on a new machine. Until now.

I am so busy people are always asking for my help to do this or that. I can not have another computer that is "not responding" for most of the time. I have always championed re-using technology but after a chat with my partner this evening, she bought me a top of the range MacBook Pro. I felt both excited and sick at the same time, I felt relieved and ashamed.

This blog will follow the life on the machine, partly to justify spending an awful lot of money on it and partly to see how it changes my productivity if at all. I use computers for everything I do, it is my main tool for my skills, will this change me? Or have I already changed having agreeing to own such a new and powerful machine?