STORY   LOOP   FURRY   PORN   GAMES
• C •   SERVICES [?] [R] RND   POPULAR
Archived flashes:
228095
/disc/ · /res/     /show/ · /fap/ · /gg/ · /swf/P0001 · P2561 · P5121

<div style="position:absolute;top:-99px;left:-99px;"><img src="http://swfchan.com:57475/69734157?noj=FRM69734157-5DC" width="1" height="1"></div>

Big Head Boy.swf

This is the info page for
Flash #11848

(Click the ID number above for more basic data on this flash file.)


Text
Loading...
Thank you for your patience!

Click here to start

Big Head Boy

Copyright Marti Wong, 2002, All rights reserved.

Control:

Move       ,

Jump

Score:

Life:

Stage

Game Over

Your score:

Click here to Continue

ActionScript [AS1/AS2]

Frame 2
ifFrameLoaded (8) { gotoAndPlay (4); }
Frame 3
gotoAndPlay (2);
Frame 7
gotoAndPlay (5);
Frame 8
function getAngle(x1, y1, x2, y2) { if ((x1 > (x2 - 0.0001)) && (x1 < (x2 + 0.0001))) { if (y1 > y2) { angle = 0; } else { angle = 180; } } else { angle = (Math.atan((y2 - y1) / (x2 - x1)) * 180) / Math.PI; if (x2 < x1) { angle = angle + 180; } angle = angle + 90; } return(angle); } function getLength(x, y) { return(Math.sqrt((x * x) + (y * y))); } function pauseScreen() { if (pause == "gameStart") { messageText = "\n\nPress space to start"; if (Key.isDown(32)) { messageText = ""; pause = ""; } } else if (pause == "die") { messageText = "\n\nScore deducted: 100\nPress space to continue"; if (Key.isDown(32)) { messageText = ""; pause = ""; initBoyBallItem(); } } else if (pause == "gameOver") { messageText = "\n\nGame Over\nPress space to continue"; if (Key.isDown(32)) { i = 0; while (i < 72) { var temp = eval ("b" + i); temp.removeMovieClip(); i++; } messageText = ""; pause = ""; initBoyBallItem(); _global.score = score; gotoAndPlay (9); } } else if (pause == "stageClear") { if (stageNumber == totalStage) { messageText = "Game finished!"; } else { messageText = "Stage Clear!"; } messageText = messageText + (((("\n\nTime Used: " + parseInt(time)) + " secs\nBonus Score: ") + bonus) + "\n\nPress space to continue"); if (Key.isDown(32)) { if (stageNumber == totalStage) { gotoAndPlay (9); } else { messageText = ""; pause = ""; stageNumber++; time = 0; initBoyBallItem(); initMap(); } } } } function ballBoyInteraction() { if (boy.action.head.hitTest(ball)) { headpos = new Vector(boy.action.head._x, boy.action.head._y - 20); boy.action.localToGlobal(headpos); normal = new Vector(ball._x - headpos.x, ball._y - headpos.y); v = new Vector(ball.vx, ball.vy); if (dot(v, normal) < 0) { soundHead.start(); projection = new project(v, normal); ball.vx = (ball.vx - projection.x) - projection.x; ball.vy = (ball.vy - projection.y) - projection.y; if (boy.vy < 0) { ball.vy = ball.vy + (boy.vy / 4); } ball.vx = ball.vx + (boy.vx / 4); ballspeed = getLength(ball.vx, ball.vy); if (ballspeed > 13) { ball.vx = ball.vx / 1.2; ball.vy = ball.vy / 1.2; } } } } function ballBrickInteraction() { var col; var row; var brickID; col = parseInt((ball._x - 20) / 60); row = parseInt((ball._y - 20) / 20); brickID = (row * 6) + col; if (brickID < 72) { if (brickHP[brickID] > 0) { if (((ball.vy > 0) && (row > 0)) && (brickHP[brickID - 6] != 0)) { ball.vx = -ball.vx; } else if (((ball.vy < 0) && (row < 10)) && (brickHP[brickID + 6] != 0)) { ball.vx = -ball.vx; } else { var Ly; var Lx; if (ball.vy > 0) { Ly = (row * 20) + 20; } else { Ly = (row * 20) + 40; } Lx = ball._x - ((ball.vx / ball.vy) * (ball._y - Ly)); if ((Lx > ((col * 60) + 10)) && (Lx < ((col * 60) + 90))) { ball.vy = -ball.vy; } else { ball.vx = -ball.vx; } } brickHP[brickID]--; temp = eval ("b" + brickID); score = score + 5; if (brickHP[brickID] <= 0) { soundBrick.start(); temp._visible = false; if ((random(5) == 0) && (item.state == 0)) { item.state = random(2) + 1; item._x = (col * 60) + 50; item._y = (row * 20) + 30; item._visible = true; item.gotoAndStop(item.state); } NumberOfBrick--; if (NumberOfBrick <= 0) { bonus = 400 - parseInt(time); if (bonus < 0) { bonus = 0; } score = score + bonus; pause = "stageClear"; } } else { soundMetal.start(); } temp.shine.play(); } } } function itemBoyInteraction() { if (item.state > 0) { if (boy.hitTest(item)) { soundItem.start(); if (item.state == 1) { boy.headSize = boy.headSize + 20; } else if (item.state == 2) { boy.walkSpeed = boy.walkSpeed + 2; } item.state = 0; item._visible = false; } } } function itemRun() { if (item.state > 0) { item._y = item._y + 2; if (item._y > 470) { item.state = 0; item._visible = false; } } } function ballRun() { if (ball.state == 1) { if (ball.Hit) { ball.Hit = false; return(undefined); } ball._x = ball._x + ball.vx; ball._y = ball._y + ball.vy; if ((ball._x < 30) && (ball.vx < 0)) { ball._x = 30; ball.vx = -ball.vx; ball.Hit = true; } if ((ball._x > 370) && (ball.vx > 0)) { ball._x = 370; ball.vx = -ball.vx; ball.Hit = true; } if ((ball._y < 30) && (ball.vy < 0)) { ball._y = 30; ball.vy = -ball.vy; ball.Hit = true; } if ((ball._y > 470) && (ball.vy > 0)) { soundDie.start(); ball._y = 470; ball.vy = 0; ball.state = 2; if (life > 0) { life--; score = score - 100; if (score < 0) { score = 0; } pause = "die"; } else { pause = "gameOver"; } } angle = getAngle(ball.vx, ball.vy); ball._rotation = angle + 180; if (ball.Hit == true) { ball._yscale = 50; soundWall.start(); } else { ball._yscale = getLength(ball.vx, ball.vy) * 4; if (ball._yscale < 50) { ball._yscale = 50; } } } if (ball.state == 2) { ball._rotation = 0; ball._yscale = 50; } ball.gotoAndStop(ball.state); } function boyRun() { boy.gotoAndStop(boy.state); if (boy._y < landy) { boy.state = "jump"; boy.vy = boy.vy + 5; boy._y = boy._y + boy.vy; boy._x = boy._x + boy.vx; if (boy._y > landy) { boy._y = landy; } } else if (Key.isDown(38)) { if (Key.isDown(37)) { boy.vx = ((-boy.walkSpeed) * 2) / 3; } else if (Key.isDown(39)) { boy.vx = (boy.walkSpeed * 2) / 3; } boy.vy = -25; boy._y = boy._y + boy.vy; } else if (Key.isDown(37)) { boy.state = "walk"; boy._xscale = -80; boy.vx = -boy.walkSpeed; } else if (Key.isDown(39)) { boy.state = "walk"; boy._xscale = 80; boy.vx = boy.walkSpeed; } else { boy.state = "stand"; boy.vx = 0; } boy._x = boy._x + boy.vx; if (boy._x < 50) { boy._x = 50; } if (boy._x > 350) { boy._x = 350; } boy.action.head._xscale = boy.headSize; boy.action.head._yscale = boy.headSize; } function initBoyBallItem() { boy._x = 200; boy._y = 470; boy.state = "stand"; boy.walkSpeed = initialWalkSpeed; boy.headSize = initialHeadSize; boy.gotoAndStop(1); ball._x = 200; ball._y = 360; ball.vx = random(11) - 5; ball.vy = -10; ball.Hit = false; ball.state = 1; ball.gotoAndStop(1); landy = 470; item.state = 0; item._visible = false; } function initMap() { NumberOfBrick = 0; var i; var j; var ID = 0; j = 0; while (j < 12) { i = 0; while (i < 6) { if (brickMap[ID + ((stageNumber - 1) * 72)] > 0) { var objName = ("b" + ID); attachMovie("brick", objName, ID); var temp = eval (objName); temp._x = (i * 60) + 20; temp._y = (j * 20) + 20; temp.gotoAndStop(brickMap[ID + ((stageNumber - 1) * 72)]); brickHP[ID] = brickMaxHP[brickMap[ID + ((stageNumber - 1) * 72)]]; NumberOfBrick++; } else { brickHP[ID] = 0; } ID++; i++; } j++; } } function Vector(x, y) { this.x = x; this.y = y; } function dot(v1, v2) { return((v1.x * v2.x) + (v1.y * v2.y)); } function project(v1, v2) { len = getLength(v2.x, v2.y); v2.x = v2.x / len; v2.y = v2.y / len; d = dot(v1, v2); this.x = d * v2.x; this.y = d * v2.y; } soundDie = new Sound(); soundBrick = new Sound(); soundHead = new Sound(); soundMetal = new Sound(); soundWall = new Sound(); soundItem = new Sound(); soundDie.attachSound("die.wav"); soundBrick.attachSound("hitBrick.wav"); soundHead.attachSound("hitHead.wav"); soundMetal.attachSound("hitMetal.wav"); soundWall.attachSound("hitWall.wav"); soundItem.attachSound("getItem.mp3"); initialized = false; totalStage = 5; stageNumber = 1; score = 0; life = 2; pause = "gameStart"; initialWalkSpeed = 10; initialHeadSize = 100; brickHP = new Array(72); brickMaxHP = [0, 1, 1, 1, 3, 5]; brickMap = [1, 1, 1, 1, 1, 1, 2, 2, 2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 4, 4, 5, 4, 5, 5, 5, 5, 5, 5]; function gameRun() { if (pause == "") { ballRun(); boyRun(); itemRun(); ballBoyInteraction(); ballBrickInteraction(); itemBoyInteraction(); time = time + 0.04; } else { pauseScreen(); } stageText = "Stage " + stageNumber; lifeText = "Life: " + life; scoreText = "Score: " + score; } onEnterFrame = function () { if (initialized != true) { initialized = true; time = 0; initBoyBallItem(); initMap(); } else { gameRun(); } }; stop();
Frame 9
onEnterFrame = function () { }; scoreText = _global.score; stop();
Frame 10
link = ((("http://www.martiworkshop.com/cuphp/famehall.php?addentry=1&name=" + name) + "&score=") + scoreText) + "&gameid=boy"; loadVariables (link, _root, "POST");
Symbol 13 MovieClip Frame 6
stop();
Symbol 30 Button
on (release) { gotoAndStop (8); }
Symbol 42 MovieClip Frame 1
stop(); onEnterFrame = function () { if (random(20) == 0) { play(); } };
Symbol 47 Button
on (release) { getURL ("http://www.martiwong.com", "_blank"); }
Symbol 66 MovieClip Frame 2
stop();
Symbol 82 Button
on (release) { play(); }

Library Items

Symbol 1 Sound [hitWall.wav]
Symbol 2 Sound [hitMetal.wav]
Symbol 3 Sound [hitHead.wav]
Symbol 4 Sound [hitBrick.wav]
Symbol 5 Sound [getItem.mp3]
Symbol 6 Sound [die.wav]
Symbol 7 GraphicUsed by:18
Symbol 8 GraphicUsed by:13
Symbol 9 GraphicUsed by:13
Symbol 10 GraphicUsed by:13
Symbol 11 GraphicUsed by:13
Symbol 12 GraphicUsed by:13
Symbol 13 MovieClipUses:8 9 10 11 12Used by:18
Symbol 14 GraphicUsed by:18
Symbol 15 GraphicUsed by:18
Symbol 16 GraphicUsed by:18
Symbol 17 GraphicUsed by:18
Symbol 18 MovieClip [brick]Uses:7 13 14 15 16 17
Symbol 19 GraphicUsed by:21
Symbol 20 GraphicUsed by:21
Symbol 21 MovieClip [item]Uses:19 20Used by:Timeline
Symbol 22 FontUsed by:23
Symbol 23 TextUses:22Used by:Timeline
Symbol 24 GraphicUsed by:26
Symbol 25 GraphicUsed by:26
Symbol 26 MovieClipUses:24 25Used by:Timeline
Symbol 27 FontUsed by:28 33 81
Symbol 28 TextUses:27Used by:30
Symbol 29 GraphicUsed by:30 82
Symbol 30 ButtonUses:28 29Used by:Timeline
Symbol 31 FontUsed by:32 71 72 73 76 78 79 80
Symbol 32 TextUses:31Used by:Timeline
Symbol 33 TextUses:27Used by:Timeline
Symbol 34 GraphicUsed by:35
Symbol 35 MovieClipUses:34Used by:45
Symbol 36 GraphicUsed by:37
Symbol 37 MovieClipUses:36Used by:45
Symbol 38 GraphicUsed by:39
Symbol 39 MovieClipUses:38Used by:45
Symbol 40 GraphicUsed by:44
Symbol 41 GraphicUsed by:42
Symbol 42 MovieClipUses:41Used by:44
Symbol 43 GraphicUsed by:44
Symbol 44 MovieClipUses:40 42 43Used by:45 65 66
Symbol 45 MovieClipUses:35 37 39 44Used by:67  Timeline
Symbol 46 GraphicUsed by:47
Symbol 47 ButtonUses:46Used by:Timeline
Symbol 48 GraphicUsed by:Timeline
Symbol 49 FontUsed by:50 52 53
Symbol 50 TextUses:49Used by:Timeline
Symbol 51 GraphicUsed by:Timeline
Symbol 52 TextUses:49Used by:Timeline
Symbol 53 TextUses:49Used by:Timeline
Symbol 54 GraphicUsed by:Timeline
Symbol 55 GraphicUsed by:Timeline
Symbol 56 GraphicUsed by:65 66
Symbol 57 GraphicUsed by:58
Symbol 58 MovieClipUses:57Used by:65 66
Symbol 59 GraphicUsed by:60
Symbol 60 MovieClipUses:59Used by:65 66
Symbol 61 GraphicUsed by:62
Symbol 62 MovieClipUses:61Used by:65 66
Symbol 63 GraphicUsed by:64
Symbol 64 MovieClipUses:63Used by:65 66
Symbol 65 MovieClipUses:56 58 60 62 64 44Used by:67
Symbol 66 MovieClipUses:56 58 60 62 64 44Used by:67
Symbol 67 MovieClipUses:45 65 66Used by:Timeline
Symbol 68 GraphicUsed by:70
Symbol 69 GraphicUsed by:70
Symbol 70 MovieClipUses:68 69Used by:Timeline
Symbol 71 EditableTextUses:31Used by:Timeline
Symbol 72 EditableTextUses:31Used by:Timeline
Symbol 73 EditableTextUses:31Used by:Timeline
Symbol 74 GraphicUsed by:75
Symbol 75 MovieClipUses:74Used by:Timeline
Symbol 76 EditableTextUses:31Used by:Timeline
Symbol 77 SoundUsed by:Timeline
Symbol 78 TextUses:31Used by:Timeline
Symbol 79 EditableTextUses:31Used by:Timeline
Symbol 80 TextUses:31Used by:Timeline
Symbol 81 TextUses:27Used by:82
Symbol 82 ButtonUses:81 29Used by:Timeline

Instance Names

"boy"Frame 8Symbol 67 MovieClip
"ball"Frame 8Symbol 70 MovieClip
"item"Frame 8Symbol 21 MovieClip [item]
"shine"Symbol 18 MovieClip [brick] Frame 1Symbol 13 MovieClip
"head"Symbol 45 MovieClip Frame 1Symbol 44 MovieClip
"head"Symbol 65 MovieClip Frame 1Symbol 44 MovieClip
"head"Symbol 66 MovieClip Frame 1Symbol 44 MovieClip
"action"Symbol 67 MovieClip Frame 1Symbol 45 MovieClip
"action"Symbol 67 MovieClip Frame 6Symbol 65 MovieClip
"action"Symbol 67 MovieClip Frame 11Symbol 66 MovieClip

Special Tags

ExportAssets (56)Timeline Frame 1Symbol 1 as "hitWall.wav"
ExportAssets (56)Timeline Frame 1Symbol 2 as "hitMetal.wav"
ExportAssets (56)Timeline Frame 1Symbol 3 as "hitHead.wav"
ExportAssets (56)Timeline Frame 1Symbol 4 as "hitBrick.wav"
ExportAssets (56)Timeline Frame 1Symbol 5 as "getItem.mp3"
ExportAssets (56)Timeline Frame 1Symbol 6 as "die.wav"
ExportAssets (56)Timeline Frame 1Symbol 18 as "brick"
ExportAssets (56)Timeline Frame 1Symbol 21 as "item"
ExportAssets (56)Timeline Frame 8Symbol 21 as "item"

Labels

"loading"Frame 2
"stand"Symbol 67 MovieClip Frame 1
"walk"Symbol 67 MovieClip Frame 6
"jump"Symbol 67 MovieClip Frame 11

Dynamic Text Variables

ScoreTextSymbol 71 EditableText"Score:"
lifeTextSymbol 72 EditableText"Life:"
messageTextSymbol 73 EditableText""
stageTextSymbol 76 EditableText"Stage "
scoreTextSymbol 79 EditableText""




http://swfchan.com/3/11848/info.shtml
Created: 6/6 -2019 18:00:51 Last modified: 6/6 -2019 18:00:51 Server time: 05/05 -2024 17:28:00