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

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

Four Square.swf

This is the info page for
Flash #72052

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


Text
FLASH

ADDICTING

GAMES

FLASH

ADDICTING

<p align="center"><font face="Myriad Pro" size="20" color="#ffffff" letterSpacing="0.000000" kerning="1"><b>1 Player</b></font></p>

<p align="center"><font face="Myriad Pro" size="20" color="#ffffff" letterSpacing="0.000000" kerning="1"><b>2 Player</b></font></p>

The object of Four Square is to
make 2 by 2 groups of squares.
For each 2 x 2 group you
complete, you score points.
Players take turns filling in a
single box.  The game ends
when all boxes are filled.

<p align="justify"><font face="Myriad Pro" size="12" color="#ffffff" letterSpacing="0.000000" kerning="1"><b>0</b></font></p>

<p align="justify"><font face="Myriad Pro" size="12" color="#ffffff" letterSpacing="0.000000" kerning="1"><b>0</b></font></p>

<p align="left"><font face="Myriad Pro" size="12" color="#ffffff" letterSpacing="0.000000" kerning="1"><b>Player 1:</b></font></p>

<p align="left"><font face="Myriad Pro" size="12" color="#ffffff" letterSpacing="0.000000" kerning="1"><b>Player 2:</b></font></p>

<p align="center"><font face="Myriad Pro" size="20" color="#ffffff" letterSpacing="0.000000" kerning="1"><b>GAME OVER</b></font></p>

<p align="center"><font face="Myriad Pro" size="16" color="#ffffff" letterSpacing="0.000000" kerning="1"><b>Start &nbsp;New Game</b></font></p>

ActionScript [AS1/AS2]

Frame 1
stop(); onEnterFrame = function () { _root.pbar._width = 320 * (_root.getBytesLoaded() / _root.getBytesTotal()); if (_root.getBytesLoaded() == _root.getBytesTotal()) { delete onEnterFrame; play(); } };
Instance of Symbol 21 MovieClip in Frame 1
on (release) { getURL ("http://www.addicting-flash-games.com", "_blank"); }
Frame 2
stop(); var players = 0; var player = 0; var boxes = []; var turns = 0;
Instance of Symbol 21 MovieClip in Frame 2
on (release) { getURL ("http://www.addicting-flash-games.com", "_blank"); }
Instance of Symbol 23 MovieClip in Frame 2
on (press) { _root.players = 1; _root.gotoAndStop("game"); }
Instance of Symbol 25 MovieClip in Frame 2
on (press) { _root.players = 2; _root.gotoAndStop("game"); }
Frame 3
function boxPress(x, y, cpu) { if (((_root.players == 2) || (_root.player == 1)) || (cpu)) { if (!_root.boxes[x][y].player) { _root.boxes[x][y].player = _root.player; _root.boxes[x][y].gotoAndStop(_root.player + 1); _root.checkPoints(_root.player, x, y, false); _root.turns--; if (!_root.turns) { return(_root.gotoAndStop("over")); } _root.player = ((_root.player == 1) ? 2 : 1); if ((_root.players == 1) && (_root.player == 2)) { setTimeout(_root.aiPlay, 500); } } } } function checkPoints(p, x, y, checkonly) { var _local7 = [0, 5, 15, 30, 50]; var _local6 = 0; var _local5 = [-1, 1]; j = 0; while (j < 2) { k = 0; while (k < 2) { if (((((_root.boxes[x][y].player == p) || (!_root.boxes[x][y].player)) && (_root.boxes[x + _local5[j]][y + _local5[k]].player == p)) && (_root.boxes[x + _local5[j]][y].player == p)) && (_root.boxes[x][y + _local5[k]].player == p)) { _local6++; } k++; } j++; } if (!checkonly) { _root["score" + p].text = int(_root["score" + p].text) + _local7[_local6]; } return(_local7[_local6]); } function aiPlay() { var _local10 = random(12); var _local9 = random(12); var _local5 = 0; var _local8 = 0; var _local4; var _local7 = -1; var _local6 = -1; pass = 0; while (pass <= 3) { var _local3 = _local10; var _local2 = _local9; _local5 = 0; var _local11 = false; do { if (_root.boxes[_local3][_local2] && (!_root.boxes[_local3][_local2].player)) { switch (pass) { case 0 : _local4 = checkPoints(_root.player, _local3, _local2, true); if (_local4 > _local5) { _local7 = _local3; _local6 = _local2; _local5 = _local4; } break; case 1 : _local4 = checkPoints(((_root.player == 1) ? 2 : 1), _local3, _local2, true); if (_local4 > _local5) { _local7 = _local3; _local6 = _local2; _local5 = _local4; } break; case 2 : _local4 = 0; if (_root.boxes[_local3 - 1][_local2].player == _root.player) { _local4++; } if (_root.boxes[_local3][_local2 - 1].player == _root.player) { _local4++; } if (_root.boxes[_local3 + 1][_local2].player == _root.player) { _local4++; } if (_root.boxes[_local3][_local2 + 1].player == _root.player) { _local4++; } if ((_root.boxes[_local3 - 1][_local2 - 1].player == _root.player) && ((_root.boxes[_local3 - 1][_local2].player == _root.player) || (_root.boxes[_local3][_local2 - 1].player == _root.player))) { _local4++; } if ((_root.boxes[_local3 - 1][_local2 + 1].player == _root.player) && ((_root.boxes[_local3 - 1][_local2].player == _root.player) || (_root.boxes[_local3][_local2 + 1].player == _root.player))) { _local4++; } if ((_root.boxes[_local3 + 1][_local2 - 1].player == _root.player) && ((_root.boxes[_local3][_local2 - 1].player == _root.player) || (_root.boxes[_local3 + 1][_local2].player == _root.player))) { _local4++; } if ((_root.boxes[_local3 + 1][_local2 + 1].player == _root.player) && ((_root.boxes[_local3][_local2 + 1].player == _root.player) || (_root.boxes[_local3 + 1][_local2].player == _root.player))) { _local4++; } if (_local4 > _local8) { _local7 = _local3; _local6 = _local2; _local8 = _local4; } break; case 3 : if (_root.boxes[_local3][_local2].player) { break; } return(boxPress(_local3, _local2, true)); } } _local3++; if (_local3 >= 12) { _local3 = 0; _local2++; } if (_local2 >= 12) { _local2 = 0; } } while ((_local2 != _local9) || (_local3 != _local10)); if ((pass >= 1) && ((_local7 >= 0) || (_local6 >= 0))) { return(boxPress(_local7, _local6, true)); } pass++; } _root.player = ((_root.player == 1) ? 2 : 1); } stop(); var player = 1; var boxes = []; var turns = 0; x = 0; while (x < 12) { if (!boxes[x]) { boxes[x] = []; } y = 0; while (y < 12) { _root.turns++; if (!boxes[x][y]) { boxes[x][y] = game.attachMovie("Box", (("box" + x) + "x") + y, game.getNextHighestDepth()); } boxes[x][y].player = 0; boxes[x][y].boxX = x; boxes[x][y].boxY = y; boxes[x][y]._x = (4 + (x * 30)) + ((x > 0) ? (x * 2) : 0); boxes[x][y]._y = (4 + (y * 30)) + ((y > 0) ? (y * 2) : 0); boxes[x][y]._width = 30; boxes[x][y]._height = 30; boxes[x][y].gotoAndStop(1); y++; } x++; }
Frame 4
stop();
Instance of Symbol 36 MovieClip in Frame 4
on (press) { _root.gotoAndStop("start"); }
Symbol 5 MovieClip [Box] Frame 1
this.onPress = function () { _root.boxPress(this.boxX, this.boxY, false); }; stop();
Symbol 5 MovieClip [Box] Frame 2
stop();
Symbol 5 MovieClip [Box] Frame 3
stop();

Library Items

Symbol 1 GraphicUsed by:5
Symbol 2 GraphicUsed by:5
Symbol 3 GraphicUsed by:5
Symbol 4 GraphicUsed by:5
Symbol 5 MovieClip [Box]Uses:1 2 3 4
Symbol 6 GraphicUsed by:7
Symbol 7 MovieClipUses:6Used by:Timeline
Symbol 8 GraphicUsed by:Timeline
Symbol 9 GraphicUsed by:10
Symbol 10 MovieClipUses:9Used by:Timeline
Symbol 11 FontUsed by:12 18
Symbol 12 TextUses:11Used by:21
Symbol 13 FontUsed by:14 19 22 24 29 30 31 32 33 34 35
Symbol 14 TextUses:13Used by:21
Symbol 15 GraphicUsed by:21
Symbol 16 FontUsed by:17 22 24 32 33 34 35
Symbol 17 TextUses:16Used by:21
Symbol 18 TextUses:11Used by:21
Symbol 19 TextUses:13Used by:21
Symbol 20 GraphicUsed by:21
Symbol 21 MovieClipUses:12 14 15 17 18 19 20Used by:Timeline
Symbol 22 EditableTextUses:13 16Used by:23
Symbol 23 MovieClipUses:22Used by:Timeline
Symbol 24 EditableTextUses:13 16Used by:25
Symbol 25 MovieClipUses:24Used by:Timeline
Symbol 26 GraphicUsed by:27
Symbol 27 MovieClipUses:26Used by:Timeline
Symbol 28 GraphicUsed by:Timeline
Symbol 29 TextUses:13Used by:Timeline
Symbol 30 EditableTextUses:13Used by:Timeline
Symbol 31 EditableTextUses:13Used by:Timeline
Symbol 32 EditableTextUses:13 16Used by:Timeline
Symbol 33 EditableTextUses:13 16Used by:Timeline
Symbol 34 EditableTextUses:13 16Used by:Timeline
Symbol 35 EditableTextUses:13 16Used by:36
Symbol 36 MovieClipUses:35Used by:Timeline

Instance Names

"pbar"Frame 1Symbol 10 MovieClip
"game"Frame 3Symbol 27 MovieClip
"score1"Frame 3Symbol 30 EditableText
"score2"Frame 3Symbol 31 EditableText

Special Tags

FileAttributes (69)Timeline Frame 1Access local files only, Metadata not present, AS1/AS2.
ExportAssets (56)Timeline Frame 1Symbol 5 as "Box"

Labels

"start"Frame 2
"game"Frame 3
"over"Frame 4




http://swfchan.com/15/72052/info.shtml
Created: 8/4 -2019 23:23:35 Last modified: 8/4 -2019 23:23:35 Server time: 05/11 -2024 09:19:56