top of page

Unit 10: Doodle 

My idea for this unit is to create an interactive fighting game using action script.

My inspirations are from 3 big game franchises, Street fighter (by Capcom) Tekken (by Namco) and Mortal Kombat (by Warner brothers). The reasons these 3 games are my inspiration is because they all have this similar arcade 2d style. Although they now use 3d assets, they still all maintain this 2d side camera style for their games, although I will focus on the styles of the earlier iterations of the games back when they were actually 2d assets. 

 

I chose this idea because I think that these types of games tend be quite simple characters with animation sets, but it still quite competitive and entertaining as an arcade game

 

Problem I may encounter is an expect of the scripting, an example of this Is when an object hits another object, we will use a ‘hit test’ statement to register the hit, the only problem is how to register what object hits what and who loses life or gains points. 

in this activity we started by creating a movie clip symbol with an animation, we then added a 'stop' script on a layer, this stops the animation from playing at the start, I then started added another button with script, that play the animation when you press it. this exercise was like basic introduction to scripting.

we then started a exercise that will enable us to creating a simple pong like game, we will be using script commands in order to create the different aspects of the game. there are three main aspects that we learnt for coding this game, the first are variables. variables a word or phrase that has a certain value given to them , an example is, "walkspeed =10 ",  this means is that the word 'walkspeed' now has a numerical value of ten. The reason we use variables is becouse  its very time sufficient, you can change its value and it effects the rest of the script that has this variable, unlike if you would add the value by itself (hard coding) meaning you would have to change every single one.  

 

Second aspects are statements. statements ways to start different scenarios if your scene, this is how you're start a line of code, starting with a statement, referring to what you are affecting and add a  command to change it.  

different statements we learned from this were: 

'load' statements: this is a to load up different variables into the scene once making them active in the code

 

Enter frame: this means when the timeline enters a frame. You would usually use this at the start of youre game to start things off 

 

If statement: if statement is used when the situation is changed, and you want something to react to that change, an example of is.  

"If (_x  >endwall){ _x = start wall" what this code means if the objects x-axis go passed the end wall, it will go back to the the start.  

 

In this pong exercise I have also used hit test, hit test is like a point or an area where it changes aspect if a object collides with it. In this case if the ball collides with the hit test it  bounces of in an different direction. 

  

for my fighting game I decided what art style I wanted to game to be in, I did some research on different classic fighting games such as street fighter and mortal combat. 

 

I have found that the art direction for the games are very looks quite cell shaded stylized, In this art style, the characters have the dark bold lines that are trying to interpret the details, giving the character the edgy look, because of this edgy rough look  it makes the character looks worn down as if they have been in a fight, which is perfect for the games there In. other games that have similar styles are games such as borderlands and walking dead telltale games, using bold outline as a silhouettes enhancing that cell shaded look,

 

  

I have also noticed in these games that there clothing is very dirty which makes  sense in terms of story but also adding to edgy look.I will using different aspect like the bold outlines and dirty clothing on my character to achieve a similar loom and feel.

Design Research

Pratical Experiment 

character design 

This is my character design, I have used my research on borderland as the main inspiration of the character, I have taken aspects such as the bold lines representing details and the dirt on the clothes to simulate that edgy stylized borderland look.  

I have chosen to create a 3d character because I was unable to capture the look and feel that I was going for, when trying to create 2d illustrations  for my sprite sheet ( a sequence of animation laid out in images) conventionally I would of illustrated a 2d sprite sheet of the animation. my plan is to rig and animated the character in Maya and then render the animation into an image sequence and using those images for my sprite sheet and for my game  

I have rigged and animated the character model I have created. for the rigging aspect. I have used the human IK node in order to create a default bi pedal skeleton, I then move and added different aspects to match my character, an example of this is extra joint in joint area in order to help deformation. sues this helped speed up the process instead to creating my own skeleton which would take a lot of time. I then added skin weights to model, skin weights tells the model how to deform different part in a certain way. 

 I used skin weights to try emulate how skin deform and fold on the human body. I was able to achieve some aspect of correct deformation using skin weights, but for places like shoulder, knees and elbows, I wasn’t able to have good deformation, because the skin wasn’t enough to fix, in the future and can use blend shapes to fix this.  

 

for the animation I have used different sprite sheets found online as a template of the move set I have created. using my current experience animating using flash, I was able to create animation in Maya I as I know the basics of key framing. one problem I have with my animation is that they may to be dramatic or snappy enough for my game making the animation I used look boring. I could change this by adding more subtle features like facial expression and changing the timing and position of the key frames.

Because my flash game is a fighting game the main concept of the game is to get the character to do an animation when and bottom command is entered and to get an a reaction from the apposing player, in order to achieve I used two main coding statements which are:  'if key.is.down' ( which means button is pressed) and 'if hit.test this' (meaning if an object collides with the object you are referring t) with these two statements I am able to make the character to do something when you press a button and make the apposing character to do something when the first character hits her.  in my code  

 

These commands have a big flaw, which is the main reason its not a two player game, hit test wont be able to register who is the attacker and who is the receiver, meaning it will not know who to retract health from. 

The second aspects of the code is the command of 'gotoAndstop'  command, this commands will refer to an labeled animation and play it when an if statement goes off.  

 

As you can see  have an "&& !jumping" line of code, this code means and not jumping. this is to further specify when to play the animation, it was a way to fix a problem I had where I the animation will either continuously play after it should or play while pressing a different, The 'else if'  statement also helps specify when to play then animation by saying if the statment is not active do this action, in my case go to idle pose

 

fighting game scripts 

The main scene for my game, I firstly added the characters which I have and animated. when I imported the image frames, I had to added a bitmap on them in flash to the are usable within flash, the side effect of this that  the losses a lot of detail making it look drawn or painted with flash. although was not my initial goal it still visually looks good almost like a minimalist art effect.

 

I have recycled my japan temple environment from  previous projects to use as the  background. I did the same process to get that painted so it will blend with the rest of the scene.

 

 To finish of the graphics for the game I added the flashing fight text at the start and added health bars. one thing I could of improved the aspects such as the heath bar and text. I could of created my own graphics in order to add detail so it would not look so plain  

other lines of codes are for aspects like jumping physics in the game and the health bar. the jumping script contains an array function where if the jump bottom is pressed , it makes the why position of the object go up and then activates the gravity code making the object fall back down the floor.

once it hit the floor the jumping gravity and jumping script is deactivated   

 

for the health bar I first had two bars one blue and red, I then added a script, to shorten the blue when the character is hit, giving the impression that it character is losing health. 

This is my final game/ interactive toy. The initial idea for this unit was to create  a game that showed that I have a basic understanding of scripting, I have decided to create a fighting game for the unit. To achieve this I used different coding statements depending on how you want your game to react  in a certain situation. In my case I had to get the character to react with each other when they are fighting.  

 

I think I was able to successfully get the characters to react within one each over and get them to react to button inputs, its show that I can code the basis of a fighting games. I also think that I was able to create character and animation for the graphics of my game, making it seem like they are actually fighting.   

what I think I could of improved was the animation itself is to make it seem more dynamic and dramatic so  it has more weight and feeling to the move set, I also think I could of found a way the fix the problem I have where the code cant register who is hitting who and turn it complete two player competitive fighting game.  

The way my research has influenced the game is by helping me understand the bases of a fighting game, how most famous franchises are still keep this 2d arcade style layout even when they use 3d models, I used this idea within my own game.  

I also had inspiration from the cell shaded like art style for games such as borderlands and streetfighter, that dark bold line detail on the character and dirty texture give that grungy look to  model and like there ready to fight, all this help with the atmosphere of the game.  

 

In terms of coding I decided that the main aspect were going to be controlling the characters to preform different animation.  I used an 'If' statements to play an animation  ("GotoAndStop() ") when a you press a button ( Key.is.down).  for the apposing character I used the same if statement but for this I used when a hit test hits the character('if.hittest.this') meaning when something collides with the character it  will play an animation.  

 

I created the characters within Maya, where I modeled/ textured, rigged and animated the character, render the animation and image sequence and used those as frames for my sprite sheet. I went through this process instead of hand dawning the graphics' because I felt like I would not be able to smoothly animate hand drawn animation within the time given. I also think I better captured more of that cell shaded borderland art style then if I was to hand draw the character.  

one strength was that the concept for coding for this kind of game was simple, the game itself relied a on  the animation to bring it to life. I also think that the process of creating the character such a rigging a animating went quite successful as for it my time attempting to use this workflow.  

 

one weakness was that I was unable to figure out how to create it two player, due the problem with using hit test and how It cannot register the attacker and receiver.  

Final Game

move character

fighting controls

click on game to play.

I researched on ways of how to code a fighting game, I found that the main concept when coding fighting games is to have pre -made animation that play them when you  press a certain button I learnt this form a ' beat em fighting game online  tutorial, by Kris Foxton in his tutorial he shows you how to create animation  using sprites sheets ( Animated frames laid out onto on  sheet. he put those animation into a movie clip symbol and then adds script for the character to move and play it animation when doing certain thing like running or jumping, the code he uses to animate the character , is 'GotoAndStop' command, this command will refer to and play and animation when its in a certain situation, In the games case, It plays the an animation when some one presses a button command. I will take this command and use it as my main coding script in order  to bring my character to life when there fighting, the only problem is, the tutorial does not teach you  how to make it multiplayer. in order to make my game a full functional fighting game I need to finding a code that allows me to make it multiplayer. 

Coding Reserach

bottom of page