Frame 1
b1 = _root.getBytesLoaded();
b2 = _root.getBytesTotal();
tgPrel = 1 + Math.round((b1 * 100) / b2);
prel.gotoAndStop(tgPrel);
if (b1 >= b2) {
gotoAndPlay ("intro");
}
Frame 4
if (Math.round(b1 / 1024) <= 35) {
gotoAndPlay ("loop1");
}
Frame 5
b1 = _root.getBytesLoaded();
b2 = _root.getBytesTotal();
tgPrel = 1 + Math.round((b1 * 100) / b2);
tg = tgprel - 1;
if (tg <= 9) {
procent = "0" + tg;
} else {
procent = tg;
}
prel.gotoAndStop(tgPrel);
Frame 9
if (Math.round(b1 / 1024) <= 100) {
gotoAndPlay ("loop2");
}
Frame 11
b1 = _root.getBytesLoaded();
b2 = _root.getBytesTotal();
tgPrel = 1 + Math.round((b1 * 100) / b2);
tg = tgprel - 2;
if (tgprel <= 9) {
procent = "0" + tg;
} else {
procent = tg;
}
prel.gotoAndStop(tgPrel);
Frame 14
if (b1 < b2) {
gotoAndPlay ("loop3");
}
Frame 15
procent = "--";
prel.gotoAndStop(100);
Frame 175
onEnterFrame = function () {
_root.background_joc.swapDepths(110000);
};
_global.music = new Sound();
_global.music.attachSound("tamuza");
_global.music.start(0, 25000);
_global.bee = new Sound();
_global.bee.attachSound("sheep1");
_global.traktor = new Sound();
_global.traktor.attachSound("carsound");
_global.samo = new Sound();
_global.samo.attachSound("trasound");
stop();
Instance of Symbol 122 MovieClip in Frame 175
//component parameters
onClipEvent (initialize) {
wynume = "littleShepherd";
wyculoare = 0;
wyasezare = "Vertical";
wyaliniere = "Stanga";
wypozitie = "Sus";
wyinstructions = true;
}
Instance of Symbol 122 MovieClip "theMenu" in Frame 175
//component parameters
onClipEvent (initialize) {
wynume = "LittleShepherd";
wyculoare = 39423;
wyasezare = "Vertical";
wyaliniere = "Stanga";
wypozitie = "Sus";
wyinstructions = true;
}
Instance of Symbol 138 MovieClip in Frame 175
on (release) {
getURL ("http://www.freeonlinegames.com/?LittleShepherd", "_blank");
}
Frame 176
if (_global.skonczyl == 1) {
_global.skonczyl = 0;
_root.wynik.gotoAndStop(2);
}
stop();
Instance of Symbol 154 MovieClip in Frame 176
on (release) {
_global.music.stop();
_root.gotoAndPlay("coperta");
}
Frame 177
_global.level = 0;
stop();
Frame 178
function getDistance(x1, y1, x2, y2) {
return(Math.sqrt(((x2 - x1) * (x2 - x1)) + ((y2 - y1) * (y2 - y1))));
}
function getAngle(x1, y1, x2, y2) {
dX = x2 - x1;
dY = y2 - y1;
theAngle = (180 * Math.atan(dY / dX)) / 3.141593;
if (dX < 0) {
theAngle = theAngle + 180;
}
return(theAngle);
}
removeMovieClip(_root.playAgain);
duplicateMovieClip (_root.owca, "owca1", 100);
duplicateMovieClip (_root.owca, "owca2", 101);
duplicateMovieClip (_root.owca, "owca3", 102);
i = 1;
while (i < 4) {
_root["owca" + i]._x = random(40) + 400;
_root["owca" + i]._y = random(200) + 40;
z = 99 + i;
_global["ustalkier" + z] = 1;
_global["popraw" + z] = 1;
i++;
}
_global.time_l = 0;
_root.playAgain.swapDepths(10000);
_root.napis.swapDepths(11000);
_root.playAgain._x = -446.2;
_root.playAgain._y = 526;
_global.level = 1;
_root.replay_the_game._x = 92;
_root.replay_the_game._y = 118.6;
var timerS_l:String;
var timerM_l:String;
folderM_l = 0;
_global.counter_timp_l = 0;
_global.counter_l = 0;
_global.count_sec = 0;
onEnterFrame = function () {
var _local1 = _global;
if (_local1.pause_var != 1) {
sunet_clock = new Sound();
sunet_clock.attachSound("clocksound");
sunet_end = new Sound();
sunet_end.attachSound("endsound");
if ((_local1.counter_l < 300) && (((_local1.counter_l / 20) - Math.round(_local1.counter_l / 20)) == 0)) {
sunet_clock.start();
} else if ((_local1.counter_l >= 300) && (_local1.counter_l <= 310)) {
_root.blip.gotoAndPlay(2);
sunet_end.start();
}
if (_local1.counter_timp_l < 1) {
_local1.counter_l++;
if (_local1.counter_l == 300) {
_root.replay_the_game.gotoAndPlay(2);
}
}
folderS_l = Math.ceil((counter_l - (1200 * _local1.count_sec)) / 20) - 1;
if (folderS_l < 10) {
timerS_l = "0" + folderS_l.toString();
} else {
timerS_l = folderS_l.toString();
}
if ((Math.round(counter_l / 1200) - (counter_l / 1200)) == 0) {
folderM_l++;
_local1.count_sec++;
}
if (folderM_l < 10) {
timerM_l = "0" + folderM_l.toString();
} else {
timerM_l = folderM_l.toString();
}
}
};
stop();
stop();
_root.themenu.swapDepths(100000);
Instance of Symbol 163 MovieClip "owca" in Frame 178
onClipEvent (enterFrame) {
if (_global.pause_var != 1) {
if (this._y > 0) {
_global.beelicznik--;
glebia = this.getDepth();
dx = _x - _root.boy._x;
dy = _y - _root.boy._y;
hyp = Math.sqrt((dx * dx) + (dy * dy));
if ((hyp < _global.zasieg) && (_global["popraw" + glebia] == 1)) {
if (_global.beelicznik <= 0) {
_global.bee.start();
_global.beelicznik = 1000;
}
speed = (5 * Math.pow((_global.zasieg - hyp) / 100, 3)) + 3;
if (_global.zasieg > 100) {
speed = speed / 8;
}
if ((((this._x > 20) && (this._x < 580)) && (this._y > 20)) && (this._y < 480)) {
_global["zmianax" + glebia] = (speed * dx) / hyp;
_global["zmianay" + glebia] = (speed * dy) / hyp;
}
}
if (_root.fence.hitTest(this._x, this._y, true)) {
if (hyp < _global.zasieg) {
_global["popraw" + glebia] = 0;
} else {
_global["popraw" + glebia] = 1;
_global["zmianax" + glebia] = -(1.5 * _global["zmianax" + glebia]);
_global["zmianay" + glebia] = -(1.5 * _global["zmianay" + glebia]);
this._x = this._x + (_global["zmianax" + glebia] + oddx);
this._y = this._y + (_global["zmianay" + glebia] + oddy);
}
}
if (_root.target.hitTest(this._x, this._y, true)) {
_global["zmianax" + glebia] = 0.9 * _global["zmianax" + glebia];
_global["zmianay" + glebia] = 0.9 * _global["zmianay" + glebia];
}
if (_global["ustalkier" + glebia] == 1) {
_global["ustalkier" + glebia] = 0;
_global["zmianax" + glebia] = random(2) - 0.5;
_global["zmianay" + glebia] = random(2) - 0.5;
_global["zmianax" + glebia] = _global["zmianax" + glebia] + 0.1;
_global["zmianay" + glebia] = _global["zmianay" + glebia] + 0.1;
}
if ((Math.abs(_global["zmianax" + glebia]) > 0.25) && (Math.abs(_global["zmianay" + glebia]) > 0.25)) {
_global["zmianax" + glebia] = _global["zmianax" + glebia] * 0.97;
_global["zmianay" + glebia] = _global["zmianay" + glebia] * 0.97;
}
_rotation = _root.getAngle(_x, _y, _x + _global["zmianax" + glebia], _y + _global["zmianay" + glebia]);
this._x = this._x + ((_global["zmianax" + glebia] + oddx) * _global["popraw" + glebia]);
this._y = this._y + ((_global["zmianay" + glebia] + oddy) * _global["popraw" + glebia]);
if ((_x <= 20) && (_global["zmianax" + glebia] < 0)) {
_global["zmianax" + glebia] = (-_global["zmianax" + glebia]) + 0.1;
this._x = this._x + (_global["zmianax" + glebia] + oddx);
this._y = this._y + (_global["zmianay" + glebia] + oddy);
}
if ((_x >= 580) && (_global["zmianax" + glebia] > 0)) {
_global["zmianax" + glebia] = (-_global["zmianax" + glebia]) + 0.1;
this._x = this._x + (_global["zmianax" + glebia] + oddx);
this._y = this._y + (_global["zmianay" + glebia] + oddy);
}
if ((_y <= 20) && (_global["zmianay" + glebia] < 0)) {
_global["zmianay" + glebia] = (-_global["zmianay" + glebia]) + 0.1;
this._x = this._x + (_global["zmianax" + glebia] + oddx);
this._y = this._y + (_global["zmianay" + glebia] + oddy);
}
if ((_y >= 480) && (_global["zmianay" + glebia] > 0)) {
_global["zmianay" + glebia] = (-_global["zmianay" + glebia]) + 0.1;
this._x = this._x + (_global["zmianax" + glebia] + oddx);
this._y = this._y + (_global["zmianay" + glebia] + oddy);
}
}
}
}
Instance of Symbol 169 MovieClip in Frame 178
onClipEvent (enterFrame) {
if (((_root.target.hitTest(_root.owca1._x, _root.owca1._y, true) == true) && (_root.target.hitTest(_root.owca2._x, _root.owca2._y, true) == true)) && (_root.target.hitTest(_root.owca3._x, _root.owca3._y, true) == true)) {
_global.counter_timp_l++;
}
if (_global.counter_timp_l == 1) {
_global.time_l = _global.counter_l;
}
if (_global.time_l > 300) {
_root.playAgain.gotoAndPlay("level_time");
_root.playAgain._x = 305;
_root.playAgain._y = 250;
} else if ((_global.time_l <= 300) && (_global.counter_timp_l > 0)) {
_global.nextlevel = 1;
_root.napis._x = 300;
_root.napis._y = 200;
}
}
Instance of Symbol 179 MovieClip "boy" in Frame 178
onClipEvent (load) {
_global.speed = 0.1;
_global.nextlevel = 0;
_global.nowapauza = 1;
_global.punkty = 0;
_global.muzagra = 1;
_global.zasieg = 100;
}
onClipEvent (enterFrame) {
if (_global.pause_var != 1) {
if ((Math.abs(_xmouse - this._x) < 2000) && (Math.abs(_ymouse - this._y) < 2000)) {
x_coord = _root._xmouse;
y_coord = _root._ymouse;
if (x_coord <= 0) {
x_coord = 0;
}
if (y_coord <= 0) {
y_coord = 0;
}
if (x_coord >= 600) {
x_coord = 600;
}
if (y_coord >= 500) {
y_coord = 500;
}
}
dawajx = speed * (x_coord - _x);
dawajy = speed * (y_coord - _y);
_x = (_x + dawajx);
_y = (_y + dawajy);
_rotation = _root.getAngle(_x, _y, _root._xmouse, _root._ymouse);
if (_root.fence.hitTest(this._x, this._y, true)) {
dawajx = -dawajx;
dawajy = -dawajy;
_x = (_x + dawajx);
_y = (_y + dawajy);
}
}
}
onClipEvent (mouseDown) {
_global.zasieg = 200;
this.gotoAndStop(2);
}
onClipEvent (mouseUp) {
_global.zasieg = 100;
this.gotoAndStop(1);
}
Instance of Symbol 181 MovieClip in Frame 178
/* no clip actions */
Instance of Symbol 183 MovieClip in Frame 178
on (press, keyPress "m") {
klawisz = 1;
if ((_global.muzagra == 1) && (klawisz == 1)) {
klawisz = 0;
_global.muzagra = 0;
stopAllSounds();
}
if ((_global.muzagra == 0) && (klawisz == 1)) {
klawisz = 0;
_global.muzagra = 1;
_global.music.start(0, 25000);
}
}
Instance of Symbol 187 MovieClip "napis" in Frame 178
on (keyPress "<Space>") {
removeMovieClip(this);
}
Instance of Symbol 189 MovieClip "tree1" in Frame 178
onClipEvent (load) {
this.swapDepths(300);
}
Instance of Symbol 189 MovieClip "tree2" in Frame 178
onClipEvent (load) {
this.swapDepths(301);
}
Instance of Symbol 207 MovieClip "playAgain" in Frame 178
on (release) {
_global.time_l = 0;
removeMovieClip(_root.owca1);
removeMovieClip(_root.owca2);
removeMovieClip(_root.owca3);
removeMovieClip(_root.tree1);
removeMovieClip(_root.tree2);
_root.themenu.removeMovieClip();
removeMovieClip(this);
_root.toGo = "level1";
_root.gotoAndStop("golevel1");
}
Instance of Symbol 257 MovieClip "themenu" in Frame 178
//component parameters
onClipEvent (initialize) {
wxnume = "LittleShepherd";
wxaliniere = "Stanga-Jos";
wxculoare = 39423;
wxdownload = true;
wxpause = true;
wxsound = true;
}
Instance of Symbol 264 MovieClip "replay_the_game" in Frame 178
on (release) {
_global.time_l = 0;
removeMovieClip(_root.owca1);
removeMovieClip(_root.owca2);
removeMovieClip(_root.owca3);
removeMovieClip(_root.tree1);
removeMovieClip(_root.tree2);
removeMovieClip(this);
_root.themenu.removeMovieClip();
_root.toGo = "level1";
_root.gotoAndStop("golevel1");
}
Frame 179
_global.level = 2;
_root.playAgain.swapDepths(10000);
_root.napis.swapDepths(11000);
_root.playAgain._x = -446.2;
_root.playAgain._y = 526;
_root.replay_the_game._x = 500;
_root.replay_the_game._y = 118.6;
var timerS_l:String;
var timerM_l:String;
folderM_l = 0;
_global.counter_timp_l = 0;
_global.counter_l = 0;
_global.count_sec = 0;
onEnterFrame = function () {
var _local1 = _global;
if (_local1.pause_var != 1) {
sunet_clock = new Sound();
sunet_clock.attachSound("clocksound");
sunet_end = new Sound();
sunet_end.attachSound("endsound");
if ((_local1.counter_l < 400) && (((_local1.counter_l / 20) - Math.round(_local1.counter_l / 20)) == 0)) {
sunet_clock.start();
} else if ((_local1.counter_l >= 400) && (_local1.counter_l <= 410)) {
_root.blip.gotoAndPlay(2);
sunet_end.start();
}
if ((_local1.licznikend != 0) && (_local1.counter_timp_l < 1)) {
_local1.counter_l++;
if (_local1.counter_l == 400) {
_root.replay_the_game.gotoAndPlay(2);
}
}
folderS_l = Math.ceil((counter_l - (1200 * _local1.count_sec)) / 20) - 1;
if (folderS_l < 10) {
timerS_l = "0" + folderS_l.toString();
} else {
timerS_l = folderS_l.toString();
}
if ((Math.round(counter_l / 1200) - (counter_l / 1200)) == 0) {
folderM_l++;
_local1.count_sec++;
}
if (folderM_l < 10) {
timerM_l = "0" + folderM_l.toString();
} else {
timerM_l = folderM_l.toString();
}
}
};
stop();
stop();
stop();
_root.themenu.swapDepths(100000);
Instance of Symbol 163 MovieClip "owca" in Frame 179
onClipEvent (enterFrame) {
if (_global.pause_var != 1) {
glebia = this.getDepth();
if ((this._y > 0) && (_global["zyje" + glebia] == 1)) {
_global.beelicznik--;
glebia = this.getDepth();
dx = _x - _root.boy._x;
dy = _y - _root.boy._y;
hyp = Math.sqrt((dx * dx) + (dy * dy));
if ((hyp < _global.zasieg) && (_global["popraw" + glebia] == 1)) {
if (_global.beelicznik <= 0) {
_global.bee.start();
_global.beelicznik = 1000;
}
speed = (5 * Math.pow((_global.zasieg - hyp) / 100, 3)) + 3;
if (_global.zasieg > 100) {
speed = speed / 8;
}
if ((((this._x > 20) && (this._x < 580)) && (this._y > 20)) && (this._y < 480)) {
_global["zmianax" + glebia] = (speed * dx) / hyp;
_global["zmianay" + glebia] = (speed * dy) / hyp;
}
}
if (_root.fence.hitTest(this._x, this._y, true)) {
if (hyp < _global.zasieg) {
_global["popraw" + glebia] = 0;
} else {
_global["popraw" + glebia] = 1;
_global["zmianax" + glebia] = -(1.5 * _global["zmianax" + glebia]);
_global["zmianay" + glebia] = -(1.5 * _global["zmianay" + glebia]);
this._x = this._x + (_global["zmianax" + glebia] + oddx);
this._y = this._y + (_global["zmianay" + glebia] + oddy);
}
}
if (_root.target.hitTest(this._x, this._y, true)) {
_global["zmianax" + glebia] = 0.9 * _global["zmianax" + glebia];
_global["zmianay" + glebia] = 0.9 * _global["zmianay" + glebia];
}
if (_root.pool.woda.hitTest(this._x, this._y, true)) {
this.gotoAndStop(2);
_global["zyje" + glebia] = 0;
_global.licznikend = 30;
}
if (_global["ustalkier" + glebia] == 1) {
_global["ustalkier" + glebia] = 0;
_global["zmianax" + glebia] = random(2) - 0.5;
_global["zmianay" + glebia] = random(2) - 0.5;
_global["zmianax" + glebia] = _global["zmianax" + glebia] + 0.1;
_global["zmianay" + glebia] = _global["zmianay" + glebia] + 0.1;
}
if ((Math.abs(_global["zmianax" + glebia]) > 0.25) && (Math.abs(_global["zmianay" + glebia]) > 0.25)) {
_global["zmianax" + glebia] = _global["zmianax" + glebia] * 0.97;
_global["zmianay" + glebia] = _global["zmianay" + glebia] * 0.97;
}
_rotation = _root.getAngle(_x, _y, _x + _global["zmianax" + glebia], _y + _global["zmianay" + glebia]);
this._x = this._x + ((_global["zmianax" + glebia] + oddx) * _global["popraw" + glebia]);
this._y = this._y + ((_global["zmianay" + glebia] + oddy) * _global["popraw" + glebia]);
if ((_x < 20) && (_global["zmianax" + glebia] < 0)) {
_global["zmianax" + glebia] = (-_global["zmianax" + glebia]) + 0.1;
this._x = this._x + (_global["zmianax" + glebia] + oddx);
this._y = this._y + (_global["zmianay" + glebia] + oddy);
}
if ((_x > 580) && (_global["zmianax" + glebia] > 0)) {
_global["zmianax" + glebia] = (-_global["zmianax" + glebia]) + 0.1;
this._x = this._x + (_global["zmianax" + glebia] + oddx);
this._y = this._y + (_global["zmianay" + glebia] + oddy);
}
if ((_y < 20) && (_global["zmianay" + glebia] < 0)) {
_global["zmianay" + glebia] = (-_global["zmianay" + glebia]) + 0.1;
this._x = this._x + (_global["zmianax" + glebia] + oddx);
this._y = this._y + (_global["zmianay" + glebia] + oddy);
}
if ((_y > 480) && (_global["zmianay" + glebia] > 0)) {
_global["zmianay" + glebia] = (-_global["zmianay" + glebia]) + 0.1;
this._x = this._x + (_global["zmianax" + glebia] + oddx);
this._y = this._y + (_global["zmianay" + glebia] + oddy);
}
}
}
}
Instance of Symbol 181 MovieClip in Frame 179
onClipEvent (load) {
duplicateMovieClip (_root.owca, "owca1", 100);
duplicateMovieClip (_root.owca, "owca2", 101);
duplicateMovieClip (_root.owca, "owca3", 102);
duplicateMovieClip (_root.owca, "owca4", 103);
i = 1;
while (i < 5) {
_root["owca" + i]._x = random(40) + 400;
_root["owca" + i]._y = random(200) + 40;
z = 99 + i;
_global["ustalkier" + z] = 1;
_global["zyje" + z] = 1;
_global["popraw" + z] = 1;
i++;
}
}
Instance of Symbol 183 MovieClip in Frame 179
on (press, keyPress "m") {
klawisz = 1;
if ((_global.muzagra == 1) && (klawisz == 1)) {
klawisz = 0;
_global.muzagra = 0;
stopAllSounds();
}
if ((_global.muzagra == 0) && (klawisz == 1)) {
klawisz = 0;
_global.muzagra = 1;
_global.music.start(0, 25000);
}
}
Instance of Symbol 187 MovieClip "napis" in Frame 179
on (keyPress "<Space>") {
removeMovieClip(this);
}
Instance of Symbol 169 MovieClip in Frame 179
onClipEvent (enterFrame) {
if ((((_root.target.hitTest(_root.owca1._x, _root.owca1._y, true) == true) && (_root.target.hitTest(_root.owca2._x, _root.owca2._y, true) == true)) && (_root.target.hitTest(_root.owca3._x, _root.owca3._y, true) == true)) && (_root.target.hitTest(_root.owca4._x, _root.owca4._y, true))) {
_global.counter_timp_l++;
}
if (_global.counter_timp_l == 1) {
_global.time_l = _global.counter_l;
}
if (_global.time_l > 400) {
_root.playAgain.gotoAndPlay("level_time");
_root.playAgain._x = 305;
_root.playAgain._y = 250;
} else if ((_global.time_l <= 400) && (_global.counter_timp_l > 0)) {
_global.nextlevel = 1;
_root.napis._x = 300;
_root.napis._y = 200;
}
if (_global.licznikend > 0) {
_global.licznikend--;
}
if (_global.licznikend == 0) {
_root.playAgain.gotoAndStop("dead_sheep");
_root.playAgain._x = 305;
_root.playAgain._y = 250;
}
}
Instance of Symbol 179 MovieClip "boy" in Frame 179
onClipEvent (load) {
_global.speed = 0.1;
_global.nextlevel = 0;
_global.nowapauza = 1;
_global.punkty = 0;
_global.zasieg = 100;
_global.licznikend = -10;
}
onClipEvent (enterFrame) {
if (_global.pause_var != 1) {
if ((Math.abs(_xmouse - this._x) < 2000) && (Math.abs(_ymouse - this._y) < 2000)) {
x_coord = _root._xmouse;
y_coord = _root._ymouse;
if (x_coord <= 0) {
x_coord = 0;
}
if (y_coord <= 0) {
y_coord = 0;
}
if (x_coord >= 600) {
x_coord = 600;
}
if (y_coord >= 500) {
y_coord = 500;
}
}
dawajx = speed * (x_coord - _x);
dawajy = speed * (y_coord - _y);
_x = (_x + dawajx);
_y = (_y + dawajy);
_rotation = _root.getAngle(_x, _y, _root._xmouse, _root._ymouse);
if (_root.fence.hitTest(this._x, this._y, true)) {
dawajx = -dawajx;
dawajy = -dawajy;
_x = (_x + dawajx);
_y = (_y + dawajy);
}
}
}
onClipEvent (mouseDown) {
_global.zasieg = 200;
this.gotoAndStop(2);
}
onClipEvent (mouseUp) {
_global.zasieg = 100;
this.gotoAndStop(1);
}
Instance of Symbol 189 MovieClip "tree1" in Frame 179
onClipEvent (load) {
this.swapDepths(300);
}
Instance of Symbol 207 MovieClip "playAgain" in Frame 179
on (release) {
_global.time_l = 0;
removeMovieClip(_root.owca1);
removeMovieClip(_root.owca2);
removeMovieClip(_root.owca3);
removeMovieClip(_root.owca4);
removeMovieClip(_root.tree1);
removeMovieClip(_root.pool);
_root.themenu.removeMovieClip();
removeMovieClip(this);
_root.toGo = "level2";
_root.gotoAndStop("golevel2");
}
Instance of Symbol 264 MovieClip "replay_the_game" in Frame 179
on (release) {
_global.time_l = 0;
removeMovieClip(_root.owca1);
removeMovieClip(_root.owca2);
removeMovieClip(_root.owca3);
removeMovieClip(_root.owca4);
removeMovieClip(_root.pool);
_root.themenu.removeMovieClip();
_root.toGo = "level2";
_root.gotoAndStop("golevel2");
}
Frame 180
_global.level = 3;
_root.playAgain.swapDepths(10000);
_root.napis.swapDepths(11000);
_root.trak.swapDepths(9997);
_root.cara.swapDepths(9996);
_root.playAgain._x = -446.2;
_root.playAgain._y = 526;
_root.replay_the_game._x = 92;
_root.replay_the_game._y = 118.6;
var timerS_l:String;
var timerM_l:String;
folderM_l = 0;
_global.counter_timp_l = 0;
_global.counter_l = 0;
_global.sheephit = 0;
_global.sheephit = 0;
_global.count_sec = 0;
onEnterFrame = function () {
var _local1 = _global;
if (_local1.pause_var != 1) {
sunet_clock = new Sound();
sunet_clock.attachSound("clocksound");
sunet_end = new Sound();
sunet_end.attachSound("endsound");
if ((_local1.counter_l < 1000) && (((_local1.counter_l / 20) - Math.round(_local1.counter_l / 20)) == 0)) {
sunet_clock.start();
} else if ((_local1.counter_l >= 1000) && (_local1.counter_l <= 1010)) {
_root.blip.gotoAndPlay(2);
sunet_end.start();
}
if (((_local1.sheephit != 1) && (_local1.boydead != 1)) && (_local1.counter_timp_l < 1)) {
_local1.counter_l++;
if (_local1.counter_l == 1000) {
_root.replay_the_game.gotoAndPlay(2);
}
}
folderS_l = Math.ceil((counter_l - (1200 * _local1.count_sec)) / 20) - 1;
if (folderS_l < 10) {
timerS_l = "0" + folderS_l.toString();
} else {
timerS_l = folderS_l.toString();
}
if ((Math.round(counter_l / 1200) - (counter_l / 1200)) == 0) {
folderM_l++;
_local1.count_sec++;
}
if (folderM_l < 10) {
timerM_l = "0" + folderM_l.toString();
} else {
timerM_l = folderM_l.toString();
}
}
};
stop();
stop();
_root.themenu.swapDepths(100000);
Instance of Symbol 163 MovieClip "owca" in Frame 180
onClipEvent (enterFrame) {
if (_global.pause_var != 1) {
glebia = this.getDepth();
if ((this._y > 0) && (_global["zyje" + glebia] == 1)) {
_global.beelicznik--;
glebia = this.getDepth();
dx = _x - _root.boy._x;
dy = _y - _root.boy._y;
hyp = Math.sqrt((dx * dx) + (dy * dy));
if ((hyp < _global.zasieg) && (_global["popraw" + glebia] == 1)) {
if (_global.beelicznik <= 0) {
_global.bee.start();
_global.beelicznik = 1000;
}
speed = (5 * Math.pow((_global.zasieg - hyp) / 100, 3)) + 3;
if (_global.zasieg > 100) {
speed = speed / 8;
}
if ((((this._x > 20) && (this._x < 580)) && (this._y > 20)) && (this._y < 480)) {
_global["zmianax" + glebia] = (speed * dx) / hyp;
_global["zmianay" + glebia] = (speed * dy) / hyp;
}
}
if (_root.fence.hitTest(this._x, this._y, true)) {
if (hyp < _global.zasieg) {
_global["popraw" + glebia] = 0;
} else {
_global["popraw" + glebia] = 1;
_global["zmianax" + glebia] = -(1.5 * _global["zmianax" + glebia]);
_global["zmianay" + glebia] = -_(1.5 * global["zmianay" + glebia]);
this._x = this._x + (_global["zmianax" + glebia] + oddx);
this._y = this._y + (_global["zmianay" + glebia] + oddy);
}
}
if (_root.target.hitTest(this._x, this._y, true)) {
_global["zmianax" + glebia] = 0.1 * _global["zmianax" + glebia];
_global["zmianay" + glebia] = 0.1 * _global["zmianay" + glebia];
}
if (_root.fence2.hitTest(this._x, this._y, true)) {
if (hyp < _global.zasieg) {
_global["popraw" + glebia] = 0;
} else {
_global["popraw" + glebia] = 1;
_global["zmianax" + glebia] = -(1.5 * _global["zmianax" + glebia]);
_global["zmianay" + glebia] = -(1.5 * _global["zmianay" + glebia]);
this._x = this._x + (_global["zmianax" + glebia] + oddx);
this._y = this._y + (_global["zmianay" + glebia] + oddy);
}
}
if (_root.cara.car.hitTest(this._x, this._y, true)) {
trace("hit");
_root.playAgain.gotoAndStop("dead_sheep");
_root.playAgain._x = 305;
_root.playAgain._y = 250;
_root.toGo = "level3";
this.gotoAndStop("golevel3");
this.gotoAndStop(2);
_global["zyje" + glebia] = 0;
_global.licznikend = 30;
_global.sheephit = 1;
}
if (_root.trak.traka.hitTest(this._x, this._y, true)) {
trace("hit");
_root.playAgain.gotoAndStop("dead_sheep");
_root.playAgain._x = 305;
_root.playAgain._y = 250;
_root.toGo = "level3";
this.gotoAndStop("golevel3");
this.gotoAndStop(2);
_global["zyje" + glebia] = 0;
_global.licznikend = 30;
_global.sheephit = 1;
}
if (_global["ustalkier" + glebia] == 1) {
_global["ustalkier" + glebia] = 0;
_global["zmianax" + glebia] = random(2) - 0.5;
_global["zmianay" + glebia] = random(2) - 0.5;
_global["zmianax" + glebia] = _global["zmianax" + glebia] + 0.1;
_global["zmianay" + glebia] = _global["zmianay" + glebia] + 0.1;
}
if ((Math.abs(_global["zmianax" + glebia]) > 0.25) && (Math.abs(_global["zmianay" + glebia]) > 0.25)) {
_global["zmianax" + glebia] = _global["zmianax" + glebia] * 0.97;
_global["zmianay" + glebia] = _global["zmianay" + glebia] * 0.97;
}
_rotation = _root.getAngle(_x, _y, _x + _global["zmianax" + glebia], _y + _global["zmianay" + glebia]);
this._x = this._x + ((_global["zmianax" + glebia] + oddx) * _global["popraw" + glebia]);
this._y = this._y + ((_global["zmianay" + glebia] + oddy) * _global["popraw" + glebia]);
if ((_x < 20) && (_global["zmianax" + glebia] < 0)) {
_global["zmianax" + glebia] = (-_global["zmianax" + glebia]) + 0.1;
this._x = this._x + (_global["zmianax" + glebia] + oddx);
this._y = this._y + (_global["zmianay" + glebia] + oddy);
}
if ((_x > 580) && (_global["zmianax" + glebia] > 0)) {
_global["zmianax" + glebia] = (-_global["zmianax" + glebia]) + 0.1;
this._x = this._x + (_global["zmianax" + glebia] + oddx);
this._y = this._y + (_global["zmianay" + glebia] + oddy);
}
if ((_y < 20) && (_global["zmianay" + glebia] < 0)) {
_global["zmianay" + glebia] = (-_global["zmianay" + glebia]) + 0.1;
this._x = this._x + (_global["zmianax" + glebia] + oddx);
this._y = this._y + (_global["zmianay" + glebia] + oddy);
}
if ((_y > 480) && (_global["zmianay" + glebia] > 0)) {
_global["zmianay" + glebia] = (-_global["zmianay" + glebia]) + 0.1;
this._x = this._x + (_global["zmianax" + glebia] + oddx);
this._y = this._y + (_global["zmianay" + glebia] + oddy);
}
}
}
}
Instance of Symbol 181 MovieClip in Frame 180
onClipEvent (load) {
duplicateMovieClip (_root.owca, "owca1", 100);
duplicateMovieClip (_root.owca, "owca2", 101);
duplicateMovieClip (_root.owca, "owca3", 102);
duplicateMovieClip (_root.owca, "owca4", 103);
duplicateMovieClip (_root.owca, "owca5", 104);
i = 1;
while (i < 6) {
_root["owca" + i]._x = 100 + (i * 5);
_root["owca" + i]._y = 100 + (i * 5);
z = 99 + i;
_global["ustalkier" + z] = 1;
_global["zyje" + z] = 1;
_global["popraw" + z] = 1;
i++;
}
}
Instance of Symbol 183 MovieClip in Frame 180
on (press, keyPress "m") {
klawisz = 1;
if ((_global.muzagra == 1) && (klawisz == 1)) {
klawisz = 0;
_global.muzagra = 0;
stopAllSounds();
}
if ((_global.muzagra == 0) && (klawisz == 1)) {
klawisz = 0;
_global.muzagra = 1;
_global.music.start(0, 25000);
}
}
Instance of Symbol 169 MovieClip in Frame 180
onClipEvent (load) {
_global.cara_var = 0;
_global.trak_var = 0;
}
onClipEvent (enterFrame) {
if (((((_root.target.hitTest(_root.owca1._x, _root.owca1._y, true) == true) && (_root.target.hitTest(_root.owca2._x, _root.owca2._y, true) == true)) && (_root.target.hitTest(_root.owca3._x, _root.owca3._y, true) == true)) && (_root.target.hitTest(_root.owca4._x, _root.owca4._y, true) == true)) && (_root.target.hitTest(_root.owca5._x, _root.owca5._y, true) == true)) {
_global.counter_timp_l++;
}
if (_global.counter_timp_l == 1) {
_global.time_l = _global.counter_l;
}
if (_global.time_l > 1000) {
_root.playAgain.gotoAndPlay("level_time");
_root.playAgain._x = 305;
_root.playAgain._y = 250;
} else if ((_global.time_l <= 1000) && (_global.counter_timp_l > 0)) {
_global.nextlevel = 1;
_root.napis._x = 300;
_root.napis._y = 200;
}
if (_global.cara_var == 0) {
szansacar = random(300);
if (((szansacar < 2) && (_root.cara._currentframe < 3)) && (_global.pause_var != 1)) {
_global.cara_var = 1;
_root.cara.gotoAndPlay(2);
}
}
if (_global.trak_var == 0) {
szansatrak = random(300);
if (((szansatrak < 2) && (_root.trak._currentframe < 3)) && (_global.pause_var != 1)) {
_global.trak_var = 1;
_root.trak.gotoAndPlay(2);
}
}
if (_global.pause_var == 1) {
_global.cara_var = 2;
_root.cara.stop();
} else if ((_global.pause_var != 1) && (_global.cara_var == 2)) {
_root.cara.play();
_global.cara_var = 0;
}
if (_global.pause_var == 1) {
_global.trak_var = 2;
_root.trak.stop();
} else if ((_global.pause_var != 1) && (_global.trak_var == 2)) {
_root.trak.play();
_global.trak_var = 0;
}
}
Instance of Symbol 179 MovieClip "boy" in Frame 180
onClipEvent (load) {
_global.speed = 0.1;
_global.nextlevel = 0;
_global.nowapauza = 1;
_global.punkty = 0;
_global.zasieg = 100;
_global.licznikend = -10;
_global.boydead = 0;
}
onClipEvent (enterFrame) {
if (_global.pause_var != 1) {
if ((Math.abs(_xmouse - this._x) < 2000) && (Math.abs(_ymouse - this._y) < 2000)) {
x_coord = _root._xmouse;
y_coord = _root._ymouse;
if (x_coord <= 0) {
x_coord = 0;
}
if (y_coord <= 0) {
y_coord = 0;
}
if (x_coord >= 600) {
x_coord = 600;
}
if (y_coord >= 500) {
y_coord = 500;
}
}
dawajx = speed * (x_coord - _x);
dawajy = speed * (y_coord - _y);
if (_root.cara.car.hitTest(this._x, this._y, true)) {
_root.playAgain.gotoAndStop("dead_boy");
_root.playAgain._x = 305;
_root.playAgain._y = 250;
_root.toGo = "level3";
this.gotoAndStop("golevel3");
_global.licznikend = 30;
_global.boydead = 1;
}
if (_root.trak.traka.hitTest(this._x, this._y, true)) {
_root.playAgain.gotoAndStop("dead_boy");
_root.playAgain._x = 305;
_root.playAgain._y = 250;
_root.toGo = "level3";
this.gotoAndStop("golevel3");
_global.boydead = 1;
_global.licznikend = 30;
}
if (_global.boydead == 1) {
dawajx = 0;
dawajy = 0;
}
_x = (_x + dawajx);
_y = (_y + dawajy);
if (_global.boydead != 1) {
_rotation = _root.getAngle(_x, _y, _root._xmouse, _root._ymouse);
}
if (_root.fence.hitTest(this._x, this._y, true)) {
dawajx = -dawajx;
dawajy = -dawajy;
_x = (_x + dawajx);
_y = (_y + dawajy);
}
if (_root.fence2.hitTest(this._x, this._y, true)) {
dawajx = -dawajx;
dawajy = -dawajy;
_x = (_x + dawajx);
_y = (_y + dawajy);
}
}
}
onClipEvent (mouseDown) {
_global.zasieg = 200;
this.gotoAndStop(2);
}
onClipEvent (mouseUp) {
_global.zasieg = 100;
this.gotoAndStop(1);
}
Instance of Symbol 292 MovieClip "trak" in Frame 180
/* no clip actions */
Instance of Symbol 296 MovieClip "cara" in Frame 180
/* no clip actions */
Instance of Symbol 207 MovieClip "playAgain" in Frame 180
on (release) {
_global.time_l = 0;
removeMovieClip(_root.owca1);
removeMovieClip(_root.owca2);
removeMovieClip(_root.owca3);
removeMovieClip(_root.owca4);
removeMovieClip(_root.owca5);
removeMovieClip(_root.fence);
removeMovieClip(_root.trak);
removeMovieClip(_root.cara);
_root.themenu.removeMovieClip();
removeMovieClip(this);
_root.toGo = "level3";
_root.gotoAndStop("golevel3");
}
Instance of Symbol 264 MovieClip "replay_the_game" in Frame 180
on (release) {
_global.time_l = 0;
removeMovieClip(_root.owca1);
removeMovieClip(_root.owca2);
removeMovieClip(_root.owca3);
removeMovieClip(_root.owca4);
removeMovieClip(_root.owca5);
removeMovieClip(_root.tree1);
removeMovieClip(_root.trak);
removeMovieClip(_root.cara);
_root.themenu.removeMovieClip();
_root.toGo = "level3";
_root.gotoAndStop("golevel3");
}
Frame 181
_global.level = 4;
removeMovieClip(_root.owca1);
removeMovieClip(_root.owca2);
removeMovieClip(_root.owca3);
removeMovieClip(_root.owca4);
removeMovieClip(_root.owca5);
removeMovieClip(_root.owca6);
removeMovieClip(_root.tree1);
_root.playAgain.swapDepths(10000);
_root.napis.swapDepths(11000);
_root.playAgain._x = -446.2;
_root.playAgain._y = 526;
_root.replay_the_game._x = 514.4;
_root.replay_the_game._y = 402.2;
_global.level = 1;
var timerS_l:String;
var timerM_l:String;
folderM_l = 0;
_global.counter_timp_l = 0;
_global.counter_l = 0;
_global.count_sec = 0;
onEnterFrame = function () {
var _local1 = _global;
if (_local1.pause_var != 1) {
sunet_clock = new Sound();
sunet_clock.attachSound("clocksound");
sunet_end = new Sound();
sunet_end.attachSound("endsound");
if ((_local1.counter_l < 1200) && (((_local1.counter_l / 20) - Math.round(_local1.counter_l / 20)) == 0)) {
sunet_clock.start();
} else if ((_local1.counter_l >= 1200) && (_local1.counter_l <= 1210)) {
_root.blip.gotoAndPlay(2);
sunet_end.start();
}
if (_local1.counter_timp_l < 1) {
_local1.counter_l++;
if (_local1.counter_l == 1200) {
_root.replay_the_game.gotoAndPlay(2);
}
}
folderS_l = Math.ceil((counter_l - (1200 * _local1.count_sec)) / 20) - 1;
if (folderS_l < 10) {
timerS_l = "0" + folderS_l.toString();
} else {
timerS_l = folderS_l.toString();
}
if ((Math.round(counter_l / 1200) - (counter_l / 1200)) == 0) {
folderM_l++;
_local1.count_sec++;
}
if (folderM_l < 10) {
timerM_l = "0" + folderM_l.toString();
} else {
timerM_l = folderM_l.toString();
}
}
};
stop();
stop();
_root.themenu.swapDepths(100000);
Instance of Symbol 181 MovieClip in Frame 181
onClipEvent (load) {
duplicateMovieClip (_root.owca, "owca1", 100);
duplicateMovieClip (_root.owca, "owca2", 101);
duplicateMovieClip (_root.owca, "owca3", 102);
duplicateMovieClip (_root.owcab, "owca4", 103);
duplicateMovieClip (_root.owcab, "owca5", 104);
duplicateMovieClip (_root.owcab, "owca6", 105);
i = 1;
while (i < 4) {
_root["owca" + i]._x = 100 + (i * 5);
_root["owca" + i]._y = 300 + (i * 5);
z = 99 + i;
_global["ustalkier" + z] = 1;
_global["zyje" + z] = 1;
_global["popraw" + z] = 1;
i++;
}
i = 4;
while (i < 7) {
_root["owca" + i]._x = 400 + (i * 5);
_root["owca" + i]._y = 300 + (i * 5);
z = 99 + i;
_global["ustalkier" + z] = 1;
_global["zyje" + z] = 1;
_global["popraw" + z] = 1;
i++;
}
}
Instance of Symbol 163 MovieClip "owca" in Frame 181
onClipEvent (enterFrame) {
if (_global.pause_var != 1) {
glebia = this.getDepth();
if ((this._y > 0) && (_global["zyje" + glebia] == 1)) {
_global.beelicznik--;
glebia = this.getDepth();
dx = _x - _root.boy._x;
dy = _y - _root.boy._y;
hyp = Math.sqrt((dx * dx) + (dy * dy));
if ((hyp < _global.zasieg) && (_global["popraw" + glebia] == 1)) {
if (_global.beelicznik <= 0) {
_global.bee.start();
_global.beelicznik = 2000;
}
speed = (5 * Math.pow((_global.zasieg - hyp) / 100, 3)) + 3;
if (_global.zasieg > 100) {
speed = speed / 8;
}
if ((((this._x > 20) && (this._x < 580)) && (this._y > 20)) && (this._y < 480)) {
_global["zmianax" + glebia] = (speed * dx) / hyp;
_global["zmianay" + glebia] = (speed * dy) / hyp;
}
}
if (_root.targetw.hitTest(this._x, this._y, true)) {
_global["zmianax" + glebia] = 0.1 * _global["zmianax" + glebia];
_global["zmianay" + glebia] = 0.1 * _global["zmianay" + glebia];
}
if (_root.fence.hitTest(this._x, this._y, true)) {
if (hyp < _global.zasieg) {
_global["popraw" + glebia] = 0;
} else {
_global["popraw" + glebia] = 1;
_global["zmianax" + glebia] = -(1.2 * _global["zmianax" + glebia]);
_global["zmianay" + glebia] = -(1.2 * _global["zmianay" + glebia]);
this._x = this._x + (_global["zmianax" + glebia] + oddx);
this._y = this._y + (_global["zmianay" + glebia] + oddy);
}
}
if (_root.fence2.hitTest(this._x, this._y, true)) {
if (hyp < _global.zasieg) {
_global["popraw" + glebia] = 0;
} else {
_global["popraw" + glebia] = 1;
_global["zmianax" + glebia] = -(1.2 * _global["zmianax" + glebia]);
_global["zmianay" + glebia] = -(1.2 * _global["zmianay" + glebia]);
this._x = this._x + (_global["zmianax" + glebia] + oddx);
this._y = this._y + (_global["zmianay" + glebia] + oddy);
}
}
if (_root.woda1.hitTest(this._x, this._y, true)) {
if (hyp < _global.zasieg) {
_global["popraw" + glebia] = 0;
} else {
_global["popraw" + glebia] = 1;
_global["zmianax" + glebia] = -(1.2 * _global["zmianax" + glebia]);
_global["zmianay" + glebia] = -(1.2 * _global["zmianay" + glebia]);
this._x = this._x + (_global["zmianax" + glebia] + oddx);
this._y = this._y + (_global["zmianay" + glebia] + oddy);
}
}
if (_root.woda2.hitTest(this._x, this._y, true)) {
if (hyp < _global.zasieg) {
_global["popraw" + glebia] = 0;
} else {
_global["popraw" + glebia] = 1;
_global["zmianax" + glebia] = -(1.2 * _global["zmianax" + glebia]);
_global["zmianay" + glebia] = -(1.2 * _global["zmianay" + glebia]);
this._x = this._x + (_global["zmianax" + glebia] + oddx);
this._y = this._y + (_global["zmianay" + glebia] + oddy);
}
}
if (_global["ustalkier" + glebia] == 1) {
_global["ustalkier" + glebia] = 0;
_global["zmianax" + glebia] = random(2) - 0.5;
_global["zmianay" + glebia] = random(2) - 0.5;
_global["zmianax" + glebia] = _global["zmianax" + glebia] + 0.1;
_global["zmianay" + glebia] = _global["zmianay" + glebia] + 0.1;
}
if ((Math.abs(_global["zmianax" + glebia]) > 0.25) && (Math.abs(_global["zmianay" + glebia]) > 0.25)) {
_global["zmianax" + glebia] = _global["zmianax" + glebia] * 0.97;
_global["zmianay" + glebia] = _global["zmianay" + glebia] * 0.97;
}
_rotation = _root.getAngle(_x, _y, _x + _global["zmianax" + glebia], _y + _global["zmianay" + glebia]);
this._x = this._x + ((_global["zmianax" + glebia] + oddx) * _global["popraw" + glebia]);
this._y = this._y + ((_global["zmianay" + glebia] + oddy) * _global["popraw" + glebia]);
if ((_x < 20) && (_global["zmianax" + glebia] < 0)) {
_global["zmianax" + glebia] = (-_global["zmianax" + glebia]) + 0.1;
this._x = this._x + (_global["zmianax" + glebia] + oddx);
this._y = this._y + (_global["zmianay" + glebia] + oddy);
}
if ((_x > 580) && (_global["zmianax" + glebia] > 0)) {
_global["zmianax" + glebia] = -_global["zmianax" + glebia];
this._x = this._x + (_global["zmianax" + glebia] + oddx);
this._y = this._y + (_global["zmianay" + glebia] + oddy);
}
if ((_y < 20) && (_global["zmianay" + glebia] < 0)) {
_global["zmianay" + glebia] = -_global["zmianay" + glebia];
this._x = this._x + (_global["zmianax" + glebia] + oddx);
this._y = this._y + (_global["zmianay" + glebia] + oddy);
}
if ((_y > 480) && (_global["zmianay" + glebia] > 0)) {
_global["zmianay" + glebia] = -_global["zmianay" + glebia];
this._x = this._x + (_global["zmianax" + glebia] + oddx);
this._y = this._y + (_global["zmianay" + glebia] + oddy);
}
}
}
}
Instance of Symbol 169 MovieClip in Frame 181
onClipEvent (enterFrame) {
if ((((((_root.targetw.hitTest(_root.owca1._x, _root.owca1._y, true) == true) && (_root.targetw.hitTest(_root.owca2._x, _root.owca2._y, true) == true)) && (_root.targetw.hitTest(_root.owca3._x, _root.owca3._y, true) == true)) && (_root.targetb.hitTest(_root.owca4._x, _root.owca4._y, true) == true)) && (_root.targetb.hitTest(_root.owca5._x, _root.owca5._y, true) == true)) && (_root.targetb.hitTest(_root.owca6._x, _root.owca6._y, true) == true)) {
_global.counter_timp_l++;
}
if (_global.counter_timp_l == 1) {
_global.time_l = _global.counter_l;
}
if (_global.time_l > 1200) {
_root.playAgain.gotoAndPlay("level_time");
_root.playAgain._x = 305;
_root.playAgain._y = 250;
} else if ((_global.time_l <= 1200) && (_global.counter_timp_l > 0)) {
_global.nextlevel = 1;
_root.napis._x = 300;
_root.napis._y = 200;
}
if (_global.licznikend > 0) {
_global.licznikend--;
}
if (_global.licznikend == 0) {
removeMovieClip(_root.owca1);
removeMovieClip(_root.owca2);
removeMovieClip(_root.owca3);
removeMovieClip(_root.owca4);
removeMovieClip(_root.owca5);
removeMovieClip(_root.owca6);
removeMovieClip(_root.tree1);
_root.gotoAndPlay(2);
}
}
Instance of Symbol 313 MovieClip "owcab" in Frame 181
onClipEvent (enterFrame) {
if (_global.pause_var != 1) {
glebia = this.getDepth();
if ((this._y > 0) && (_global["zyje" + glebia] == 1)) {
_global.beelicznik--;
glebia = this.getDepth();
dx = _x - _root.boy._x;
dy = _y - _root.boy._y;
hyp = Math.sqrt((dx * dx) + (dy * dy));
if ((hyp < _global.zasieg) && (_global["popraw" + glebia] == 1)) {
if (_global.beelicznik <= 0) {
_global.bee.start();
_global.beelicznik = 2000;
}
speed = (5 * Math.pow((_global.zasieg - hyp) / 100, 3)) + 3;
if (_global.zasieg > 100) {
speed = speed / 8;
}
if ((((this._x > 20) && (this._x < 580)) && (this._y > 20)) && (this._y < 480)) {
_global["zmianax" + glebia] = (speed * dx) / hyp;
_global["zmianay" + glebia] = (speed * dy) / hyp;
}
}
if (_root.targetb.hitTest(this._x, this._y, true)) {
_global["zmianax" + glebia] = 0.1 * _global["zmianax" + glebia];
_global["zmianay" + glebia] = 0.1 * _global["zmianay" + glebia];
}
if (_root.fence.hitTest(this._x, this._y, true)) {
if (hyp < _global.zasieg) {
_global["popraw" + glebia] = 0;
} else {
_global["popraw" + glebia] = 1;
_global["zmianax" + glebia] = -(1.2 * _global["zmianax" + glebia]);
_global["zmianay" + glebia] = -(1.2 * _global["zmianay" + glebia]);
this._x = this._x + (_global["zmianax" + glebia] + oddx);
this._y = this._y + (_global["zmianay" + glebia] + oddy);
}
}
if (_root.fence2.hitTest(this._x, this._y, true)) {
if (hyp < _global.zasieg) {
_global["popraw" + glebia] = 0;
} else {
_global["popraw" + glebia] = 1;
_global["zmianax" + glebia] = -(1.2 * _global["zmianax" + glebia]);
_global["zmianay" + glebia] = -(1.2 * _global["zmianay" + glebia]);
this._x = this._x + (_global["zmianax" + glebia] + oddx);
this._y = this._y + (_global["zmianay" + glebia] + oddy);
}
}
if (_root.woda1.hitTest(this._x, this._y, true)) {
if (hyp < _global.zasieg) {
_global["popraw" + glebia] = 0;
} else {
_global["popraw" + glebia] = 1;
_global["zmianax" + glebia] = -(1.2 * _global["zmianax" + glebia]);
_global["zmianay" + glebia] = -(1.2 * _global["zmianay" + glebia]);
this._x = this._x + (_global["zmianax" + glebia] + oddx);
this._y = this._y + (_global["zmianay" + glebia] + oddy);
}
}
if (_root.woda2.hitTest(this._x, this._y, true)) {
if (hyp < _global.zasieg) {
_global["popraw" + glebia] = 0;
} else {
_global["popraw" + glebia] = 1;
_global["zmianax" + glebia] = -(1.2 * _global["zmianax" + glebia]);
_global["zmianay" + glebia] = -(1.2 * _global["zmianay" + glebia]);
this._x = this._x + (_global["zmianax" + glebia] + oddx);
this._y = this._y + (_global["zmianay" + glebia] + oddy);
}
}
if (_global["ustalkier" + glebia] == 1) {
_global["ustalkier" + glebia] = 0;
_global["zmianax" + glebia] = random(2) - 0.5;
_global["zmianay" + glebia] = random(2) - 0.5;
_global["zmianax" + glebia] = _global["zmianax" + glebia] + 0.1;
_global["zmianay" + glebia] = _global["zmianay" + glebia] + 0.1;
}
if ((Math.abs(_global["zmianax" + glebia]) > 0.25) && (Math.abs(_global["zmianay" + glebia]) > 0.25)) {
_global["zmianax" + glebia] = _global["zmianax" + glebia] * 0.97;
_global["zmianay" + glebia] = _global["zmianay" + glebia] * 0.97;
}
_rotation = _root.getAngle(_x, _y, _x + _global["zmianax" + glebia], _y + _global["zmianay" + glebia]);
this._x = this._x + ((_global["zmianax" + glebia] + oddx) * _global["popraw" + glebia]);
this._y = this._y + ((_global["zmianay" + glebia] + oddy) * _global["popraw" + glebia]);
if ((_x < 20) && (_global["zmianax" + glebia] < 0)) {
_global["zmianax" + glebia] = (-_global["zmianax" + glebia]) + 0.1;
this._x = this._x + (_global["zmianax" + glebia] + oddx);
this._y = this._y + (_global["zmianay" + glebia] + oddy);
}
if ((_x > 580) && (_global["zmianax" + glebia] > 0)) {
_global["zmianax" + glebia] = (-_global["zmianax" + glebia]) + 0.1;
this._x = this._x + (_global["zmianax" + glebia] + oddx);
this._y = this._y + (_global["zmianay" + glebia] + oddy);
}
if ((_y < 20) && (_global["zmianay" + glebia] < 0)) {
_global["zmianay" + glebia] = (-_global["zmianay" + glebia]) + 0.1;
this._x = this._x + (_global["zmianax" + glebia] + oddx);
this._y = this._y + (_global["zmianay" + glebia] + oddy);
}
if ((_y > 480) && (_global["zmianay" + glebia] > 0)) {
_global["zmianay" + glebia] = (-_global["zmianay" + glebia]) + 0.1;
this._x = this._x + (_global["zmianax" + glebia] + oddx);
this._y = this._y + (_global["zmianay" + glebia] + oddy);
}
}
}
}
Instance of Symbol 183 MovieClip in Frame 181
on (press, keyPress "m") {
klawisz = 1;
if ((_global.muzagra == 1) && (klawisz == 1)) {
klawisz = 0;
_global.muzagra = 0;
stopAllSounds();
}
if ((_global.muzagra == 0) && (klawisz == 1)) {
klawisz = 0;
_global.muzagra = 1;
_global.music.start(0, 25000);
}
}
Instance of Symbol 189 MovieClip "tree1" in Frame 181
onClipEvent (load) {
this.swapDepths(300);
}
Instance of Symbol 179 MovieClip "boy" in Frame 181
onClipEvent (load) {
_global.speed = 0.1;
_global.nextlevel = 0;
_global.nowapauza = 1;
_global.punkty = 0;
_global.zasieg = 100;
_global.licznikend = -10;
}
onClipEvent (enterFrame) {
if (_global.pause_var != 1) {
if ((Math.abs(_xmouse - this._x) < 2000) && (Math.abs(_ymouse - this._y) < 2000)) {
x_coord = _root._xmouse;
y_coord = _root._ymouse;
if (x_coord <= 0) {
x_coord = 0;
}
if (y_coord <= 0) {
y_coord = 0;
}
if (x_coord >= 600) {
x_coord = 600;
}
if (y_coord >= 500) {
y_coord = 500;
}
}
dawajx = speed * (x_coord - _x);
dawajy = speed * (y_coord - _y);
_x = (_x + dawajx);
_y = (_y + dawajy);
_rotation = _root.getAngle(_x, _y, _root._xmouse, _root._ymouse);
if (_root.woda1.hitTest(this._x, this._y, true)) {
dawajx = -dawajx;
dawajy = -dawajy;
_x = (_x + dawajx);
_y = (_y + dawajy);
}
if (_root.woda2.hitTest(this._x, this._y, true)) {
dawajx = -dawajx;
dawajy = -dawajy;
_x = (_x + dawajx);
_y = (_y + dawajy);
}
if (_root.fence2.hitTest(this._x, this._y, true)) {
dawajx = -dawajx;
dawajy = -dawajy;
_x = (_x + dawajx);
_y = (_y + dawajy);
}
if (_root.fence.hitTest(this._x, this._y, true)) {
dawajx = -dawajx;
dawajy = -dawajy;
_x = (_x + dawajx);
_y = (_y + dawajy);
}
}
}
onClipEvent (mouseDown) {
_global.zasieg = 200;
this.gotoAndStop(2);
}
onClipEvent (mouseUp) {
_global.zasieg = 100;
this.gotoAndStop(1);
}
Instance of Symbol 187 MovieClip "napis" in Frame 181
on (keyPress "<Space>") {
removeMovieClip(this);
}
Instance of Symbol 207 MovieClip "playAgain" in Frame 181
on (release) {
_global.time_l = 0;
removeMovieClip(_root.owca1);
removeMovieClip(_root.owca2);
removeMovieClip(_root.owca3);
removeMovieClip(_root.owca4);
removeMovieClip(_root.owca5);
removeMovieClip(_root.owca6);
removeMovieClip(_root.tree1);
removeMovieClip(_root.targetw);
removeMovieClip(_root.targetb);
removeMovieClip(_root.fence);
removeMovieClip(_root.fence2);
_root.themenu.removeMovieClip();
removeMovieClip(this);
_root.toGo = "level4";
_root.gotoAndStop("golevel4");
}
Instance of Symbol 264 MovieClip "replay_the_game" in Frame 181
on (release) {
_global.time_l = 0;
removeMovieClip(_root.owca1);
removeMovieClip(_root.owca2);
removeMovieClip(_root.owca3);
removeMovieClip(_root.owca4);
removeMovieClip(_root.owca5);
removeMovieClip(_root.owca6);
removeMovieClip(_root.tree1);
_root.themenu.removeMovieClip();
_root.toGo = "level4";
_root.gotoAndStop("golevel4");
}
Frame 182
_global.level = 5;
removeMovieClip(_root.owca1);
removeMovieClip(_root.owca2);
removeMovieClip(_root.owca3);
removeMovieClip(_root.owca4);
removeMovieClip(_root.owca5);
removeMovieClip(_root.owca6);
removeMovieClip(_root.owca7);
_root.playAgain.swapDepths(10000);
_root.napis.swapDepths(11000);
_root.playAgain._x = -446.2;
_root.playAgain._y = 526;
_root.replay_the_game._x = 350;
_root.replay_the_game._y = 460;
_global.level = 1;
var timerS_l:String;
var timerM_l:String;
folderM_l = 0;
_global.counter_timp_l = 0;
_global.counter_l = 0;
_global.count_sec = 0;
onEnterFrame = function () {
var _local1 = _global;
if (_local1.pause_var != 1) {
sunet_clock = new Sound();
sunet_clock.attachSound("clocksound");
sunet_end = new Sound();
sunet_end.attachSound("endsound");
if ((_local1.counter_l < 1200) && (((_local1.counter_l / 20) - Math.round(_local1.counter_l / 20)) == 0)) {
sunet_clock.start();
} else if ((_local1.counter_l >= 1200) && (_local1.counter_l <= 1210)) {
_root.blip.gotoAndPlay(2);
sunet_end.start();
}
if ((_local1.licznikend != 0) && (_local1.counter_timp_l < 1)) {
_local1.counter_l++;
if (_local1.counter_l == 1200) {
_root.replay_the_game.gotoAndPlay(2);
}
}
folderS_l = Math.ceil((counter_l - (1200 * _local1.count_sec)) / 20) - 1;
if (folderS_l < 10) {
timerS_l = "0" + folderS_l.toString();
} else {
timerS_l = folderS_l.toString();
}
if ((Math.round(counter_l / 1200) - (counter_l / 1200)) == 0) {
folderM_l++;
_local1.count_sec++;
}
if (folderM_l < 10) {
timerM_l = "0" + folderM_l.toString();
} else {
timerM_l = folderM_l.toString();
}
}
};
stop();
stop();
_root.themenu.swapDepths(100000);
Instance of Symbol 179 MovieClip "boy" in Frame 182
onClipEvent (load) {
_global.speed = 0.1;
_global.nextlevel = 0;
_global.nowapauza = 1;
_global.punkty = 0;
_global.zasieg = 100;
_global.licznikend = -10;
}
onClipEvent (enterFrame) {
if (_global.pause_var != 1) {
if ((Math.abs(_xmouse - this._x) < 2000) && (Math.abs(_ymouse - this._y) < 2000)) {
x_coord = _root._xmouse;
y_coord = _root._ymouse;
if (x_coord <= 0) {
x_coord = 0;
}
if (y_coord <= 0) {
y_coord = 0;
}
if (x_coord >= 600) {
x_coord = 600;
}
if (y_coord >= 500) {
y_coord = 500;
}
}
dawajx = speed * (x_coord - _x);
dawajy = speed * (y_coord - _y);
_x = (_x + dawajx);
_y = (_y + dawajy);
_rotation = _root.getAngle(_x, _y, _root._xmouse, _root._ymouse);
if (_root.fence.hitTest(this._x, this._y, true)) {
dawajx = -dawajx;
dawajy = -dawajy;
_x = (_x + dawajx);
_y = (_y + dawajy);
}
}
}
onClipEvent (mouseDown) {
_global.zasieg = 300;
this.gotoAndStop(2);
}
onClipEvent (mouseUp) {
_global.zasieg = 100;
this.gotoAndStop(1);
}
Instance of Symbol 169 MovieClip in Frame 182
onClipEvent (enterFrame) {
if (((((((_root.target.hitTest(_root.owca1._x, _root.owca1._y, true) == true) && (_root.target.hitTest(_root.owca2._x, _root.owca2._y, true) == true)) && (_root.target.hitTest(_root.owca3._x, _root.owca3._y, true) == true)) && (_root.target.hitTest(_root.owca4._x, _root.owca4._y, true) == true)) && (_root.target.hitTest(_root.owca5._x, _root.owca5._y, true) == true)) && (_root.target.hitTest(_root.owca6._x, _root.owca6._y, true) == true)) && (_root.target.hitTest(_root.owca7._x, _root.owca7._y, true) == true)) {
_global.counter_timp_l++;
}
if (_global.counter_timp_l == 1) {
_global.time_l = _global.counter_l;
}
if (_global.time_l > 1200) {
_root.playAgain.gotoAndPlay("level_time");
_root.playAgain._x = 305;
_root.playAgain._y = 250;
} else if ((_global.time_l <= 1200) && (_global.counter_timp_l > 0)) {
_global.nextlevel = 1;
_root.napis._x = 300;
_root.napis._y = 200;
}
if (_global.licznikend > 0) {
_global.licznikend--;
}
if (_global.licznikend == 0) {
_root.playAgain.gotoAndStop("dead_sheep");
_root.playAgain._x = 305;
_root.playAgain._y = 250;
}
}
Instance of Symbol 183 MovieClip in Frame 182
on (press, keyPress "m") {
klawisz = 1;
if ((_global.muzagra == 1) && (klawisz == 1)) {
klawisz = 0;
_global.muzagra = 0;
stopAllSounds();
}
if ((_global.muzagra == 0) && (klawisz == 1)) {
klawisz = 0;
_global.muzagra = 1;
_global.music.start(0, 25000);
}
}
Instance of Symbol 187 MovieClip "napis" in Frame 182
on (keyPress "<Space>") {
removeMovieClip(this);
}
Instance of Symbol 181 MovieClip in Frame 182
onClipEvent (load) {
duplicateMovieClip (_root.owca, "owca1", 100);
duplicateMovieClip (_root.owca, "owca2", 101);
duplicateMovieClip (_root.owca, "owca3", 102);
duplicateMovieClip (_root.owca, "owca4", 103);
duplicateMovieClip (_root.owca, "owca5", 104);
duplicateMovieClip (_root.owca, "owca6", 105);
duplicateMovieClip (_root.owca, "owca7", 106);
i = 1;
while (i < 8) {
_root["owca" + i]._x = random(40) + 400;
_root["owca" + i]._y = random(200) + 40;
z = 99 + i;
_global["ustalkier" + z] = 1;
_global["zyje" + z] = 1;
_global["popraw" + z] = 1;
i++;
}
}
Instance of Symbol 163 MovieClip "owca" in Frame 182
onClipEvent (enterFrame) {
if (_global.pause_var != 1) {
glebia = this.getDepth();
if ((this._y > 0) && (_global["zyje" + glebia] == 1)) {
_global.beelicznik--;
glebia = this.getDepth();
dx = _x - _root.boy._x;
dy = _y - _root.boy._y;
hyp = Math.sqrt((dx * dx) + (dy * dy));
if ((hyp < _global.zasieg) && (_global["popraw" + glebia] == 1)) {
if (_global.beelicznik <= 0) {
_global.bee.start();
_global.beelicznik = 1000;
}
speed = (5 * Math.pow((_global.zasieg - hyp) / 100, 3)) + 3;
if (_global.zasieg > 100) {
speed = speed / 8;
}
if ((((this._x > 20) && (this._x < 580)) && (this._y > 20)) && (this._y < 480)) {
_global["zmianax" + glebia] = (speed * dx) / hyp;
_global["zmianay" + glebia] = (speed * dy) / hyp;
if (_global["zmianax" + glebia] > 5) {
_global["zmianax" + glebia] = 5;
}
if (_global["zmianay" + glebia] > 5) {
_global["zmianay" + glebia] = 5;
}
}
}
if (_root.fence.hitTest(this._x, this._y, true)) {
_global["zmianax" + glebia] = -(1.5 * _global["zmianax" + glebia]);
_global["zmianay" + glebia] = -(1.5 * _global["zmianay" + glebia]);
this._x = this._x + (_global["zmianax" + glebia] + oddx);
this._y = this._y + (_global["zmianay" + glebia] + oddy);
this._x = this._x + (_global["zmianax" + glebia] + oddx);
this._y = this._y + (_global["zmianay" + glebia] + oddy);
}
if (_root.fence2.hitTest(this._x, this._y, true)) {
_global["zmianax" + glebia] = -(1.3 * _global["zmianax" + glebia]);
_global["zmianay" + glebia] = -(1.3 * _global["zmianay" + glebia]);
this._x = this._x + (_global["zmianax" + glebia] + oddx);
this._y = this._y + (_global["zmianay" + glebia] + oddy);
this._x = this._x + (_global["zmianax" + glebia] + oddx);
this._y = this._y + (_global["zmianay" + glebia] + oddy);
}
if (_root.target.hitTest(this._x, this._y, true)) {
_global["zmianax" + glebia] = 0.1 * _global["zmianax" + glebia];
_global["zmianay" + glebia] = 0.1 * _global["zmianay" + glebia];
}
if (_root.woda.hitTest(this._x, this._y, true)) {
this.gotoAndStop(2);
_global["zyje" + glebia] = 0;
_global.licznikend = 30;
}
if (_global["ustalkier" + glebia] == 1) {
_global["ustalkier" + glebia] = 0;
_global["zmianax" + glebia] = random(2) - 0.5;
_global["zmianay" + glebia] = random(2) - 0.5;
_global["zmianax" + glebia] = _global["zmianax" + glebia] + 0.1;
_global["zmianay" + glebia] = _global["zmianay" + glebia] + 0.1;
}
if ((Math.abs(_global["zmianax" + glebia]) > 0.25) && (Math.abs(_global["zmianay" + glebia]) > 0.25)) {
_global["zmianax" + glebia] = _global["zmianax" + glebia] * 0.97;
_global["zmianay" + glebia] = _global["zmianay" + glebia] * 0.97;
}
_rotation = _root.getAngle(_x, _y, _x + _global["zmianax" + glebia], _y + _global["zmianay" + glebia]);
this._x = this._x + ((_global["zmianax" + glebia] + oddx) * _global["popraw" + glebia]);
this._y = this._y + ((_global["zmianay" + glebia] + oddy) * _global["popraw" + glebia]);
if ((_x < 20) && (_global["zmianax" + glebia] < 0)) {
_global["zmianax" + glebia] = (-_global["zmianax" + glebia]) + 0.1;
this._x = this._x + (_global["zmianax" + glebia] + oddx);
this._y = this._y + (_global["zmianay" + glebia] + oddy);
}
if ((_x > 580) && (_global["zmianax" + glebia] > 0)) {
_global["zmianax" + glebia] = (-_global["zmianax" + glebia]) + 0.1;
this._x = this._x + (_global["zmianax" + glebia] + oddx);
this._y = this._y + (_global["zmianay" + glebia] + oddy);
}
if ((_y < 20) && (_global["zmianay" + glebia] < 0)) {
_global["zmianay" + glebia] = (-_global["zmianay" + glebia]) + 0.1;
this._x = this._x + (_global["zmianax" + glebia] + oddx);
this._y = this._y + (_global["zmianay" + glebia] + oddy);
}
if ((_y > 480) && (_global["zmianay" + glebia] > 0)) {
_global["zmianay" + glebia] = (-_global["zmianay" + glebia]) + 0.1;
this._x = this._x + (_global["zmianax" + glebia] + oddx);
this._y = this._y + (_global["zmianay" + glebia] + oddy);
}
}
}
}
Instance of Symbol 207 MovieClip "playAgain" in Frame 182
on (release) {
_global.time_l = 0;
removeMovieClip(_root.owca1);
removeMovieClip(_root.owca2);
removeMovieClip(_root.owca3);
removeMovieClip(_root.owca4);
removeMovieClip(_root.owca5);
removeMovieClip(_root.owca6);
removeMovieClip(_root.owca7);
removeMovieClip(_root.woda);
removeMovieClip(_root.fence);
removeMovieClip(_root.fence2);
_root.themenu.removeMovieClip();
removeMovieClip(this);
_root.toGo = "level5";
_root.gotoAndStop("golevel5");
}
Instance of Symbol 264 MovieClip "replay_the_game" in Frame 182
on (release) {
_global.time_l = 0;
removeMovieClip(_root.owca1);
removeMovieClip(_root.owca2);
removeMovieClip(_root.owca3);
removeMovieClip(_root.owca4);
removeMovieClip(_root.tree1);
removeMovieClip(_root.pool);
_root.themenu.removeMovieClip();
_root.toGo = "level5";
_root.gotoAndStop("golevel5");
}
Frame 183
_global.level = 6;
removeMovieClip(_root.owca1);
removeMovieClip(_root.owca2);
removeMovieClip(_root.owca3);
removeMovieClip(_root.owca4);
removeMovieClip(_root.owca5);
removeMovieClip(_root.owca6);
removeMovieClip(_root.owca7);
_root.playAgain.swapDepths(10000);
_root.final_joc.swapDepths(90000);
_root.playAgain._x = -446.2;
_root.playAgain._y = 526;
_root.replay_the_game._x = 500;
_root.replay_the_game._y = 118.6;
_global.level = 1;
var timerS_l:String;
var timerM_l:String;
folderM_l = 0;
_global.counter_timp_l = 0;
_global.counter_l = 0;
_global.count_sec = 0;
onEnterFrame = function () {
var _local1 = _global;
if (_local1.pause_var != 1) {
sunet_clock = new Sound();
sunet_clock.attachSound("clocksound");
sunet_end = new Sound();
sunet_end.attachSound("endsound");
if ((_local1.counter_l < 1200) && (((_local1.counter_l / 20) - Math.round(_local1.counter_l / 20)) == 0)) {
sunet_clock.start();
} else if ((_local1.counter_l >= 1200) && (_local1.counter_l <= 1210)) {
_root.blip.gotoAndPlay(2);
sunet_end.start();
}
if ((_local1.licznikend != 0) && (_local1.counter_timp_l < 1)) {
_local1.counter_l++;
if (_local1.counter_l == 1200) {
_root.replay_the_game.gotoAndPlay(2);
}
}
folderS_l = Math.ceil((counter_l - (1200 * _local1.count_sec)) / 20) - 1;
if (folderS_l < 10) {
timerS_l = "0" + folderS_l.toString();
} else {
timerS_l = folderS_l.toString();
}
if ((Math.round(counter_l / 1200) - (counter_l / 1200)) == 0) {
folderM_l++;
_local1.count_sec++;
}
if (folderM_l < 10) {
timerM_l = "0" + folderM_l.toString();
} else {
timerM_l = folderM_l.toString();
}
}
};
stop();
stop();
_root.themenu.swapDepths(100000);
Instance of Symbol 181 MovieClip in Frame 183
onClipEvent (load) {
duplicateMovieClip (_root.owca, "owca1", 100);
duplicateMovieClip (_root.owca, "owca2", 101);
duplicateMovieClip (_root.owca, "owca3", 102);
duplicateMovieClip (_root.owca, "owca4", 103);
duplicateMovieClip (_root.owca, "owca5", 104);
duplicateMovieClip (_root.owca, "owca6", 105);
duplicateMovieClip (_root.owca, "owca7", 106);
duplicateMovieClip (_root.owca, "owca8", 107);
i = 1;
while (i < 9) {
_root["owca" + i]._x = random(400) + 40;
_root["owca" + i]._y = random(200) + 40;
z = 99 + i;
_global["ustalkier" + z] = 1;
_global["zyje" + z] = 1;
_global["popraw" + z] = 1;
i++;
}
}
Instance of Symbol 163 MovieClip "owca" in Frame 183
onClipEvent (enterFrame) {
if (_global.pause_var != 1) {
glebia = this.getDepth();
if ((this._y > 0) && (_global["zyje" + glebia] == 1)) {
_global.beelicznik--;
glebia = this.getDepth();
dx = _x - _root.boy._x;
dy = _y - _root.boy._y;
hyp = Math.sqrt((dx * dx) + (dy * dy));
if ((hyp < _global.zasieg) && (_global["popraw" + glebia] == 1)) {
if (_global.beelicznik <= 0) {
_global.bee.start();
_global.beelicznik = 1000;
}
speed = (5 * Math.pow((_global.zasieg - hyp) / 100, 3)) + 3;
if (_global.zasieg > 100) {
speed = speed / 8;
}
if ((((this._x > 20) && (this._x < 580)) && (this._y > 20)) && (this._y < 480)) {
_global["zmianax" + glebia] = (speed * dx) / hyp;
_global["zmianay" + glebia] = (speed * dy) / hyp;
if (_global["zmianax" + glebia] > 5) {
_global["zmianax" + glebia] = 5;
}
if (_global["zmianay" + glebia] > 5) {
_global["zmianay" + glebia] = 5;
}
}
}
if (_root.target.hitTest(this._x, this._y, true)) {
_global["zmianax" + glebia] = 0.4 * _global["zmianax" + glebia];
_global["zmianay" + glebia] = 0.4 * _global["zmianay" + glebia];
_global.fenced_sheep = 1;
}
dx = _x - _root.dog._x;
dy = _y - _root.dog._y;
hyp = Math.sqrt((dx * dx) + (dy * dy));
if ((hyp < _global.zasieg) && (_global["popraw" + glebia] == 1)) {
if (_global.fenced_sheep != 1) {
speed = (20 * Math.pow((100 - hyp) / 100, 3)) + 3;
}
if (_global.zasieg > 100) {
speed = speed / 8;
}
if ((((this._x > 20) && (this._x < 580)) && (this._y > 20)) && (this._y < 480)) {
_global["zmianax" + glebia] = (speed * dx) / hyp;
_global["zmianay" + glebia] = (speed * dy) / hyp;
if (_global["zmianax" + glebia] > 5) {
_global["zmianax" + glebia] = 5;
}
if (_global["zmianay" + glebia] > 5) {
_global["zmianay" + glebia] = 5;
}
}
}
dx = _x - _root.boy._x;
dy = _y - _root.boy._y;
hyp = Math.sqrt((dx * dx) + (dy * dy));
if (_root.fence.hitTest(this._x, this._y, true)) {
if (hyp < _global.zasieg) {
_global["popraw" + glebia] = 0;
} else {
_global["popraw" + glebia] = 1;
_global["zmianax" + glebia] = -(1.5 * _global["zmianax" + glebia]);
_global["zmianay" + glebia] = -(1.5 * _global["zmianay" + glebia]);
this._x = this._x + (_global["zmianax" + glebia] + oddx);
this._y = this._y + (_global["zmianay" + glebia] + oddy);
}
}
if (_root.woda.hitTest(this._x, this._y, true)) {
this.gotoAndStop(2);
_global["zyje" + glebia] = 0;
_global.licznikend = 30;
}
if (_root.fence2.hitTest(this._x, this._y, true)) {
if (hyp < _global.zasieg) {
_global["popraw" + glebia] = 0;
} else {
_global["popraw" + glebia] = 1;
_global["zmianax" + glebia] = -_global["zmianax" + glebia];
_global["zmianay" + glebia] = -_global["zmianay" + glebia];
this._x = this._x + (_global["zmianax" + glebia] + oddx);
this._y = this._y + (_global["zmianay" + glebia] + oddy);
}
}
if (_root.woda.hitTest(this._x, this._y, true)) {
this.gotoAndStop(2);
_global["zyje" + glebia] = 0;
_global.licznikend = 30;
}
if (_global["ustalkier" + glebia] == 1) {
_global["ustalkier" + glebia] = 0;
_global["zmianax" + glebia] = random(2) - 0.5;
_global["zmianay" + glebia] = random(2) - 0.5;
_global["zmianax" + glebia] = _global["zmianax" + glebia] + 0.1;
_global["zmianay" + glebia] = _global["zmianay" + glebia] + 0.1;
}
if ((Math.abs(_global["zmianax" + glebia]) > 0.25) && (Math.abs(_global["zmianay" + glebia]) > 0.25)) {
_global["zmianax" + glebia] = _global["zmianax" + glebia] * 0.97;
_global["zmianay" + glebia] = _global["zmianay" + glebia] * 0.97;
}
_rotation = _root.getAngle(_x, _y, _x + _global["zmianax" + glebia], _y + _global["zmianay" + glebia]);
this._x = this._x + ((_global["zmianax" + glebia] + oddx) * _global["popraw" + glebia]);
this._y = this._y + ((_global["zmianay" + glebia] + oddy) * _global["popraw" + glebia]);
if ((_x < 20) && (_global["zmianax" + glebia] < 0)) {
_global["zmianax" + glebia] = (-_global["zmianax" + glebia]) + 0.1;
this._x = this._x + (_global["zmianax" + glebia] + oddx);
this._y = this._y + (_global["zmianay" + glebia] + oddy);
}
if ((_x > 580) && (_global["zmianax" + glebia] > 0)) {
_global["zmianax" + glebia] = -_global["zmianax" + glebia];
this._x = this._x + (_global["zmianax" + glebia] + oddx);
this._y = this._y + (_global["zmianay" + glebia] + oddy);
}
if ((_y < 20) && (_global["zmianay" + glebia] < 0)) {
_global["zmianay" + glebia] = (-_global["zmianay" + glebia]) + 0.1;
this._x = this._x + (_global["zmianax" + glebia] + oddx);
this._y = this._y + (_global["zmianay" + glebia] + oddy);
}
if ((_y > 480) && (_global["zmianay" + glebia] > 0)) {
_global["zmianay" + glebia] = -_global["zmianay" + glebia];
this._x = this._x + (_global["zmianax" + glebia] + oddx);
this._y = this._y + (_global["zmianay" + glebia] + oddy);
}
}
}
}
Instance of Symbol 189 MovieClip "tree1" in Frame 183
onClipEvent (load) {
this.swapDepths(300);
}
Instance of Symbol 189 MovieClip "tree2" in Frame 183
onClipEvent (load) {
this.swapDepths(301);
}
Instance of Symbol 179 MovieClip "boy" in Frame 183
onClipEvent (load) {
_global.speed = 0.1;
_global.nextlevel = 0;
_global.nowapauza = 1;
_global.punkty = 0;
_global.zasieg = 100;
_global.licznikend = -10;
}
onClipEvent (enterFrame) {
if (_global.pause_var != 1) {
if ((Math.abs(_xmouse - this._x) < 2000) && (Math.abs(_ymouse - this._y) < 2000)) {
x_coord = _root._xmouse;
y_coord = _root._ymouse;
if (x_coord <= 0) {
x_coord = 0;
}
if (y_coord <= 0) {
y_coord = 0;
}
if (x_coord >= 600) {
x_coord = 600;
}
if (y_coord >= 500) {
y_coord = 500;
}
}
dawajx = speed * (x_coord - _x);
dawajy = speed * (y_coord - _y);
_x = (_x + dawajx);
_y = (_y + dawajy);
_rotation = _root.getAngle(_x, _y, _root._xmouse, _root._ymouse);
if (_root.fence2.hitTest(this._x, this._y, true)) {
dawajx = -dawajx;
dawajy = -dawajy;
_x = (_x + dawajx);
_y = (_y + dawajy);
}
}
}
Instance of Symbol 169 MovieClip in Frame 183
onClipEvent (enterFrame) {
if ((((((((_root.target.hitTest(_root.owca1._x, _root.owca1._y, true) == true) && (_root.target.hitTest(_root.owca2._x, _root.owca2._y, true) == true)) && (_root.target.hitTest(_root.owca3._x, _root.owca3._y, true) == true)) && (_root.target.hitTest(_root.owca4._x, _root.owca4._y, true) == true)) && (_root.target.hitTest(_root.owca5._x, _root.owca5._y, true) == true)) && (_root.target.hitTest(_root.owca6._x, _root.owca6._y, true) == true)) && (_root.target.hitTest(_root.owca7._x, _root.owca7._y, true) == true)) && (_root.target.hitTest(_root.owca8._x, _root.owca8._y, true) == true)) {
_global.counter_timp_l++;
}
if (_global.counter_timp_l == 1) {
_global.time_l = _global.counter_l;
}
if (_global.time_l > 1200) {
_root.playAgain.gotoAndPlay("level_time");
_root.playAgain._x = 305;
_root.playAgain._y = 250;
} else if ((_global.time_l <= 1200) && (_global.counter_timp_l > 0)) {
_global.nextlevel = 1;
if (_global.nextlevel == 1) {
_global.nextlevel = 0;
_root.final_joc._x = 324;
_root.final_joc._y = 230;
removeMovieClip(_root.playAgain);
_root.themenu.removeMovieClip();
_global.skonczyl = 1;
gotoAndPlay (176);
}
}
if (_global.licznikend > 0) {
_global.licznikend--;
}
if (_global.licznikend == 0) {
_root.playAgain.gotoAndStop("dead_sheep");
_root.playAgain._x = 305;
_root.playAgain._y = 250;
}
}
Instance of Symbol 183 MovieClip in Frame 183
on (press, keyPress "m") {
klawisz = 1;
if ((_global.muzagra == 1) && (klawisz == 1)) {
klawisz = 0;
_global.muzagra = 0;
stopAllSounds();
}
if ((_global.muzagra == 0) && (klawisz == 1)) {
klawisz = 0;
_global.muzagra = 1;
_global.music.start(0, 25000);
}
}
Instance of Symbol 187 MovieClip "napis" in Frame 183
on (keyPress "<Space>") {
removeMovieClip(this);
}
Instance of Symbol 341 MovieClip "dog" in Frame 183
onClipEvent (load) {
_global.kierx = 4;
_global.kiery = 4;
}
onClipEvent (enterFrame) {
if (_global.pause_var != 1) {
this._x = this._x + _global.kierx;
this._y = this._y + _global.kiery;
_rotation = _root.getAngle(_x, _y, _x + _global.kierx, _y + _global.kiery);
if ((this._y > 470) && (_global.kiery > 0)) {
_global.kierx = _global.kierx + (random(2) - 1);
_global.kiery = -_global.kiery;
}
if ((this._y < 30) && (_global.kiery < 0)) {
_global.kierx = _global.kierx + (random(2) - 1);
_global.kiery = -_global.kiery;
}
if ((this._x > 570) && (_global.kierx > 0)) {
_global.kiery = _global.kiery + (random(2) - 1);
_global.kierx = -_global.kierx;
}
if ((this._x < 30) && (_global.kierx < 0)) {
_global.kiery = _global.kiery + (random(2) - 1);
_global.kierx = -_global.kierx;
}
if (_root.fence2.hitTest(this._x, this._y, true)) {
_global.kierx = -_global.kierx;
_global.kiery = -_global.kiery;
_x = (_x + _global.kierx);
_y = (_y + _global.kiery);
}
if (_root.woda.hitTest(this._x, this._y, true)) {
_global.kierx = -_global.kierx;
_global.kiery = -_global.kiery;
_x = (_x + _global.kierx);
_y = (_y + _global.kiery);
}
}
}
Instance of Symbol 207 MovieClip "playAgain" in Frame 183
on (release) {
_global.time_l = 0;
removeMovieClip(_root.owca1);
removeMovieClip(_root.owca2);
removeMovieClip(_root.owca3);
removeMovieClip(_root.owca4);
removeMovieClip(_root.owca5);
removeMovieClip(_root.owca6);
removeMovieClip(_root.owca7);
removeMovieClip(_root.owca8);
removeMovieClip(_root.tree1);
removeMovieClip(_root.tree2);
removeMovieClip(_root.woda);
removeMovieClip(_root.fence2);
_root.themenu.removeMovieClip();
removeMovieClip(this);
_root.toGo = "level6";
_root.gotoAndStop("golevel6");
}
Instance of Symbol 264 MovieClip "replay_the_game" in Frame 183
on (release) {
_global.time_l = 0;
removeMovieClip(_root.owca1);
removeMovieClip(_root.owca2);
removeMovieClip(_root.owca3);
removeMovieClip(_root.owca4);
removeMovieClip(_root.tree1);
removeMovieClip(_root.pool);
removeMovieClip(_root.final_joc);
_root.themenu.removeMovieClip();
_root.toGo = "level6";
_root.gotoAndStop("golevel6");
}
Frame 184
removeMovieClip(_root.owca1);
removeMovieClip(_root.owca2);
removeMovieClip(_root.owca3);
removeMovieClip(_root.tree1);
removeMovieClip(_root.tree2);
removeMovieClip(_root.napis);
removeMovieClip(_root.playAgain);
_root.gotoAndStop(_root.toGo);
stop();
Frame 185
removeMovieClip(_root.owca1);
removeMovieClip(_root.owca2);
removeMovieClip(_root.owca3);
removeMovieClip(_root.owca4);
removeMovieClip(_root.tree1);
removeMovieClip(_root.napis);
removeMovieClip(_root.playAgain);
_root.gotoAndStop(_root.toGo);
stop();
Frame 186
removeMovieClip(_root.owca1);
removeMovieClip(_root.owca2);
removeMovieClip(_root.owca3);
removeMovieClip(_root.owca4);
removeMovieClip(_root.owca5);
removeMovieClip(_root.napis);
removeMovieClip(_root.playAgain);
_root.gotoAndStop(_root.toGo);
stop();
Frame 187
removeMovieClip(_root.owca1);
removeMovieClip(_root.owca2);
removeMovieClip(_root.owca3);
removeMovieClip(_root.owca4);
removeMovieClip(_root.owca5);
removeMovieClip(_root.owca6);
removeMovieClip(_root.tree1);
removeMovieClip(_root.napis);
removeMovieClip(_root.playAgain);
_root.gotoAndStop(_root.toGo);
stop();
Frame 188
removeMovieClip(_root.owca1);
removeMovieClip(_root.owca2);
removeMovieClip(_root.owca3);
removeMovieClip(_root.owca4);
removeMovieClip(_root.owca5);
removeMovieClip(_root.owca6);
removeMovieClip(_root.owca7);
removeMovieClip(_root.napis);
removeMovieClip(_root.playAgain);
_root.gotoAndStop(_root.toGo);
stop();
Frame 189
removeMovieClip(_root.owca1);
removeMovieClip(_root.owca2);
removeMovieClip(_root.owca3);
removeMovieClip(_root.owca4);
removeMovieClip(_root.owca5);
removeMovieClip(_root.owca6);
removeMovieClip(_root.owca7);
removeMovieClip(_root.owca8);
removeMovieClip(_root.tree1);
removeMovieClip(_root.tree2);
removeMovieClip(_root.napis);
_root.gotoAndStop(_root.toGo);
stop();
Symbol 8 Button
on (release) {
getURL ("http://www.freeonlinegames.com/?LittleShepherd", "_blank");
}
Symbol 12 MovieClip Frame 1
stop();
Symbol 23 MovieClip Frame 1
stop();
Symbol 33 MovieClip Frame 50
stop();
_parent.play();
Symbol 74 MovieClip Frame 1
stop();
Symbol 74 MovieClip Frame 28
gotoAndPlay ("loop");
Symbol 80 Button
on (release) {
targetul1 = ("http://www.freeonlinegames.com/downloads/" + _parent.wynume) + ".exe";
getURL (targetul1);
}
Symbol 88 MovieClip Frame 1
stop();
if (_parent.wyaliniere == "Centru") {
this.gotoAndStop(2);
}
if (_parent.wyaliniere == "Dreapta") {
this.gotoAndStop(3);
}
Symbol 88 MovieClip Frame 2
wxculoarea2 = new Color(but1);
myColorTransform = new Object();
myColorTransform = {ra:"100", rb:_parent.xrtb5, ga:"100", gb:_parent.xgtb5, ba:"100", bb:_parent.xbtb5, aa:"100", ab:"0"};
wxculoarea2.setTransform(myColorTransform);
Symbol 88 MovieClip Frame 3
wxculoarea2 = new Color(but1);
myColorTransform = new Object();
myColorTransform = {ra:"100", rb:_parent.xrtb5, ga:"100", gb:_parent.xgtb5, ba:"100", bb:_parent.xbtb5, aa:"100", ab:"0"};
wxculoarea2.setTransform(myColorTransform);
Symbol 89 Button
on (release) {
targetul2 = "http://www.freeonlinegames.com/?" + _parent.wynume;
getURL (targetul2, "_blank");
}
Symbol 96 MovieClip Frame 1
stop();
if (_parent.wyaliniere == "Centru") {
this.gotoAndStop(2);
}
if (_parent.wyaliniere == "Dreapta") {
this.gotoAndStop(3);
}
Symbol 96 MovieClip Frame 2
wxculoarea2 = new Color(but2);
myColorTransform = new Object();
myColorTransform = {ra:"100", rb:_parent.xrtb5, ga:"100", gb:_parent.xgtb5, ba:"100", bb:_parent.xbtb5, aa:"100", ab:"0"};
wxculoarea2.setTransform(myColorTransform);
Symbol 96 MovieClip Frame 3
wxculoarea2 = new Color(but2);
myColorTransform = new Object();
myColorTransform = {ra:"100", rb:_parent.xrtb5, ga:"100", gb:_parent.xgtb5, ba:"100", bb:_parent.xbtb5, aa:"100", ab:"0"};
wxculoarea2.setTransform(myColorTransform);
Symbol 97 Button
on (release) {
targetul3 = "http://www.freegamesforyourwebsite.com/?" + _parent.wynume;
getURL (targetul3, "_blank");
}
Symbol 100 MovieClip Frame 1
stop();
if (_parent.wyaliniere == "Centru") {
this.gotoAndStop(2);
}
if (_parent.wyaliniere == "Dreapta") {
this.gotoAndStop(3);
}
Symbol 100 MovieClip Frame 2
wxculoarea2 = new Color(but3);
myColorTransform = new Object();
myColorTransform = {ra:"100", rb:_parent.xrtb5, ga:"100", gb:_parent.xgtb5, ba:"100", bb:_parent.xbtb5, aa:"100", ab:"0"};
wxculoarea2.setTransform(myColorTransform);
Symbol 100 MovieClip Frame 3
wxculoarea2 = new Color(but3);
myColorTransform = new Object();
myColorTransform = {ra:"100", rb:_parent.xrtb5, ga:"100", gb:_parent.xgtb5, ba:"100", bb:_parent.xbtb5, aa:"100", ab:"0"};
wxculoarea2.setTransform(myColorTransform);
Symbol 105 Button
on (release) {
targetul1 = ("http://www.freeonlinegames.com/downloads/" + _parent.wynume) + ".exe";
getURL (targetul1);
}
Symbol 106 MovieClip Frame 1
stop();
Symbol 109 Button
on (release) {
targetul2 = "http://www.freeonlinegames.com/?" + _parent.wynume;
getURL (targetul2);
}
Symbol 110 Button
on (release) {
targetul2 = "http://www.freeonlinegames.com/?" + _parent.wynume;
getURL (targetul2);
}
Symbol 111 MovieClip Frame 1
stop();
Symbol 112 Button
on (release, keyPress "p") {
_parent.instructionsFunction();
}
Symbol 119 MovieClip Frame 1
stop();
if (_parent.wyaliniere == "Centru") {
this.gotoAndStop(2);
}
if (_parent.wyaliniere == "Dreapta") {
this.gotoAndStop(3);
}
Symbol 119 MovieClip Frame 2
wxculoarea2 = new Color(but4);
myColorTransform = new Object();
myColorTransform = {ra:"100", rb:_parent.xrtb5, ga:"100", gb:_parent.xgtb5, ba:"100", bb:_parent.xbtb5, aa:"100", ab:"0"};
wxculoarea2.setTransform(myColorTransform);
Symbol 119 MovieClip Frame 3
wxculoarea2 = new Color(but4);
myColorTransform = new Object();
myColorTransform = {ra:"100", rb:_parent.xrtb5, ga:"100", gb:_parent.xgtb5, ba:"100", bb:_parent.xbtb5, aa:"100", ab:"0"};
wxculoarea2.setTransform(myColorTransform);
Symbol 120 Button
on (release, keyPress "p") {
_parent.instructionsFunction();
}
Symbol 121 MovieClip Frame 1
stop();
Symbol 122 MovieClip Frame 1
function instructionsFunction() {
var _local1 = _root;
_local1.instructions._x = 352;
_local1.instructions._y = 250;
_local1.theMenu._visible = false;
}
stop();
if ((wyasezare == "Orizontal") && (wyinstructions == false)) {
this.gotoAndStop(2);
}
if (((wyasezare == "Vertical") && (wyinstructions == true)) && (wypozitie == "Sus")) {
this.gotoAndStop(3);
}
if (((wyasezare == "Vertical") && (wyinstructions == true)) && (wypozitie == "Jos")) {
this.gotoAndStop(4);
}
if (((wyasezare == "Orizontal") && (wyinstructions == true)) && (wypozitie == "Sus")) {
this.gotoAndStop(5);
}
if (((wyasezare == "Orizontal") && (wyinstructions == true)) && (wypozitie == "Jos")) {
this.gotoAndStop(6);
}
my_color = new Color(my_mc);
my_color.setRGB(wyculoare);
myValue = my_color.getRGB().toString(16);
trace(myValue.length);
if (myValue.length == 5) {
myValue = "0" + myValue;
}
if (myValue.length == 4) {
myValue = "00" + myValue;
}
if (myValue.length == 3) {
myValue = "000" + myValue;
}
if (myValue.length == 2) {
myValue = "0000" + myValue;
}
if (myValue.length == 1) {
myValue = "00000" + myValue;
}
xtbcolor = myValue;
xrtb5 = Number("0x" + xtbcolor.slice(0, 2)) - 1;
xgtb5 = Number("0x" + xtbcolor.slice(2, 4)) - 1;
xbtb5 = Number("0x" + xtbcolor.slice(4, 6)) - 1;
wxculoarea2 = new Color(wynbut1.but1);
wxculoarea3 = new Color(wynbut2.but2);
wxculoarea4 = new Color(wynbut3.but3);
wxculoarea5 = new Color(wynbut4.but4);
myColorTransform = new Object();
myColorTransform = {ra:"100", rb:xrtb5, ga:"100", gb:xgtb5, ba:"100", bb:xbtb5, aa:"100", ab:"0"};
wxculoarea2.setTransform(myColorTransform);
wxculoarea3.setTransform(myColorTransform);
wxculoarea4.setTransform(myColorTransform);
wxculoarea5.setTransform(myColorTransform);
Symbol 122 MovieClip Frame 2
stop();
my_color = new Color(my_mc);
my_color.setRGB(wyculoare);
myValue = my_color.getRGB().toString(16);
trace(myValue.length);
if (myValue.length == 5) {
myValue = "0" + myValue;
}
if (myValue.length == 4) {
myValue = "00" + myValue;
}
if (myValue.length == 3) {
myValue = "000" + myValue;
}
if (myValue.length == 2) {
myValue = "0000" + myValue;
}
if (myValue.length == 1) {
myValue = "00000" + myValue;
}
xtbcolor = myValue;
xrtb5 = Number("0x" + xtbcolor.slice(0, 2)) - 1;
xgtb5 = Number("0x" + xtbcolor.slice(2, 4)) - 1;
xbtb5 = Number("0x" + xtbcolor.slice(4, 6)) - 1;
wxculoarea2 = new Color(wynbut1.but1);
wxculoarea3 = new Color(wynbut2.but2);
wxculoarea4 = new Color(wynbut3.but3);
wxculoarea5 = new Color(wynbut4.but4);
myColorTransform = new Object();
myColorTransform = {ra:"100", rb:xrtb5, ga:"100", gb:xgtb5, ba:"100", bb:xbtb5, aa:"100", ab:"0"};
wxculoarea2.setTransform(myColorTransform);
wxculoarea3.setTransform(myColorTransform);
wxculoarea4.setTransform(myColorTransform);
wxculoarea5.setTransform(myColorTransform);
Symbol 122 MovieClip Frame 3
stop();
my_color = new Color(my_mc);
my_color.setRGB(wyculoare);
myValue = my_color.getRGB().toString(16);
trace(myValue.length);
if (myValue.length == 5) {
myValue = "0" + myValue;
}
if (myValue.length == 4) {
myValue = "00" + myValue;
}
if (myValue.length == 3) {
myValue = "000" + myValue;
}
if (myValue.length == 2) {
myValue = "0000" + myValue;
}
if (myValue.length == 1) {
myValue = "00000" + myValue;
}
xtbcolor = myValue;
xrtb5 = Number("0x" + xtbcolor.slice(0, 2)) - 1;
xgtb5 = Number("0x" + xtbcolor.slice(2, 4)) - 1;
xbtb5 = Number("0x" + xtbcolor.slice(4, 6)) - 1;
wxculoarea2 = new Color(wynbut1.but1);
wxculoarea3 = new Color(wynbut2.but2);
wxculoarea4 = new Color(wynbut3.but3);
wxculoarea5 = new Color(wynbut4.but4);
myColorTransform = new Object();
myColorTransform = {ra:"100", rb:xrtb5, ga:"100", gb:xgtb5, ba:"100", bb:xbtb5, aa:"100", ab:"0"};
wxculoarea2.setTransform(myColorTransform);
wxculoarea3.setTransform(myColorTransform);
wxculoarea4.setTransform(myColorTransform);
wxculoarea5.setTransform(myColorTransform);
Symbol 122 MovieClip Frame 4
stop();
my_color = new Color(my_mc);
my_color.setRGB(wyculoare);
myValue = my_color.getRGB().toString(16);
trace(myValue.length);
if (myValue.length == 5) {
myValue = "0" + myValue;
}
if (myValue.length == 4) {
myValue = "00" + myValue;
}
if (myValue.length == 3) {
myValue = "000" + myValue;
}
if (myValue.length == 2) {
myValue = "0000" + myValue;
}
if (myValue.length == 1) {
myValue = "00000" + myValue;
}
xtbcolor = myValue;
xrtb5 = Number("0x" + xtbcolor.slice(0, 2)) - 1;
xgtb5 = Number("0x" + xtbcolor.slice(2, 4)) - 1;
xbtb5 = Number("0x" + xtbcolor.slice(4, 6)) - 1;
wxculoarea2 = new Color(wynbut1.but1);
wxculoarea3 = new Color(wynbut2.but2);
wxculoarea4 = new Color(wynbut3.but3);
wxculoarea5 = new Color(wynbut4.but4);
myColorTransform = new Object();
myColorTransform = {ra:"100", rb:xrtb5, ga:"100", gb:xgtb5, ba:"100", bb:xbtb5, aa:"100", ab:"0"};
wxculoarea2.setTransform(myColorTransform);
wxculoarea3.setTransform(myColorTransform);
wxculoarea4.setTransform(myColorTransform);
wxculoarea5.setTransform(myColorTransform);
Symbol 122 MovieClip Frame 5
stop();
my_color = new Color(my_mc);
my_color.setRGB(wyculoare);
myValue = my_color.getRGB().toString(16);
trace(myValue.length);
if (myValue.length == 5) {
myValue = "0" + myValue;
}
if (myValue.length == 4) {
myValue = "00" + myValue;
}
if (myValue.length == 3) {
myValue = "000" + myValue;
}
if (myValue.length == 2) {
myValue = "0000" + myValue;
}
if (myValue.length == 1) {
myValue = "00000" + myValue;
}
xtbcolor = myValue;
xrtb5 = Number("0x" + xtbcolor.slice(0, 2)) - 1;
xgtb5 = Number("0x" + xtbcolor.slice(2, 4)) - 1;
xbtb5 = Number("0x" + xtbcolor.slice(4, 6)) - 1;
wxculoarea2 = new Color(wynbut1.but1);
wxculoarea3 = new Color(wynbut2.but2);
wxculoarea4 = new Color(wynbut3.but3);
wxculoarea5 = new Color(wynbut4.but4);
myColorTransform = new Object();
myColorTransform = {ra:"100", rb:xrtb5, ga:"100", gb:xgtb5, ba:"100", bb:xbtb5, aa:"100", ab:"0"};
wxculoarea2.setTransform(myColorTransform);
wxculoarea3.setTransform(myColorTransform);
wxculoarea4.setTransform(myColorTransform);
wxculoarea5.setTransform(myColorTransform);
Symbol 122 MovieClip Frame 6
stop();
my_color = new Color(my_mc);
my_color.setRGB(wyculoare);
myValue = my_color.getRGB().toString(16);
trace(myValue.length);
if (myValue.length == 5) {
myValue = "0" + myValue;
}
if (myValue.length == 4) {
myValue = "00" + myValue;
}
if (myValue.length == 3) {
myValue = "000" + myValue;
}
if (myValue.length == 2) {
myValue = "0000" + myValue;
}
if (myValue.length == 1) {
myValue = "00000" + myValue;
}
xtbcolor = myValue;
xrtb5 = Number("0x" + xtbcolor.slice(0, 2)) - 1;
xgtb5 = Number("0x" + xtbcolor.slice(2, 4)) - 1;
xbtb5 = Number("0x" + xtbcolor.slice(4, 6)) - 1;
wxculoarea2 = new Color(wynbut1.but1);
wxculoarea3 = new Color(wynbut2.but2);
wxculoarea4 = new Color(wynbut3.but3);
wxculoarea5 = new Color(wynbut4.but4);
myColorTransform = new Object();
myColorTransform = {ra:"100", rb:xrtb5, ga:"100", gb:xgtb5, ba:"100", bb:xbtb5, aa:"100", ab:"0"};
wxculoarea2.setTransform(myColorTransform);
wxculoarea3.setTransform(myColorTransform);
wxculoarea4.setTransform(myColorTransform);
wxculoarea5.setTransform(myColorTransform);
Symbol 130 Button
on (release) {
_root.instructions._x = -266;
_root.theMenu._visible = true;
}
Symbol 136 Button
on (release) {
gotoAndPlay (178);
}
Symbol 145 MovieClip Frame 1
stop();
Symbol 145 MovieClip Frame 2
stop();
Symbol 153 Button
on (release) {
getURL ("http://www.freeonlinegames.com/?LittleShepherd", "_blank");
}
Instance of Symbol 149 MovieClip in Symbol 154 MovieClip Frame 1
on (release) {
_global.music.stop();
removeMovieClip(_root.owca1);
removeMovieClip(_root.owca2);
removeMovieClip(_root.owca3);
removeMovieClip(_root.owca4);
removeMovieClip(_root.owca5);
removeMovieClip(_root.owca6);
removeMovieClip(_root.owca7);
removeMovieClip(_root.owca8);
removeMovieClip(_root.tree1);
removeMovieClip(_root.tree2);
removeMovieClip(_root.napis);
removeMovieClip(_root.woda);
removeMovieClip(_root.boy);
removeMovieClip(_root.dog);
removeMovieClip(_root.fence);
removeMovieClip(_root.target);
removeMovieClip(_root.final_joc);
removeMovieClip(_root.replay_the_game);
_root.gotoAndPlay("coperta");
}
Instance of Symbol 122 MovieClip in Symbol 154 MovieClip Frame 1
//component parameters
onClipEvent (initialize) {
wynume = "LittleShepherd";
wyculoare = 0;
wyasezare = "Vertical";
wyaliniere = "Stanga";
wypozitie = "Sus";
wyinstructions = false;
}
Symbol 163 MovieClip Frame 1
stop();
Symbol 163 MovieClip Frame 2
stop();
Symbol 165 MovieClip Frame 1
stop();
Symbol 165 MovieClip Frame 11
gotoAndPlay (2);
Symbol 171 Button
on (press, keyPress "<Space>") {
if (_global.nextlevel == 1) {
_global.nextlevel = 0;
removeMovieClip(_root.owca1);
removeMovieClip(_root.owca2);
removeMovieClip(_root.owca3);
removeMovieClip(_root.tree1);
removeMovieClip(_root.tree2);
removeMovieClip(_root.napis);
removeMovieClip(_root.playAgain);
removeMovieClip(_root.replay_the_game);
gotoAndPlay (179);
}
}
Symbol 179 MovieClip Frame 1
stop();
Symbol 179 MovieClip Frame 2
stop();
Symbol 179 MovieClip Frame 3
stop();
Symbol 207 MovieClip Frame 1
stop();
Symbol 207 MovieClip Frame 2
stop();
Symbol 207 MovieClip Frame 3
stop();
Symbol 211 Button
on (release) {
targetul3 = "http://www.freegamesforyourwebsite.com/?" + _parent.wxnume;
getURL (targetul3, "_blank");
}
Symbol 212 Button
on (release) {
targetul2 = "http://www.freeonlinegames.com/?" + _parent.wxnume;
getURL (targetul2, "_blank");
}
Symbol 213 Button
on (release) {
_parent.mainMenuFunction();
}
Symbol 214 Button
on (release) {
targetul1 = ("http://www.freeonlinegames.com/downloads/" + _parent.wxnume) + ".exe";
getURL (targetul1);
}
Symbol 215 Button
on (release, keyPress "p") {
_parent.pauseFunction();
}
Symbol 216 Button
on (release, keyPress "s") {
_parent.soundFunction();
}
Symbol 227 Button
on (release, keyPress "p") {
_parent.soundFunction();
}
Symbol 228 MovieClip Frame 1
stop();
wxculoarea3 = new Color(but1);
wxculoarea4 = new Color(but2);
wxculoarea5 = new Color(but3);
wxculoarea6 = new Color(but4);
wxculoarea7 = new Color(but5);
wxculoarea8 = new Color(but6);
myColorTransform2 = new Object();
myColorTransform2 = {ra:"100", rb:_parent.xrtb5, ga:"100", gb:_parent.xgtb5, ba:"100", bb:_parent.xbtb5, aa:"100", ab:"0"};
wxculoarea3.setTransform(myColorTransform2);
wxculoarea4.setTransform(myColorTransform2);
wxculoarea5.setTransform(myColorTransform2);
wxculoarea6.setTransform(myColorTransform2);
wxculoarea7.setTransform(myColorTransform2);
wxculoarea8.setTransform(myColorTransform2);
_parent.wxbutno = 6;
if (((_parent.wxdownload == false) && (_parent.wxpause == true)) && (_parent.wxsound == true)) {
this.gotoAndStop(2);
_parent.wxbutno = 5;
}
if (((_parent.wxdownload == true) && (_parent.wxpause == false)) && (_parent.wxsound == true)) {
this.gotoAndStop(3);
_parent.wxbutno = 5;
}
if (((_parent.wxdownload == true) && (_parent.wxpause == true)) && (_parent.wxsound == false)) {
this.gotoAndStop(4);
_parent.wxbutno = 5;
}
if (((_parent.wxdownload == false) && (_parent.wxpause == false)) && (_parent.wxsound == true)) {
this.gotoAndStop(5);
_parent.wxbutno = 4;
}
if (((_parent.wxdownload == false) && (_parent.wxpause == true)) && (_parent.wxsound == false)) {
this.gotoAndStop(6);
_parent.wxbutno = 4;
}
if (((_parent.wxdownload == true) && (_parent.wxpause == false)) && (_parent.wxsound == false)) {
this.gotoAndStop(7);
_parent.wxbutno = 4;
}
if (((_parent.wxdownload == false) && (_parent.wxpause == false)) && (_parent.wxsound == false)) {
this.gotoAndStop(8);
_parent.wxbutno = 3;
}
Symbol 228 MovieClip Frame 2
wxculoarea3 = new Color(but1);
wxculoarea4 = new Color(but2);
wxculoarea5 = new Color(but3);
wxculoarea6 = new Color(but4);
wxculoarea7 = new Color(but5);
wxculoarea8 = new Color(but6);
myColorTransform2 = new Object();
myColorTransform2 = {ra:"100", rb:_parent.xrtb5, ga:"100", gb:_parent.xgtb5, ba:"100", bb:_parent.xbtb5, aa:"100", ab:"0"};
wxculoarea3.setTransform(myColorTransform2);
wxculoarea4.setTransform(myColorTransform2);
wxculoarea5.setTransform(myColorTransform2);
wxculoarea6.setTransform(myColorTransform2);
wxculoarea7.setTransform(myColorTransform2);
wxculoarea8.setTransform(myColorTransform2);
Symbol 228 MovieClip Frame 3
wxculoarea3 = new Color(but1);
wxculoarea4 = new Color(but2);
wxculoarea5 = new Color(but3);
wxculoarea6 = new Color(but4);
wxculoarea7 = new Color(but5);
wxculoarea8 = new Color(but6);
myColorTransform2 = new Object();
myColorTransform2 = {ra:"100", rb:_parent.xrtb5, ga:"100", gb:_parent.xgtb5, ba:"100", bb:_parent.xbtb5, aa:"100", ab:"0"};
wxculoarea3.setTransform(myColorTransform2);
wxculoarea4.setTransform(myColorTransform2);
wxculoarea5.setTransform(myColorTransform2);
wxculoarea6.setTransform(myColorTransform2);
wxculoarea7.setTransform(myColorTransform2);
wxculoarea8.setTransform(myColorTransform2);
Symbol 228 MovieClip Frame 4
wxculoarea3 = new Color(but1);
wxculoarea4 = new Color(but2);
wxculoarea5 = new Color(but3);
wxculoarea6 = new Color(but4);
wxculoarea7 = new Color(but5);
wxculoarea8 = new Color(but6);
myColorTransform2 = new Object();
myColorTransform2 = {ra:"100", rb:_parent.xrtb5, ga:"100", gb:_parent.xgtb5, ba:"100", bb:_parent.xbtb5, aa:"100", ab:"0"};
wxculoarea3.setTransform(myColorTransform2);
wxculoarea4.setTransform(myColorTransform2);
wxculoarea5.setTransform(myColorTransform2);
wxculoarea6.setTransform(myColorTransform2);
wxculoarea7.setTransform(myColorTransform2);
wxculoarea8.setTransform(myColorTransform2);
Symbol 228 MovieClip Frame 5
wxculoarea3 = new Color(but1);
wxculoarea4 = new Color(but2);
wxculoarea5 = new Color(but3);
wxculoarea6 = new Color(but4);
wxculoarea7 = new Color(but5);
wxculoarea8 = new Color(but6);
myColorTransform2 = new Object();
myColorTransform2 = {ra:"100", rb:_parent.xrtb5, ga:"100", gb:_parent.xgtb5, ba:"100", bb:_parent.xbtb5, aa:"100", ab:"0"};
wxculoarea3.setTransform(myColorTransform2);
wxculoarea4.setTransform(myColorTransform2);
wxculoarea5.setTransform(myColorTransform2);
wxculoarea6.setTransform(myColorTransform2);
wxculoarea7.setTransform(myColorTransform2);
wxculoarea8.setTransform(myColorTransform2);
Symbol 228 MovieClip Frame 6
wxculoarea3 = new Color(but1);
wxculoarea4 = new Color(but2);
wxculoarea5 = new Color(but3);
wxculoarea6 = new Color(but4);
wxculoarea7 = new Color(but5);
wxculoarea8 = new Color(but6);
myColorTransform2 = new Object();
myColorTransform2 = {ra:"100", rb:_parent.xrtb5, ga:"100", gb:_parent.xgtb5, ba:"100", bb:_parent.xbtb5, aa:"100", ab:"0"};
wxculoarea3.setTransform(myColorTransform2);
wxculoarea4.setTransform(myColorTransform2);
wxculoarea5.setTransform(myColorTransform2);
wxculoarea6.setTransform(myColorTransform2);
wxculoarea7.setTransform(myColorTransform2);
wxculoarea8.setTransform(myColorTransform2);
Symbol 228 MovieClip Frame 7
wxculoarea3 = new Color(but1);
wxculoarea4 = new Color(but2);
wxculoarea5 = new Color(but3);
wxculoarea6 = new Color(but4);
wxculoarea7 = new Color(but5);
wxculoarea8 = new Color(but6);
myColorTransform2 = new Object();
myColorTransform2 = {ra:"100", rb:_parent.xrtb5, ga:"100", gb:_parent.xgtb5, ba:"100", bb:_parent.xbtb5, aa:"100", ab:"0"};
wxculoarea3.setTransform(myColorTransform2);
wxculoarea4.setTransform(myColorTransform2);
wxculoarea5.setTransform(myColorTransform2);
wxculoarea6.setTransform(myColorTransform2);
wxculoarea7.setTransform(myColorTransform2);
wxculoarea8.setTransform(myColorTransform2);
Symbol 228 MovieClip Frame 8
wxculoarea3 = new Color(but1);
wxculoarea4 = new Color(but2);
wxculoarea5 = new Color(but3);
wxculoarea6 = new Color(but4);
wxculoarea7 = new Color(but5);
wxculoarea8 = new Color(but6);
myColorTransform2 = new Object();
myColorTransform2 = {ra:"100", rb:_parent.xrtb5, ga:"100", gb:_parent.xgtb5, ba:"100", bb:_parent.xbtb5, aa:"100", ab:"0"};
wxculoarea3.setTransform(myColorTransform2);
wxculoarea4.setTransform(myColorTransform2);
wxculoarea5.setTransform(myColorTransform2);
wxculoarea6.setTransform(myColorTransform2);
wxculoarea7.setTransform(myColorTransform2);
wxculoarea8.setTransform(myColorTransform2);
Symbol 233 Button
on (press) {
_parent.play();
}
Symbol 236 MovieClip Frame 1
stop();
if (_parent.wxaliniere == "Dreapta-Jos") {
this.gotoAndStop(2);
}
if ((_parent.wxaliniere == "Dreapta-Sus") && (_parent.wxbutno == 6)) {
this.gotoAndStop(3);
}
if ((_parent.wxaliniere == "Dreapta-Sus") && (_parent.wxbutno == 5)) {
this.gotoAndStop(5);
}
if ((_parent.wxaliniere == "Dreapta-Sus") && (_parent.wxbutno == 4)) {
this.gotoAndStop(6);
}
if ((_parent.wxaliniere == "Dreapta-Sus") && (_parent.wxbutno == 3)) {
this.gotoAndStop(7);
}
if ((_parent.wxaliniere == "Stanga-Sus") && (_parent.wxbutno == 6)) {
this.gotoAndStop(4);
}
if ((_parent.wxaliniere == "Stanga-Sus") && (_parent.wxbutno == 5)) {
this.gotoAndStop(8);
}
if ((_parent.wxaliniere == "Stanga-Sus") && (_parent.wxbutno == 4)) {
this.gotoAndStop(9);
}
if ((_parent.wxaliniere == "Stanga-Sus") && (_parent.wxbutno == 3)) {
this.gotoAndStop(10);
}
Symbol 236 MovieClip Frame 2
tg._x = 147;
tg._y = 1.1;
Symbol 236 MovieClip Frame 3
tg._x = 147;
tg._y = -174.9;
Symbol 236 MovieClip Frame 4
tg._x = 1.5;
tg._y = -174.9;
Symbol 236 MovieClip Frame 5
tg._x = 147;
tg._y = -152.4;
Symbol 236 MovieClip Frame 6
tg._x = 147;
tg._y = -128.9;
Symbol 236 MovieClip Frame 7
tg._x = 147;
tg._y = -104.9;
Symbol 236 MovieClip Frame 8
tg._x = 1.5;
tg._y = -151.4;
Symbol 236 MovieClip Frame 9
tg._x = 1.5;
tg._y = -128.4;
Symbol 236 MovieClip Frame 10
tg._x = 1.5;
tg._y = -104.9;
Symbol 255 MovieClip Frame 1
stop();
this.onRollOver = function () {
if (_parent._parent._currentframe <= 10) {
_parent._parent.gotoAndPlay(11);
}
};
if (_parent._parent.wxbutno == 5) {
this.gotoAndStop(2);
}
if (_parent._parent.wxbutno == 4) {
this.gotoAndStop(3);
}
if (_parent._parent.wxbutno == 3) {
this.gotoAndStop(4);
}
Symbol 256 MovieClip Frame 1
stop();
if ((_parent.wxaliniere == "Stanga-Sus") || (_parent.wxaliniere == "Dreapta-Sus")) {
this.gotoAndStop(2);
}
Symbol 257 MovieClip Frame 1
function pauseFunction() {
var _local1 = _global;
if (_local1.pause_var != 1) {
_local1.pause_var = 1;
} else {
_local1.pause_var = 0;
}
}
function soundFunction() {
var _local1 = _global;
if (_local1.sound_off != 1) {
_local1.sound_off = 1;
} else {
_local1.sound_off = 0;
}
if (_local1.sound_off == 1) {
_local1.music.stop();
} else {
_local1.music.start();
}
}
function mainMenuFunction() {
var _local1 = _root;
removeMovieClip(_local1.themenu);
removeMovieClip(_local1.owca1);
removeMovieClip(_local1.owca2);
removeMovieClip(_local1.owca3);
removeMovieClip(_local1.owca4);
removeMovieClip(_local1.owca5);
removeMovieClip(_local1.owca6);
removeMovieClip(_local1.owca7);
removeMovieClip(_local1.owca8);
removeMovieClip(_local1.fence);
removeMovieClip(_local1.target);
removeMovieClip(_local1.pool);
removeMovieClip(_local1.fence1);
removeMovieClip(_local1.trak);
removeMovieClip(_local1.cara);
removeMovieClip(_local1.woda);
removeMovieClip(_local1.woda2);
removeMovieClip(_local1.targetw);
removeMovieClip(_local1.targetb);
removeMovieClip(_local1.tree1);
removeMovieClip(_local1.tree2);
removeMovieClip(_local1.dog);
removeMovieClip(_local1.napis);
removeMovieClip(_local1.playAgain);
stopAllSounds();
_local1.gotoAndStop("coperta");
}
stop();
wxnguides._alpha = 0;
my_color = new Color(my_mc);
my_color.setRGB(wxculoare);
myValue = my_color.getRGB().toString(16);
trace(myValue.length);
if (myValue.length == 5) {
myValue = "0" + myValue;
}
if (myValue.length == 4) {
myValue = "00" + myValue;
}
if (myValue.length == 3) {
myValue = "000" + myValue;
}
if (myValue.length == 2) {
myValue = "0000" + myValue;
}
if (myValue.length == 1) {
myValue = "00000" + myValue;
}
xtbcolor = myValue;
xrtb5 = Number("0x" + xtbcolor.slice(0, 2)) - 1;
xgtb5 = Number("0x" + xtbcolor.slice(2, 4)) - 1;
xbtb5 = Number("0x" + xtbcolor.slice(4, 6)) - 1;
wxculoarea2 = new Color(wxnmenu.tg);
myColorTransform = new Object();
myColorTransform = {ra:"100", rb:xrtb5, ga:"100", gb:xgtb5, ba:"100", bb:xbtb5, aa:"100", ab:"0"};
wxculoarea2.setTransform(myColorTransform);
wxculoarea3 = new Color(wxnfer);
myColorTransform2 = new Object();
myColorTransform2 = {ra:"100", rb:xrtb5, ga:"100", gb:xgtb5, ba:"100", bb:xbtb5, aa:"100", ab:"0"};
wxculoarea3.setTransform(myColorTransform2);
Symbol 257 MovieClip Frame 10
stop();
Symbol 263 Button
on (release) {
_global.time_l = 0;
removeMovieClip(_root.owca1);
removeMovieClip(_root.owca2);
removeMovieClip(_root.owca3);
removeMovieClip(_root.tree1);
removeMovieClip(_root.tree2);
removeMovieClip(this);
_root.themenu.removeMovieClip();
_root.toGo = "level1";
_root.gotoAndStop("golevel1");
}
Symbol 264 MovieClip Frame 1
stop();
Symbol 264 MovieClip Frame 2
trace("kdfsjkl");
Symbol 264 MovieClip Frame 19
gotoAndPlay (2);
Symbol 275 Button
on (press, keyPress "<Space>") {
if (_global.nextlevel == 1) {
_global.nextlevel = 0;
removeMovieClip(_root.owca1);
removeMovieClip(_root.owca2);
removeMovieClip(_root.owca3);
removeMovieClip(_root.owca4);
removeMovieClip(_root.tree1);
removeMovieClip(_root.napis);
removeMovieClip(_root.playAgain);
removeMovieClip(_root.replay_the_game);
gotoAndPlay (180);
}
}
Symbol 288 Button
on (press, keyPress "<Space>") {
if (_global.nextlevel == 1) {
_global.nextlevel = 0;
removeMovieClip(_root.owca1);
removeMovieClip(_root.owca2);
removeMovieClip(_root.owca3);
removeMovieClip(_root.owca4);
removeMovieClip(_root.owca5);
removeMovieClip(_root.napis);
removeMovieClip(_root.cara);
removeMovieClip(_root.trak);
removeMovieClip(_root.playAgain);
removeMovieClip(_root.replay_the_game);
gotoAndPlay (181);
}
}
Symbol 292 MovieClip Frame 1
stop();
Symbol 292 MovieClip Frame 2
if (_global.pause_var != 1) {
this.play();
} else {
this.stop();
}
Symbol 296 MovieClip Frame 1
stop();
Symbol 314 Button
on (press, keyPress "<Space>") {
if (_global.nextlevel == 1) {
_global.nextlevel = 0;
removeMovieClip(_root.owca1);
removeMovieClip(_root.owca2);
removeMovieClip(_root.owca3);
removeMovieClip(_root.owca4);
removeMovieClip(_root.owca5);
removeMovieClip(_root.owca6);
removeMovieClip(_root.tree1);
removeMovieClip(_root.napis);
removeMovieClip(_root.playAgain);
removeMovieClip(_root.replay_the_game);
gotoAndPlay (182);
}
}
Symbol 329 Button
on (press, keyPress "<Space>") {
if (_global.nextlevel == 1) {
_global.nextlevel = 0;
removeMovieClip(_root.owca1);
removeMovieClip(_root.owca2);
removeMovieClip(_root.owca3);
removeMovieClip(_root.owca4);
removeMovieClip(_root.owca5);
removeMovieClip(_root.owca6);
removeMovieClip(_root.owca7);
removeMovieClip(_root.napis);
removeMovieClip(_root.playAgain);
removeMovieClip(_root.replay_the_game);
gotoAndPlay (183);
}
}