#programmingforcreativity
Explore tagged Tumblr posts
Text
Revelation/ Proud Moment 1: Programming
I ran into a little problem when randomly generating the position of the two balls in assignment two:
The circle would sometimes form partly off-screen.
I thought this would be an easy fix by setting the parameters of the random function for the location, from the beginning of the canvas plus the radius of randomly generated circle to the end of the canvas minus its radius...
Unfortunately, it still phased off-screen...
AND HERE’S WHY!
x = random (r, width-r);
y = random (r, height-r);
r = random(10, 20);
Even though I told the computer to offset by the radius, I did not realize that at that point the “r” did not exist/had not been generated yet. So I simply made the following changes:
r = random(10, 20);
x = random (r, width-r);
y = random (r, height-r);
And this fixed it :)
1 note
·
View note
Text
Final Assignment - Got The Colours Working
I barely caught Stefan before the end of class, he helped me to get the colour palette working in my programme. I still have a lot to go, but it’s now pretty fun to use.
1 note
·
View note
Video
tumblr
Programming For Creativity
Day 1 (07-03-17)
Today, we had our first session of Programming For Creativity. Overall, it was a pretty good lecture. However, I have never learnt programming before, so I was a bit confused with the language. Firstly, we learned about the coding of the first piano. It was really good to listen to the way that the piano was playing and I soon realised that it was due to the coding. No human could have played that piece of music as it was quite fast and needed lots of keys to be played at once.
Then, we downloaded the Software required for programming — “PureData.”
Since I am new to this Software, I asked for some help from the people around me. It got easier after a while and I was able to produce the three different sounds taught to us.
(see the video above - the sound isn’t clear but if you listen closely, you can hear the three different tunes.)
This is quite a fun Software to play around with and try different coding, however, I will look at different tutorials to learn more and be ready for the next lesson.
———————————————————————————————————
1 note
·
View note
Text
Cool stuff with PureData
In this morning’s Programming for Creativity class we continued learning about PD’s features, moving on to the more advanced send and receive methods. This sends data between two objects in the file. While looking at this, we found ‘netsend’, an object that promised to allow data to be sent over a local TCP or UDP connection. Gianni and I started reading the help guide and trying to get it working. I got a localhost transfer and could send numbers to myself, and after some IP address finding and changing to a UDP connection, we were able to send numbers between computers. Josh also set up his PD document to send a stream of numbers to mine, and I connected the two streams to an oscillator and dac. The result was a remote speaker playing a combination of two frequency sequences.
0 notes
Text
Programming Reflection
So finally programming is over! It’s been a frustrating yet rewarding experience.
In the first few lessons of programming i knew it would be something that would interest me having never done it before. I immediately found out that the text based nature of it is just like learning a whole new language. The only differences being that there absolutely no room for error; it’s instruction based. This was initially a challenge.
What I really enjoyed getting into was the understanding of the logic behind how you instruct the computer to do different things i.e: how little movements of an object would have to be precisely mapped out so it wouldn’t stray off course.
For the game I was quite quick to get all the basics down, but the hardest (and longest) part for me was trouble shooting. I spent probably just as much time putting the game together as I did testing and troubleshooting it. Apon completion I’m sure that my code writing could have been done a bit neater, but time pressure got the best of me.
Being having completed this paper it has given me a really interesting insight into the world of programming. Being naturally more of a hands on person, this has opened up a new avenue for creative practice. Also this has given me immense respect for the hours that go into making things such as websites, games, programmes and phone apps. Software developers are the real un-sung heroes of the modern age, for there seems to be a small piece of programmed software in all of our everyday lives.
0 notes
Video
tumblr
It's always a good idea to let someone else test your game! Even when you got beaten in your own game.... Feedback: it's fun and a real challenge when you add more balls. She asked for an option to decrease the amount balls if you added to many balls to make it easier.
0 notes
Text
Episode 1 of James Learns Programming!
Who knows if this will lead to a whole blog series or my laziness will render this to be an embarrassing standalone post but oh well... I deleted my games so I may as well post about it with all the free time I have (not much actually). I don’t know why I mentioned that or why I am still narrating my thought process but ANYWAYS!
Tonight, I have decided to finally tackle Assignment 2 for my programming class which requires me to simulate a certain number of balls (hopefully three) bouncing around a canvas. And so that when they collide with each other, they stick together and continue to bounce around in unison.

The epitome of contentment or perhaps postception...
I began by setting up the canvas, setting the ellipse mode to center cause why not and before I do anything else, I’m gonna teach myself how to do OOP (Object Oriented Programming I think??) and to use PVectors.
Here is the video I am currently watching to accomplish the latter:
https://www.youtube.com/watch?v=7nTLzLf7jUg
Let’s see where this goes...
__________________________________________
PVector location;
location = new PVector (100, 50);
___________________________________________
Oh... wow. So here’s what I learnt:
PVector is a class that stores two variables (three but we shall not tread into the 3D realm yet): x and y
It’s used so you don’t have to keep on typing x and y all the time and also so that you know what the x and y are for (eg. the x and y components of velocity, location, etc)
The video contains code that does everything except collision detection... but I won’t abuse it cause learning is gud
Now that’s done, I shall attempt to replicate the code from scratch... right after I figure out how to make a class (hahaha siiiiigh I’m so far behind).
Important Stuff to Keep Note of While I Read That I’ll Forget After Reading:
Class: a description of the structure of an object
Instance: a specific example from a class
After you define a class, you can use it as a new variable type
Okay reading sucks here’s a video(s) on Classes in Processing:
https://www.youtube.com/watch?v=lmgcMPRa1qw (defining a class part I)
https://www.youtube.com/watch?v=XwfOVFelLoo (defining a class part II)
A lot of the info about defining a class has gone way over my head especially the constructor part of it so I’m going to play around with it in processing now.
An hour later...
HEY! So I kinda got it, I managed to create a class for balls and had their locations and radii successfully randomized upon generation.
And now I have managed to get them bouncing around the screen.
It is now time for me to go to bed as I have some random class at 9 am tomorrow to go to.
Tonight was a lot of fun :).
1 note
·
View note
Video
tumblr
Managed to get a file import window working with one GPX file, along with animations. Once a file is selected it plots the GPS coordinates out.
I still a lot to do but I’m happy with my current progress!
1 note
·
View note
Text
Mankini Man has launched
Done! Finally after a lot of tidying up and bug fixing the game is complete. Now with a score counter and losing mechanic im really happy with how its turned out. Some people may call the game a tad contraversal but its exactly the kind of game that seems to get popular these days. lets just hope Stefan likes dancing men in Mankinis...
1 note
·
View note
Text
Programming - Done
With this paper at least I hope I've got my Processing woes behind me. UNlike last year I have completed something that works the way I intended it to this time, and with some help I got around the trouble I had with having balls animating when I only wanted them drawn once.
Dave suggested the use of a toggle, which fits because it allows the user to only draw an object when they want to, and because they are drawn randomly across the screen I implemented a function where the objects are drawn at the point of the cursor - which lets the user select a point to draw at if they want.
Hopefully I've got enough for at least a pass, although I was partially frustrated a few times getting this done, I'm glad looking back at what I've done. I've learnt a lot along the way, and this is far from the end of using code in my career, things I can only get better from here on I guess
0 notes
Text
Programming For Creativity
Day 5 (04-04-17)
Today, I got a wake-up call. We received our test results from last week, and to be honest, I did better than I thought, but worse that I should. I know the reason behind this grade though — I haven’t been spending as much time as I should on this subject, because I think other subjects are more important and time-consuming. So, I guess I really need to manage my time so that I can focus on this part of the course as well.
What I find difficult in this course is understanding how everything works. I am quite new to Programming and I think I’m trying my best to pay attention and trying to follow what I’ve been taught. However, by not putting in extra time or prioritising correctly, I’m letting myself down and basically failing this subject.
I still haven’t started the project for this course, however, after talking to Colin, I was feeling a bit better. I think I will use Max for this project as it can be a bit easier to use than PD. It also has many more tools and options, and allows more freedom to make the codes look attractive, which is one of the brief specifications.
For the rest of the week, I will go over all the slides and look at Max tutorials to help me get a better understanding of the Software. I believe if I practice during my free time, I will get a better grasp of both Softwares, and will easily be able to achieve this project. My goal is to at least start on this project by Friday, so that I have next week to improve, make changes and receive any help or feedback from Colin.
————————————————————————————————————————
0 notes
Text
Final Assignment - Cleaning Up Some Code
Just making a Class to clean up all this code...
0 notes
Text
Success!
After coding half the night I finally got both of the speakers to play a tone in the same sketch as my ultrasonic code. I didn’t know if the issue was with my code, or a timing limitation with the Arduino, or an issue with the library.. Turns out it was an issue with my code, and the library. After loads of troubleshooting I fixed the issue and the harmonic tone works great.
0 notes
Text
Final stretch
The game is almost there, with Kittens falling down the screen that you have to save, all the sound effects working and a score board the game is really taking shape. Im super happy with how the game has turned out, it may be very simple but it seems to bring humour and joy to everyone who plays it and i can see it as being one of those stupid games that become an internet hit (like flappy bird). Only a few more bugs to sort out but the thing is pretty much finished. Couldn't be happier!
0 notes
Text
Sexy Sax Man
I thought that before i get into designing some game mechanics i could add some music to spice up my game. Looking online it took me a while to find anything that worked with the scene. However eventually i stumbled across the Sexy Sax Man 10 hour loop, and when i combined it with my game...it was magic. By simply adding that song it literally changed the entire feel of the program and i love it! Im thinking of ditching the platform idea as my game has naturally developed away from that, and from watching other people reactions from playtesting they all seem to absolutely love it.
0 notes
Text
The Party has begun
Today while messing around with my program i stumbled across something brilliant. I toyed around with a few different backgrounds for my platformer but couldnt find anything that really fit the theme of my Mankini Man. I decided to try a number of colours flashing in the background, which looked pretty good. Then i added the Alpha Omega symbol over the top and took the game to a whole new level, it worked really well. Now i just have to start thinking about game mechanics and possibly put some sound into it.
0 notes