Section 1
//jeu_2 (ShifumiFayeCS5_fla.jeu_2)
package ShifumiFayeCS5_fla {
import flash.events.*;
import flash.display.*;
import flash.text.*;
import flash.utils.*;
import flash.net.*;
import adobe.utils.*;
import flash.accessibility.*;
import flash.errors.*;
import flash.external.*;
import flash.filters.*;
import flash.geom.*;
import flash.media.*;
import flash.printing.*;
import flash.profiler.*;
import flash.sampler.*;
import flash.system.*;
import flash.ui.*;
import flash.xml.*;
public dynamic class jeu_2 extends MovieClip {
public var CacheS:MovieClip;
public var Start:SimpleButton;
public var feuille:SimpleButton;
public var textMC:MovieClip;
public var pierre:SimpleButton;
public var btOk:SimpleButton;
public var YouHer:MovieClip;
public var Result:TextField;
public var ciseaux:SimpleButton;
public var gameRunning:Boolean;
public var pointspc:int;
public var StrVid;
public var res;
public var video;
public var habitMax;
public var ciseauxVideo;
public var pierreVideo;
public var feuilleVideo;
public var gagneVideo;
public var perdVideo;
public var nulVideo;
public var changementHabit;
public var habit;
public var tableau;
public var choix:String;
public var affBool:Boolean;
public var myTimer:Timer;
public var timerOK:Timer;
public function jeu_2(){
addFrameScript(0, frame1);
}
public function Start_Click(_arg1:MouseEvent){
if (!gameRunning){
startGame();
YouHer.visible = false;
pointspc = 0;
Start.visible = false;
video.addEventListener(Event.ENTER_FRAME, listenerObject);
};
}
public function startGame(){
changementHabit = 0;
habit = 0;
textMC.visible = false;
gameRunning = true;
pierre.visible = false;
feuille.visible = false;
ciseaux.visible = false;
StrVid = "bonjour";
res = "";
YouHer.visible = (CacheS.visible = (Result.visible = (btOk.visible = false)));
video = new bonjour();
fixVideo();
}
public function timerOK_Tick(_arg1:TimerEvent){
timerOK.stop();
CacheS.visible = (YouHer.visible = (Result.visible = (btOk.visible = false)));
this.removeChild(video);
if (StrVid == "gagne"){
video = new (gagneVideo[habit]);
changementHabit = 1;
};
if (StrVid == "nul"){
video = new (nulVideo[habit]);
};
if (StrVid == "perdu"){
video = new (perdVideo[habit]);
};
StrVid = "";
fixVideo();
}
public function btOkClick(_arg1:MouseEvent){
this.removeChild(video);
btOk.visible = false;
startGame();
}
public function ciseauxClick(_arg1:MouseEvent){
YouHer.mainYou.gotoAndStop(1);
affBool = true;
pierre.visible = (feuille.visible = (ciseaux.visible = (CacheS.visible = (YouHer.visible = (Result.visible = (btOk.visible = (pierre.enabled = (feuille.enabled = (ciseaux.enabled = false)))))))));
if (choix == "Ciseaux"){
StrVid = "nul";
} else {
if (choix == "Pierre"){
StrVid = "perdu";
} else {
if (choix == "Feuille"){
StrVid = "gagne";
};
};
};
choixVideo();
}
public function pierreClick(_arg1:MouseEvent){
YouHer.mainYou.gotoAndStop(2);
affBool = true;
pierre.visible = (feuille.visible = (ciseaux.visible = (CacheS.visible = (YouHer.visible = (Result.visible = (pierre.enabled = (feuille.enabled = (ciseaux.enabled = false))))))));
if (choix == "Ciseaux"){
StrVid = "gagne";
} else {
if (choix == "Pierre"){
StrVid = "nul";
} else {
if (choix == "Feuille"){
StrVid = "perdu";
};
};
};
choixVideo();
}
public function feuilleClick(_arg1:MouseEvent){
YouHer.mainYou.gotoAndStop(3);
affBool = true;
pierre.visible = (feuille.visible = (ciseaux.visible = (CacheS.visible = (YouHer.visible = (Result.visible = (btOk.visible = (pierre.enabled = (feuille.enabled = (ciseaux.enabled = false)))))))));
if (choix == "Ciseaux"){
StrVid = "perdu";
} else {
if (choix == "Pierre"){
StrVid = "gagne";
} else {
if (choix == "Feuille"){
StrVid = "nul";
};
};
};
choixVideo();
}
public function choixVideo(){
this.removeChild(video);
if (choix == "Ciseaux"){
YouHer.mainHer.gotoAndStop(1);
video = new (ciseauxVideo[habit]);
} else {
if (choix == "Pierre"){
YouHer.mainHer.gotoAndStop(2);
video = new (pierreVideo[habit]);
} else {
if (choix == "Feuille"){
YouHer.mainHer.gotoAndStop(3);
video = new (feuilleVideo[habit]);
};
};
};
fixVideo();
}
public function fixVideo(){
video.x = -277;
video.y = -202;
this.addChild(video);
this.setChildIndex(video, 0);
video.gotoAndPlay(1);
video.addEventListener(Event.ENTER_FRAME, listenerObject);
}
public function lanceWaiting(){
YouHer.visible = (btOk.visible = false);
CacheS.visible = (Result.visible = (pierre.visible = (feuille.visible = (ciseaux.visible = true))));
Result.text = "Make your choice!";
res = "";
choix = tableau[Math.round((Math.random() * 2))];
ciseaux.enabled = true;
feuille.enabled = true;
pierre.enabled = true;
}
public function listenerObject(_arg1:Event){
if (video.currentFrame >= video.totalFrames){
if (StrVid != "bonjour"){
if (StrVid != ""){
myTimer.start();
if (StrVid == "gagne"){
Result.text = "You win!";
};
if (StrVid == "nul"){
Result.text = "Draw!";
};
if (StrVid == "perdu"){
Result.text = "You lose!";
};
} else {
CacheS.visible = (YouHer.visible = (Result.visible = true));
if (changementHabit != 0){
habit = (habit + changementHabit);
changementHabit = 0;
};
if (habit == (habitMax + 1)){
btOk.visible = true;
YouHer.visible = false;
Result.text = "You've won! Play again?";
} else {
lanceWaiting();
};
};
} else {
lanceWaiting();
};
video.removeEventListener(Event.ENTER_FRAME, listenerObject);
video.stop();
};
}
public function timer_Tick(_arg1:TimerEvent){
myTimer.stop();
if (affBool){
affBool = false;
timerOK.start();
CacheS.visible = (YouHer.visible = (Result.visible = true));
};
}
function frame1(){
gameRunning = false;
pointspc = 0;
StrVid = "bonjour";
res = "";
habitMax = 6;
ciseauxVideo = new Array(c0, c1, c2, c3, c4, c5, c6);
pierreVideo = new Array(p0, p1, p2, p3, p4, p5, p6);
feuilleVideo = new Array(f0, f1, f2, f3, f4, f5, f6);
gagneVideo = new Array(gagne0, gagne1, gagne2, gagne3, gagne4, gagne5, gagne6);
perdVideo = new Array(perd0, perd1, perd2, perd3, perd4, perd5, perd6);
nulVideo = new Array(nul0, nul1, nul2, nul3, nul4, nul5, nul6);
Start.addEventListener(MouseEvent.MOUSE_UP, Start_Click);
stop();
changementHabit = 0;
habit = 0;
btOk.addEventListener(MouseEvent.MOUSE_UP, btOkClick);
pierre.addEventListener(MouseEvent.MOUSE_UP, pierreClick);
feuille.addEventListener(MouseEvent.MOUSE_UP, feuilleClick);
ciseaux.addEventListener(MouseEvent.MOUSE_UP, ciseauxClick);
tableau = new Array("Pierre", "Feuille", "Ciseaux");
choix = tableau[Math.round(((Math.random() * this.length) - 0.5))];
affBool = false;
myTimer = new Timer(1500);
timerOK = new Timer(1500);
myTimer.addEventListener(TimerEvent.TIMER, timer_Tick);
timerOK.addEventListener(TimerEvent.TIMER, timerOK_Tick);
}
}
}//package ShifumiFayeCS5_fla
Section 2
//MainTimeline (ShifumiFayeCS5_fla.MainTimeline)
package ShifumiFayeCS5_fla {
import flash.events.*;
import flash.display.*;
import flash.text.*;
import flash.net.*;
public dynamic class MainTimeline extends MovieClip {
public var linkFSG:SimpleButton;
public var pText:TextField;
public var Link:SimpleButton;
public function MainTimeline(){
addFrameScript(0, frame1, 1, frame2);
}
public function loadProgress(_arg1:Event){
var _local2:int = this.root.loaderInfo.bytesLoaded;
var _local3:int = this.root.loaderInfo.bytesTotal;
var _local4:int = ((100 * _local2) / _local3);
pText.text = (("Please Wait: " + _local4) + "%");
if (_local2 >= _local3){
pText.text = "Click on the Start Button to play";
removeEventListener(Event.ENTER_FRAME, loadProgress);
gotoAndStop(3);
};
}
public function linkFSGClick(_arg1:MouseEvent){
var _local2:URLRequest = new URLRequest("http://www.free-strip-games.com/");
navigateToURL(_local2, "_blank");
}
public function LinkClick(_arg1:MouseEvent){
var _local2:URLRequest = new URLRequest("http://www.uplay-istrip.com/");
navigateToURL(_local2, "_blank");
}
function frame1(){
addEventListener(Event.ENTER_FRAME, loadProgress);
linkFSG.addEventListener(MouseEvent.MOUSE_UP, linkFSGClick);
Link.addEventListener(MouseEvent.MOUSE_UP, LinkClick);
}
function frame2(){
stop();
}
}
}//package ShifumiFayeCS5_fla
Section 3
//bonjour (bonjour)
package {
import flash.display.*;
public dynamic class bonjour extends MovieClip {
}
}//package
Section 4
//c0 (c0)
package {
import flash.display.*;
public dynamic class c0 extends MovieClip {
}
}//package
Section 5
//c1 (c1)
package {
import flash.display.*;
public dynamic class c1 extends MovieClip {
}
}//package
Section 6
//c2 (c2)
package {
import flash.display.*;
public dynamic class c2 extends MovieClip {
}
}//package
Section 7
//c3 (c3)
package {
import flash.display.*;
public dynamic class c3 extends MovieClip {
}
}//package
Section 8
//c4 (c4)
package {
import flash.display.*;
public dynamic class c4 extends MovieClip {
}
}//package
Section 9
//c5 (c5)
package {
import flash.display.*;
public dynamic class c5 extends MovieClip {
}
}//package
Section 10
//c6 (c6)
package {
import flash.display.*;
public dynamic class c6 extends MovieClip {
}
}//package
Section 11
//f0 (f0)
package {
import flash.display.*;
public dynamic class f0 extends MovieClip {
}
}//package
Section 12
//f1 (f1)
package {
import flash.display.*;
public dynamic class f1 extends MovieClip {
}
}//package
Section 13
//f2 (f2)
package {
import flash.display.*;
public dynamic class f2 extends MovieClip {
}
}//package
Section 14
//f3 (f3)
package {
import flash.display.*;
public dynamic class f3 extends MovieClip {
}
}//package
Section 15
//f4 (f4)
package {
import flash.display.*;
public dynamic class f4 extends MovieClip {
}
}//package
Section 16
//f5 (f5)
package {
import flash.display.*;
public dynamic class f5 extends MovieClip {
}
}//package
Section 17
//f6 (f6)
package {
import flash.display.*;
public dynamic class f6 extends MovieClip {
}
}//package
Section 18
//gagne0 (gagne0)
package {
import flash.display.*;
public dynamic class gagne0 extends MovieClip {
}
}//package
Section 19
//gagne1 (gagne1)
package {
import flash.display.*;
public dynamic class gagne1 extends MovieClip {
}
}//package
Section 20
//gagne2 (gagne2)
package {
import flash.display.*;
public dynamic class gagne2 extends MovieClip {
}
}//package
Section 21
//gagne3 (gagne3)
package {
import flash.display.*;
public dynamic class gagne3 extends MovieClip {
}
}//package
Section 22
//gagne4 (gagne4)
package {
import flash.display.*;
public dynamic class gagne4 extends MovieClip {
}
}//package
Section 23
//gagne5 (gagne5)
package {
import flash.display.*;
public dynamic class gagne5 extends MovieClip {
}
}//package
Section 24
//gagne6 (gagne6)
package {
import flash.display.*;
public dynamic class gagne6 extends MovieClip {
}
}//package
Section 25
//nul0 (nul0)
package {
import flash.display.*;
public dynamic class nul0 extends MovieClip {
}
}//package
Section 26
//nul1 (nul1)
package {
import flash.display.*;
public dynamic class nul1 extends MovieClip {
}
}//package
Section 27
//nul2 (nul2)
package {
import flash.display.*;
public dynamic class nul2 extends MovieClip {
}
}//package
Section 28
//nul3 (nul3)
package {
import flash.display.*;
public dynamic class nul3 extends MovieClip {
}
}//package
Section 29
//nul4 (nul4)
package {
import flash.display.*;
public dynamic class nul4 extends MovieClip {
}
}//package
Section 30
//nul5 (nul5)
package {
import flash.display.*;
public dynamic class nul5 extends MovieClip {
}
}//package
Section 31
//nul6 (nul6)
package {
import flash.display.*;
public dynamic class nul6 extends MovieClip {
}
}//package
Section 32
//p0 (p0)
package {
import flash.display.*;
public dynamic class p0 extends MovieClip {
}
}//package
Section 33
//p1 (p1)
package {
import flash.display.*;
public dynamic class p1 extends MovieClip {
}
}//package
Section 34
//p2 (p2)
package {
import flash.display.*;
public dynamic class p2 extends MovieClip {
}
}//package
Section 35
//p3 (p3)
package {
import flash.display.*;
public dynamic class p3 extends MovieClip {
}
}//package
Section 36
//p4 (p4)
package {
import flash.display.*;
public dynamic class p4 extends MovieClip {
}
}//package
Section 37
//p5 (p5)
package {
import flash.display.*;
public dynamic class p5 extends MovieClip {
}
}//package
Section 38
//p6 (p6)
package {
import flash.display.*;
public dynamic class p6 extends MovieClip {
}
}//package
Section 39
//perd0 (perd0)
package {
import flash.display.*;
public dynamic class perd0 extends MovieClip {
}
}//package
Section 40
//perd1 (perd1)
package {
import flash.display.*;
public dynamic class perd1 extends MovieClip {
}
}//package
Section 41
//perd2 (perd2)
package {
import flash.display.*;
public dynamic class perd2 extends MovieClip {
}
}//package
Section 42
//perd3 (perd3)
package {
import flash.display.*;
public dynamic class perd3 extends MovieClip {
}
}//package
Section 43
//perd4 (perd4)
package {
import flash.display.*;
public dynamic class perd4 extends MovieClip {
}
}//package
Section 44
//perd5 (perd5)
package {
import flash.display.*;
public dynamic class perd5 extends MovieClip {
}
}//package
Section 45
//perd6 (perd6)
package {
import flash.display.*;
public dynamic class perd6 extends MovieClip {
}
}//package