Sunday 22 May 2011

Working with others

Both Dave and myself are making our games in a program called The Games Factory 2.
With this program there's a section that helps us to program the aspects of our game. Since there was alot of diffents things and it was our first time using the program we sometimes got stuck on certain aspects.

To start with to work out the collision between my characters and the objects I made a reference point that is hidden behind the background layers, with this it meant I could have my sheep and cow move behind and infront of boulders and other obsticals that I could place in my game. Dave was having trouble with his animation where his character would jutter while walking, by showing dave what I did with mine he was able to use the same technique to smooth it out so it would run properly.

Both of us have characters that used mellee attacks however collision between the character and the enemy meant the whole body would do damage instead of just the weapons or the foot of my character's kick, using the same reference idea we had it techically "shoot" a box that's hidden and when it would make contact with the enemy it would do damage. By setting it so it fires at a speed of 0 making it so it can't move we was able to make it so when the attack happens it would only be on the area where we set the "attack box".

However this added a second problem for us as this "attack box" would appear at the start of the attacking animation instead of when they should of make contact with the sword swing or when the kick was fully extended. After tinkering Dave was able to use the value function so the "attack box" would appear later in the animation. Basically as the game starts we assigned a value to the character for example we set to be Value B, then a number to it is set which we used 100, then we made it so every 0.01 seconds it removes 1 from the value, then set it so when we hit the attack button it would reset the value to 100, finally a condition was put in for when the value of B hits 80 the "attack box" would appear. With this we were able to delay the "attack box" appearing to be in time with the animation by changing the number of when value B reaches. It was a bit technical but it worked well for what we needed.

I wanted to have a shadow underneath my characters however I couldn't figure out how to make it transparent with the game engine, even making it semi transparent in photoshop beforehand and importing it in didn't work and I was pretty much having to accept solid shadows until Dave figured out when he was playing with some settings that there was a transparency value within the coding section I could use.

No comments:

Post a Comment