home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Mobiclic 136
/
MOBICLIC136.ISO
/
pc
/
DATA
/
ENG136
/
ENG136_00
/
ENG136_00.swf
/
scripts
/
frame_209
/
DoAction.as
Wrap
Text File
|
2011-07-20
|
6KB
|
238 lines
function commentFiniLocal()
{
trace("comment fini local");
if(_root.expression)
{
stopExpression();
}
else if(_root.sonVocab != 0)
{
if(_root.listDone[_root.sonVocab - 1] == 0)
{
_root["ZONE_" + _root.sonVocab].gotoAndStop("E1");
}
else
{
_root["ZONE_" + _root.sonVocab].gotoAndStop("E3");
}
gereTextes.masqueIB();
_root.sonVocab = 0;
if(doneVocabSon == undefined)
{
if(getPos(_root.listDone,0) == -1)
{
doneVocabSon = 1;
joueSon({nomSon:"VOC"});
}
}
}
else if(gClicZap !== 0)
{
trace("OOOPS PLAY");
play();
}
}
function zonesEnE1()
{
var _loc2_ = 1;
while(_loc2_ <= nbZones)
{
this["ZONE_" + gimme2digits(_loc2_)].gotoAndStop("E1");
_loc2_ = _loc2_ + 1;
}
}
if(doneIntro == undefined)
{
doneIntro = 1;
joueSon({nomSon:"00",actionFin:"RIEN"});
}
VENDEUR.useHandCursor = 0;
VENDEUR.onPress = function()
{
};
LIZZ.useHandCursor = 0;
LIZZ.onPress = function()
{
};
gereTextes.masqueIB();
BT_DIALOG.onRollOver = function()
{
gereCursor(2);
this.gotoAndStop("E2");
joueBruitage({nomSon:"B_DIA"});
gereTextes.afficheIB({codeIB:"IB_DIA"});
};
BT_DIALOG.onRollOut = function()
{
gereCursor(1);
this.gotoAndStop("E1");
stopBruitage({nomSon:"B_DIA"});
gereTextes.masqueIB();
};
BT_DIALOG.onPress = function()
{
gereTextes.masqueIB();
_root.blockRolls = 1;
gereCursor(1);
this.gotoAndStop("E1");
stopBruitage({nomSon:"B_DIA"});
_root.gotoAndPlay("DIA_INTRO");
};
_root.sonVocab = 0;
nbZones = 14;
if(listDone == undefined)
{
listDone = [];
var i = 1;
while(i <= nbZones)
{
listDone.push(0);
i++;
}
}
_root.blockRolls = 0;
var i = 1;
while(i <= nbZones)
{
this["ZONE_" + gimme2digits(i)].pZone = i;
this["ZONE_" + gimme2digits(i)].pName = "ZONE_" + gimme2digits(i);
if(_root.vocabJeu == 1)
{
if(_root.listDone[i - 1] == 1)
{
this["ZONE_" + gimme2digits(i)].gotoAndStop("E3");
}
}
this["ZONE_" + gimme2digits(i)].onRollOver = function()
{
if(_root.sonVocab == 0 & _root.blockRolls == 0)
{
this.useHandCursor = 1;
gereCursor(2);
joueBruitage({nomSon:"B_" + this.pName.split("_")[1]});
this.gotoAndStop("E2");
}
else
{
this.useHandCursor = 0;
}
};
this["ZONE_" + gimme2digits(i)].onRollOut = function()
{
if(_root.sonVocab == 0 & _root.blockRolls == 0)
{
gereCursor(1);
stopBruitage({nomSon:"B_" + this.pName.split("_")[1]});
switch(_root.vocabJeu)
{
case 1:
if(_root.listDone[this.pZone - 1] == 0)
{
this.gotoAndStop("E1");
}
else
{
this.gotoAndStop("E3");
}
break;
case 2:
this.gotoAndStop("E1");
}
}
else
{
this.useHandCursor = 0;
}
};
this["ZONE_" + gimme2digits(i)].onPress = function()
{
gereCursor(1);
switch(_root.vocabJeu)
{
case 1:
if(_root.sonVocab == 0 & _root.blockRolls == 0)
{
_root.sonVocab = this.pName.split("_")[1];
var _loc3_ = "IB_T" + _root.sonVocab;
gereTextes.afficheIB({codeIB:_loc3_,X:_root._xmouse,Y:_root._ymouse + 20});
joueSon({nomSon:_root.sonVocab,actionFin:"commentFiniLocal"});
stopBruitage({nomSon:"B_" + this.pName.split("_")[1]});
_root.listDone[this.pZone - 1] = 1;
this.gotoAndStop("E3");
}
else
{
this.useHandCursor = 0;
}
break;
case 2:
if(_root.blockRolls == 0)
{
if(this.pName.split("_")[1] == gimme2digits(_root.gListMots[0]))
{
_root.gScore += 1;
_root.succes = 1;
}
else
{
_root.succes = 0;
}
_root.blockRolls = 1;
this.gotoAndStop("e1");
stopBruitage({nomSon:"B_" + this.pName.split("_")[1]});
_root.gotoAndPlay("SUITE_JEU");
}
}
};
i++;
}
btn_jeu._visible = 1;
btn_jeu.onRollOver = function()
{
trace("ROLL " + _root.sonVocab + " " + _root.blockRolls);
if(_root.sonVocab == 0 & _root.blockRolls == 0)
{
this.useHandCursor = 1;
gereCursor(2);
var _loc3_ = "IB_DE";
gereTextes.afficheIB({codeIB:_loc3_,mc:this});
joueBruitage({nomSon:"B_DE"});
this.gotoAndStop(2);
}
};
btn_jeu.onRollOut = function()
{
stopBruitage({nomSon:"B_DE"});
gereCursor(1);
gereTextes.masqueIB();
this.gotoAndStop(1);
};
btn_jeu.onPress = function()
{
if(_root.sonVocab == 0 & _root.blockRolls == 0)
{
stopBruitage({nomSon:"B_DE"});
gereCursor(1);
gCommentOn.stop();
gereTextes.masqueIB();
_root.vocabJeu = 2;
_root.blockRolls = 1;
_root.gScore = 0;
zonesEnE1();
_root.gotoAndPlay("JEU");
}
};
btn_jeu.onReleaseOutside = function()
{
if(_root.sonVocab == 0 & _root.blockRolls == 0)
{
gereCursor(1);
if(gCommentOn !== undefined)
{
stopSon(_root);
}
gereTextes.masqueIB();
}
};
stop();