Monday, 22 January 2018

Exit Interview

Exit Interview

You have reached the end of the course. 
Some assignments you may have enjoyed while others ...

Question 1: Which assignments did you enjoy and especially why?

Question 2: Which assignments did you struggle with and why?


Each year this course changes flavour and explores different software.

Question 3: What innovative idea or software would you like to explore?


Now look introspectively at yourself.  
Look at your effort. 
Look at your distractions. 

Question 4: What should you have done to do better?



Question 5: Sum up your experience in IT

Tuesday, 16 January 2018

Animate CC -flappyBird -Part6

Animate CC -flappyBird -Part6

In this section you add script for ...
Follow the tutorial

http://blogs.adobe.com/animate/part-6-building-a-html5-flappy-bird-game-clone-with-adobe-animate-cc/





 









my issue
with undefined instance - in UI class

I changed the following form 'this' to 'exportRoot'
function UI()
{
this.scoreLabel = exportRoot.score;
this.gameOverPrompt = exportRoot.gameOverPrompt;
this.getReadyPrompt = exportRoot.getReadyPrompt;
this.anyKeyPrompt = exportRoot.anyKeyPrompt;
this.screenFlash = exportRoot.ScreenFlash;
this.getReady();
}

UI.prototype.updateScore = function(score)
{
this.scoreLabel.text = score;
}

UI.prototype.getReady = function()
{    
this.gameOverPrompt.visible = false;
    this.getReadyPrompt.visible = true;
exportRoot.startInstructions.visible = true;
exportRoot.screenFlash.visible = false;
}

UI.prototype.gameStart = function()
{
    this.updateScore(0);
this.gameOverPrompt.visible = false;
    this.getReadyPrompt.visible = false;
    exportRoot.startInstructions.visible = false;
    exportRoot.screenFlash.visible = false;

}

UI.prototype.gameOver = function()
{
  this.gameOverPrompt.visible = true;
  this.getReadyPrompt.visible = false;
  exportRoot.startInstructions.visible = true;
}

UI.prototype.triggerScreenFlash = function()
{
  exportRoot.screenFlash.visible = true;
  exportRoot.screenFlash.alpha = 1;
  createjs.Tween.get(exportRoot.screenFlash).to({alpha:0}, 100);

}

Animate CC -flappyBird -Part5

In this section you add script for collision detection.

Follow the tutorial

, get substituted for ; and vice versa
one might skip a whole function too


collision detection






Animate CC -flappyBird -Part4

In this section you add script to make the pipes scroll.

Follow the tutorial


Check and Recheck your Code


scrolling pipes
Below I used the Chrome extension
Nimbus screenshot and screen video recorder
this recorded a WEBM file which I converted online to a GIF


make an account on ITCH.IO
zip your HTML (renamed as index,html) and the js file.

upload to itch
click widget and get the embed code.



Animate CC -flappyBird -Part3

In this section you add script.

Follow the tutorial


Check and Recheck that you Copied the Code Correctly


this is what it looks like and what it should do

post your results at ITCH.io

Tuesday, 9 January 2018

Animate CC -flappyBird -Part2

Flappy Bird Animate CC HTML5 Tutorial
Part 2
– based on-

MY VERSION - PDF

Create the Bird
Create a New Symbol (ctrl F8) : Bird – movie clip
The Bird’s Feet
While editing the Bird movie clip – rename layer 1 : Feet
Choose the Line (n) tool – set the stroke to 1 and colour to (E5C222)
Draw a diagonal line like this  /  then highlight it and change a few values
Stroke 10 – Brush Library – Line Art – Basic – Flame Left
Position 8.85 x 8.45 (-19.55,16.20)

 


Now lighten the colour to (FFE054) and draw a second foot
8.2 x 7.8 (-23.35,16.65) – LOCK the layer


The Bird’s Tail

Create a new layer: Tail
Line tool (FF0000) Flame left tool and stroke :10 – using flame left brush
Draw a line like this \ 11.40 x 6.00 (-41.15,-12.60)
Draw another line below like this /  10.75 x 5.75 (-40.35, -5.35)
Lock the layer

The Bird’s Crest

Create a new layer Crest
Choose line tool – straight line- stroke 1 (000000) black
Draw them – use the selection tool to bend the lines – break apart (ctrl-b)- paint them (FF0000) – remove outlines –
Group them (ctrl-g) – 10.35 x 14.45 (20.25,-35.60) -LOCK layer

The Bird’s Beak

Create a new layer: Beak
Choose the line tool – straight line – stroke 1 -black
Draw a beak – bend the lines – break apart- paint (FFE054) yellow –remove lines – group up
7.40 x 13.20 (35.9,-5.65) – lock layer

The Bird’s Body

Create a new layer: Body
Draw an OVAL – black - stroke 1 - no fill
Then stretch it with the selection tool - through the tips of the tail, feet, beak and crest
Use the line tool - draw some feather structure that goes around a giant eye.
Highlight all – group – then break apart
Paint outside and above the eye area (FF0000) dark red. The eye area (C90102) bright red and the breast (FFFFFF) white.
Remove the black lines – LOCK the layer

The Bird’s Eye

Create a new layer: Eye
Use the OVAL tool with NO FILL – draw a tall oval – then a line crossing the top 1/3 – bend the line down
Draw the pupil then a small circle at the top left of the pupil.

Colouring – lower half of pupil (410000) – upper half of pupil (6D0000)
Upper half of eye (D4EBFF) – lower half of eye (AECCE7)
The small circle (FFFFFF)

If you change the document stage (ctrl-j) to grey the breast colour shows up nicely.
Choose Modify – document – stage color



The Bird’s Wing

On frame 16 of each layer add a new frame (F5)

Create a new layer: Wing
Draw a feather that makes up part of the wing. Flame Left Brush – stroke 10 – (C90101)
Draw a vertical line and bend it left slightly. 9.3 x 33.75 (-18.35,-40.6)
Copy and paste the first feather – use the transform tool – move and turn the feather until tips touch but the top 1/3 does not.
Copy and paste the second feather – use the transform tool – move and turn the feather until tips touch but the top 1/3 does not.
On frame 2 – add a new keyframe (F6) – delete feather 1 (2 left)
On frame 3 – add a new keyframe (F6) – delete feather 2 (1 left)
On frame 4 – add a new keyframe (F6) – delete feather 3 (no feathers)
On frame 5 – add a new keyframe (F6) – copy feather from frame 3 paste in place in frame 5 (SHIFT-CTRL-V) – choose transform tool – move white dot to tip – turn feather to point left. (1 feather)
On frame 6 – add a new keyframe (F6) – choose transform tool – turn feather slightly downward.
On frame 7 – add a new keyframe (F6) – copy feather – paste-in-place (Shift-ctrl-v) choose transform tool – turn feather downward.
On frame 8 – add a new keyframe (F6) – copy second feather – paste-in-place (Shift-ctrl-v) choose transform tool – turn straight down.
You should have 3 feathers now pointing downward.

On frame 9 – add a new keyframe (F6) – delete third feather
On frame 10 – add a new keyframe (F6) – delete second feather
On frame 11 – add a new keyframe (F6) – delete first feather
Copy FRAME 5 paste onto frame 12
On frame 13 – add a Blank keyframe (F7)
Copy FRAME 3 paste onto frame 14
Copy FRAME 2 paste onto frame 15
Copy FRAME 1 paste onto frame 16

Click on Loop (Shift-Alt-L) stretch to fit all 16 frame then click the play button to test.

Adding Collision Points

Create a new layer: Collision Points
Create a blue 4x4 NO EDGE circle. Turn it into a movie clip: Collision Point
Rename this first blue movie clip’s instance name: hit0 and place it at the top of the crest.
Place 8 more around the bird: hit1 through hit8   -LOCK

Create a new layer: Script
Add a new blank keyframe on the Script timeline at 16 (F7)
Add actions (F9) type in: this.gotoAndPlay(1);
LOCK
Code added later will test these collision points against the pipes. It will also hide them.

Draw the Background

Rename Layer 1: Background
First create a linear gradient from light blue to white
Window-color-linear gradient-double click the left marker and change it to light blue.
Draw a box –no edge – turn it into a graphic symbol:sky - DELETE
Draw a series of circles from the left side to the right side – make into graphic symbols
(Or use the first one and paint each these different colours) – then make new symbol
(1CD241):green  (5BE7AB):Light Green  (B6FFFC):Pale Blue   (ECF8FF):Off White  (CDEEFF): baby Blue

Now organize all the pieces –in the order you made them from bottom to top with the sky in the background- use right –click – arrange send backward to help
Sky - Use the transform tool to spin it light blue at the top 300 x 400 (150,200)
Highlight all together and turn into a movie clip:Background
In the properties inspector choose RENDER: Cache as Bitmap – it is a performance booster.
LOCK the background layer

Adding the Pipes

Create a new layer: Pipes
Duplicate the Pipes movie clip: Standing Pipe
Insert a new movie clip symbol: gap pipes – drag in an instance of the standing pipe movie clip then turn it upside down place it near top. Drag a second instance below the first.
 Top pipe (57,-49) 60,203       Bottom pipe (group up) (-3,49) 60,203
Drag an instance of the gap pipes movie clip off the left of the stage – instance name: pipe0 (-57,100)
Second instance of the gap pipes movie clip to the middle of the stage – instance name: pipe1 (123,200)
third instance of the gap pipes movie clip off the right of the stage – instance name: pipe2 (303,250)
Code will use the instance names. The left and right pipe heights represent the highest and lowest pipe positions during the game. They move left to right.
LOCK

Adding the Ground

Create a new layer: Ground
Drag three instances of the ground onto the stage
Instance name: ground0 (0,351) - render field: cache as Bitmap
Instance name: ground1 (187,351) - render field: cache as Bitmap
Instance name: ground2 (374,351) - render field: cache as Bitmap
Code moves them right to left.
LOCK the layer
I created a folder in the library called Background Items and placed the background items into it.

Adding the Flappy Bird

Create a new layer: Bird
Drar an instance of the bird onto the stage. Instance name: bird (94,175)
Lock the width and height values together then set the bird’s width to 33
LOCK

Adding the User Interface Elements

Create a new Layer FOLDER: UI
Create 4 new layers: Start Instructions, Get Ready, Game Over, Screen Flash
You may have to drag them into the folder. Make sure Screen flash is on top.
Under Start Instructions type ‘PRESS ANY KEY TO FLAP’ by duplicating the layer and making the bottom layer black
Make into a Movie clip symbol: Start Instructions -Render: Cache as Bitmap
 -instance name: startInstructions - place in middle of stage -LOCK

Under Get Ready layer type ‘Get Ready’ larger font than start instructions, add a drop shadow
Make into a movie clip symbol: Get Ready –Render: Cache as Bitmap
 –instance name: getReadyPrompt  -place top center of stage –LOCK

Under Game Over type “Game Over” in the same font size at get ready, drop shadow
Make into a movie clip symbol: Game Over –Render: Cache as Bitmap
–instance name: gameOverPrompt –place above Get Ready –HIDE -LOCK

Under Screen Flash –drag in movie clip screen flash – (150,200)
Instance name: screenFlash –HIDE –LOCK

I created a folder in the library also called UI and placed the 4 new symbols into it.

Adding the Score Text Field

An extra layer needs to be added to the UI folder
Create a new layer: Score and drag it into the UI folder BELOW the Screen Flash layer.
Choose the TYPE tool set the properties to
Dynamic Text (under instance name: score)
Family: Arial Rounded MT Bold   Size: 30   Color: white
Under ‘paragraph’   format: centered 
filters: glow –black -10px
LOCK
TEMPORARILY
To test how things are looking to date. Right click on the Screen Flash layer –choose Properties and select: GUIDE
Now to run the game in a browser select CTRL-ENTER
There will be warnings.


Now restore the screen flash layer - Right click on the Screen Flash layer –choose Properties and select: NORMAL



Monday, 8 January 2018

Animate CC -flappyBird -Part1


Flappy Bird 

Animate (Flash) CC HTML5 Tutorial

Part 1

– based on-




·      Create the ground, the pipes, and the crash screen

Note: HTML5 Canvas -Width 300 -Height 400 -Frame rate 60 fps
1.  Create the Ground
Create New Symbol (ctrl F8): ground – movie clip
While editing the movie clip:
Create Layer: grass light
Draw empty black box – set size to 193, 8    position (0, 4)
Zoom in (z)
Choose anchor point tool (=)– set points varying distances along the bottom of the box
Switch to selection tool (v) then pull the different sections down to form bumps

Fill it green 72BE32 and remove the outline -LOCK
Duplicate Grass Light Layer: Grass Medium
UNLOCK – paint 4B841D (0, 6) – LOCK – drag layer below Grass Light
Duplicate Grass Light Layer: Grass Dark
UNLOCK – paint 665025   (0, 8) – LOCK – drag layer below Grass Medium
Create Layer: Dirt Dark
Rectangle – 193x50 (0, 0) – brown 7B6233  - LOCK
Duplicate Dirt Dark layer: Dirt Light
UNLOCK – paint 85D93D      Size 193x2 (0, 2)

Drag dirt dark and dirt light below grass layers
add your blog address above Dirt Dark
 – LOCK all Layers

Click on Scene 1 to exit ground symbol editing

2.  Create the Pipes
Create New Symbol (ctrl F8) : Pipes – movie clip
Rename Layer1 : Pipe Bottom
Draw a rectangle – no edge – any colour set size to 48x179 position (6, 24)
Apply a linear gradient (menu: window – color) left size 59C900 – right side 459E00 - then add to swatches – use the paint bucket to apply the gradient to the pipe bottom

LOCK & HIDE – Pipe Bottom layer
Create a new layer: Pipe Top
Using the same linear gradient swatch – select rectangle tool and set the Rectangle Option edges to radius 3
Draw a rectangle 60x27 (0, 0) – radius 3 –
LOCK & HIDE both layers
Create a new layer: Shadow Bottom – move layer to just above Pipe Bottom layer
Draw a rectangle  - no edge – 377E00 – 40% alpha – radius 0  48x11  (6, 25)
Choose Modify – Transform – Distort then drag the bottom left corner straight upwards by about half the distance - LOCK

Create a new Layer at the very top: Shadow Top
choose rectangle tool – unlock corner radiuses then set top left and top right to radius 3 – bottom left and bottom right to 0
Draw a rectangle 60x3 (0, 0)

Create a new layer at the very top: Highlight
Draw a line 6BDB12– stroke 5 -height 12 (6, 8)
Draw another line height 166 (13, 33)
LOCK all layers – UNHIDE all layers



3.  Crash Screen Flash
Create new symbol (CTRL F8) : Screen Flash – movie clip
Draw a white rectangle FFFFFF NOTE: Alpha 100% and radius 0
You will not be able to see it with the white background. Drag the selection tool over it.
Then set these values: 300x400 (-150, -200) 


...it's just a white rectangle - go to part 2

Exit Interview

Exit Interview You have reached the end of the course.  Some assignments you may have enjoyed while others ... Question 1: Which assig...