Sunday, 27 November 2011

Final Week - Get your assessments in!

You have 3 assessments due with me in this final week.

Due on Tuesday - 
Due on Wednesday -

Tuesday, 22 November 2011

Full screen game

place this code on frame 1 of your game:

fscommand("fullscreen", "true");

Sunday, 20 November 2011

Week 17 - Web Interface Design

Discussion: Web Usability Principles & how they apply to your assessement
1. Don’t make users think
2. Don’t squander users’ patience
3. Manage to focus users’ attention
4. Strive for feature exposure
5. Make use of effective writing
6. Strive for simplicity
7. Don’t be afraid of the white space
8. Communicate effectively with a “visible language”
9. Conventions are our friends
10. Test early, test often
Resource: http://uxdesign.smashingmagazine.com/2008/01/31/10-principles-of-effective-web-design/

Exercise #1: Create a sitemap for your game's website

Exercise #2: Create a design concept for your game's website.  I suggest you use Adobe Illustrator to create your final mockup.

Sunday, 13 November 2011

Week 16 - Web Interface Design & Game

This week I would like everyone to try and finish your game.

Over the next two weeks, you will be designing a user interface for your game website.  You will be presenting this to the class during Week 18 (last week of the term).


Monday
Work on your assessment that is due tomorrow (Flowchart, HUD, Start Screen)

SURVEY EXTENSION: Survey due next Monday 21st November

Tuesday
Your last two assessment events have been uploaded to Moodle

  • Web Interface
    • Create Sitemap
    • Create homepage concept
  • Presentation
    • Present your website concept to the class and discuss usability

Next Week
We will be discussing 10 Principles Of Effective Web Design and how they relate to your assessment:
1. Don’t make users think
2. Don’t squander users’ patience
3. Manage to focus users’ attention
4. Strive for feature exposure
5. Make use of effective writing
6. Strive for simplicity
7. Don’t be afraid of the white space
8. Communicate effectively with a “visible language”
9. Conventions are our friends
10. Test early, test often

Tuesday, 1 November 2011

Game Help

 Scrolling Background Tutorial


http://www.kongregate.com/games/Kongregate/shootorial-2








Create a Time Counter Bar

 onClipEvent(load) {
    timeCounter = 100; // set default width
    timeSpeed = 0.5; // set decrement rate
}

onClipEvent(enterFrame) {
    this._xscale = timeCounter; // set width of rectangle to equal % of counter left
  
    if (timeCounter>=timeSpeed) { // check if rectangle is still larger than 0 + decrement rate
        timeCounter -= timeSpeed; // reduce with of rectangle
    }
  
    if (timeCounter < 10) { // check if only 10% of bar left
        var colorful = new Color(this); // create new variable for colour of selected object
        colorful.setRGB(0xff0000); // set color to red
    }
}




Import sound effects to your game

  1. Import sound file (.mp3) to your Flash library
  2. Right-click on the file in your library and view Properties
  3. Check 'Export for Actionscript' and give the 'Identifier' field a name that you will reference in the AS code.  The example below has an Identifier of 'blast'
  4. Insert the following code on the event that you want the sound to play (eg crash sound should go on the hitTest event):
variableName = new Sound(this);  // Create variable that represents a sound associated with this movieClip object
variableName.attachSound("blast");  // Attach sound from our library with identifier of 'blast' to the new sound variable
variableName.start();  // Play the sound!
You can also specify a start frame and loop timeout for background music. 
variableName.start(0,99);  // Play sound from frame 0 (start of clip). Loop 99 times before stopping
Resources: 
http://www.kirupa.com/developer/actionscript/sound.htm
http://www.gotoandlearnforum.com/viewtopic.php?f=28&t=26222




Create a Barrier to stop your hero character flying out of the screen

Place the following code on your hero Movie Clip:

onClipEvent (enterFrame) { // every time the frame runs
if (Key.isDown(Key.UP)) { // when the UP key is pressed
if (_y>30)  // check if the center of the object is within 30px from the top of the stage
_y -=5;  // move the object up 5 pixels
}  //stop checking if the UP key is pressed
} // stop checking every time the frame runs




Respawn objects

Watch the following tutorial on how to randomly spawn enemies (eg Asteroids):





Random Colours for your spawned objects:

onClipEvent(load) {
rndColor = Math.round( Math.random()*0xFFFFFF );  // generate a random color coloredObject = new Color (this);  // colour of this object will be called 'coloredObject' coloredObject.setRGB(rndColor);  // set colour of this object to be the random colour
}



Random Sizes for your spawned objects:

onClipEvent(load) {
randomSize=random(80); // pick a number between 1 and 80 this._xscale=randomSize; // set width to equal random number this._yscale=randomSize; // set height to equal same random number
}



Random Rotation for your spawned objects:

onClipEvent(load) {
this._rotation= random(360); // set rotate angle starting position rotationRate=random(5); // set random rotation speed between 1 and 5 degrees per frame
}

onClipEvent(enterFrame) {
this._rotation+=rotationRate; // rotate frame by same value(speed) each frame
}