Frame 1
function saveprogress(lvl) {
if (lvl <= prog) {
return(undefined);
}
sav.data.prog = lvl;
sav.flush();
prog = lvl;
}
function trigmove_x(distance, angle) {
return(distance * Math.cos(angle));
}
function trigmove_y(distance, angle) {
return(distance * Math.sin(angle));
}
function trigmove_getangle(sx, sy, ex, ey) {
return(Math.atan2(ey - sy, ex - sx));
}
function trigmove_getdist(sx, sy, ex, ey) {
return(Math.sqrt(Math.pow(ex - sx, 2) + Math.pow(ey - sy, 2)));
}
function deceleration(perc) {
return(1 - Math.pow(1 - perc, 2));
}
function acceleration(perc) {
return(Math.pow(perc, 2));
}
function smoothstep(perc) {
return(Math.pow(perc, 2) * (3 - (2 * perc)));
}
function tween_init(home, tween, ms, ex, ey, exscl, eyscl) {
home.sx = home._x;
home.sy = home._y;
home.sxscl = home._xscale;
home.syscl = home._yscale;
home.xscl = ((exscl == undefined) ? 0 : (exscl - home.sxscl));
home.yscl = ((eyscl == undefined) ? 0 : (eyscl - home.syscl));
if (((ex == null) || (ex == home.sx)) && ((ey == null) || (ey == home.sy))) {
home.dist = 0;
} else {
home.rad = trigmove_getangle(home.sx, home.sy, ex, ey);
home.dist = trigmove_getdist(home.sx, home.sy, ex, ey);
}
home.time_s = getTimer();
home.time_e = getTimer() + ms;
home.tween = tween;
}
function tween_move(home) {
if (((((home.dist == 0) && (home.xscl == 0)) && (home.yscl == 0)) && (home.blurx == 0)) && (home.blury == 0)) {
if (getTimer() >= home.time_e) {
home.time_e = undefined;
return(1);
}
return(1);
}
if (home.time_e == undefined) {
return(undefined);
}
var _local5 = ((getTimer() >= home.time_e) ? (home.time_e) : (getTimer()));
var _local2 = (_local5 - home.time_s) / (home.time_e - home.time_s);
switch (home.tween) {
case "in" :
_local2 = acceleration(_local2);
break;
case "out" :
_local2 = deceleration(_local2);
break;
case "smooth" :
_local2 = smoothstep(_local2);
}
if (home.dist != 0) {
var _local4 = home.dist * _local2;
var _local7 = trigmove_x(_local4, home.rad);
var _local6 = trigmove_y(_local4, home.rad);
home._x = home.sx + _local7;
home._y = home.sy + _local6;
}
if (home.xscl != 0) {
var _local8 = home.xscl * _local2;
home._xscale = home.sxscl + _local8;
}
if (home.yscl != 0) {
var _local8 = home.yscl * _local2;
home._yscale = home.syscl + _local8;
}
if (home.blurx != 0) {
var _local8 = home.blurx * _local2;
var _local3 = home.filters;
_local3[0].blurX = _local8 + home.sblurx;
home.filters = _local3;
}
if (home.blury != 0) {
var _local8 = home.blury * _local2;
var _local3 = home.filters;
_local3[0].blurY = _local8 + home.sblury;
home.filters = _local3;
}
if (_local5 == home.time_e) {
home.time_e = undefined;
return(1);
}
}
function clearphase() {
timed = 0;
goals = [];
levelphase = 0;
}
function weirdotext() {
switch (random(4)) {
case 0 :
textbox("You are behaving strangely.", 1);
return;
case 1 :
textbox("You are making those around you uncomfortable.", 1);
return;
case 2 :
textbox("You appear to need medical attention.", 1);
return;
case 3 :
textbox("This behavior may attract unwanted attention.", 1);
}
}
function level_romance(phase) {
var _local3 = _root.world;
switch (phase) {
case 0 :
snd_stop("amb_rainy");
snd_play("amb_grocery");
_local3.gotoAndStop("romance");
_local3.checkout.gotoAndStop(1);
_local3.npc.gotoAndStop(2);
_local3.npc.mouth.gotoAndStop("d");
_local3.mc.mouth.gotoAndStop("d");
levelphase = 1;
textbox("Purchase the condoms.", 0, 1179599);
break;
case 1 :
timed = getTimer() + 2000;
timedforce = 1;
goals = [];
goals[0] = {type:"stare", gaze:"ul", time:1000, otime:1000, prog:0, goal:"store_yammer", action:"smiletalk", inaction:"d", reaction:1, unreaction:2, phaseless:1};
goals[1] = {type:"stare", gaze:"ur", time:1000, otime:1000, prog:0, goal:"store_stare", phaseless:1};
goals[2] = {type:"stare", gaze:"dl", time:1000, otime:1000, prog:0, goal:"store_stare", phaseless:1};
goals[3] = {type:"stare", gaze:"dr", time:1000, otime:1000, prog:0, goal:"store_mumble", action:"dtalk", inaction:"d", reaction:1, unreaction:2, phaseless:1};
goals[4] = {type:"stare", gaze:"u", time:1000, otime:1000, prog:0, goal:"store_stare", phaseless:1};
goals[5] = {type:"stare", gaze:"cl", time:1000, otime:1000, prog:0, goal:"store_stare", phaseless:1};
goals[6] = {type:"stare", gaze:"d", time:1000, otime:1000, prog:0, goal:"store_stare", phaseless:1};
goals[7] = {type:"stare", gaze:"cr", time:1000, otime:1000, prog:0, goal:"store_creep", phaseless:1};
goals[8] = {type:"stare", gaze:"c", time:1000, otime:1000, prog:0, goal:"store_weirdo", phaseless:1};
levelphase = 2;
break;
case "2_timeout" :
_local3.npc.gotoAndStop(3);
_local3.checkout.gotoAndStop(2);
goals[0].unreaction = 3;
goals[3].unreaction = 3;
timed = getTimer() + 2000;
timedforce = 1;
levelphase = 3;
break;
case "3_timeout" :
snd_play("register");
_local3.checkout.gotoAndStop(3);
timed = getTimer() + 1000;
timedforce = 1;
levelphase = 4;
break;
case "store_yammer" :
clearphase();
textbox("You're acting too excited about purchasing a product.", 1);
break;
case "store_mumble" :
clearphase();
textbox("Please don't mumble under your breath.", 1);
break;
case "store_stare" :
clearphase();
textbox("Don't avoid interaction so much.", 1);
break;
case "store_creep" :
clearphase();
textbox("You're making the cashier uncomfortable with your staring.", 1);
break;
case "store_weirdo" :
clearphase();
textbox("Please stop doing that.", 1);
break;
case "4_timeout" :
clearphase();
textbox("You've successfully purchased the condoms!", 0, 1179599);
levelphase = 5;
break;
case 5 :
snd_stop("amb_grocery");
snd_play("amb_rainy");
_local3.gotoAndStop("romance2");
_local3.npc.gotoAndStop(2);
_local3.npc.mouth.gotoAndStop("smile");
_local3.mc.mouth.gotoAndStop("opend");
textbox("Have sexual intercourse.", 0, 16716192);
levelphase = 6;
break;
case 6 :
timed = getTimer() + 4000;
timedforce = 1;
goals = [];
goals[0] = {type:"look", gaze:"ul", time:20000, prog:0, phaseless:1};
goals[1] = {type:"look", gaze:"u", time:20000, prog:0, phaseless:1};
goals[2] = {type:"look", gaze:"ur", time:20000, prog:0, phaseless:1};
goals[3] = {type:"look", gaze:"cl", time:20000, prog:0, phaseless:1};
goals[4] = {type:"look", gaze:"c", time:20000, prog:0, phaseless:1};
goals[5] = {type:"look", gaze:"cr", time:20000, prog:0, phaseless:1};
goals[6] = {type:"look", gaze:"dl", time:20000, prog:0, phaseless:1};
goals[7] = {type:"look", gaze:"d", time:20000, prog:0, phaseless:1};
goals[8] = {type:"look", gaze:"dr", time:20000, prog:0, phaseless:1};
levelphase = 7;
break;
case "7_timeout" :
_local3.npc.gotoAndStop(5);
_local3.npc.mouth.gotoAndStop("d");
timed = getTimer() + 3000;
timedforce = 1;
levelphase = 8;
break;
case "8_timeout" :
_local3.npc.gotoAndStop(3);
_local3.npc.mouth.gotoAndStop("frown");
timed = getTimer() + 2000;
timedforce = 1;
levelphase = 9;
break;
case "9_timeout" :
_local3.npc.gotoAndStop(3);
_local3.npc.mouth.gotoAndStop("opensmile");
snd_play("opensmile");
timed = getTimer() + 3000;
timedforce = 1;
levelphase = 10;
break;
case "10_timeout" :
var _local2 = {};
_local2.ul = Math.floor(((20000 - goals[0].time) / 12000) * 100);
_local2.u = Math.floor(((20000 - goals[1].time) / 12000) * 100);
_local2.ur = Math.floor(((20000 - goals[2].time) / 12000) * 100);
_local2.cl = Math.floor(((20000 - goals[3].time) / 12000) * 100);
_local2.c = Math.floor(((20000 - goals[4].time) / 12000) * 100);
_local2.cr = Math.floor(((20000 - goals[5].time) / 12000) * 100);
_local2.dl = Math.floor(((20000 - goals[6].time) / 12000) * 100);
_local2.d = Math.floor(((20000 - goals[7].time) / 12000) * 100);
_local2.dr = Math.floor(((20000 - goals[8].time) / 12000) * 100);
var _local4 = "Congratulations on completing coitus!\nYour partner found your love-making to be ";
var _local5 = (((((_local2.ul > 15) || (_local2.ur > 15)) || (_local2.cl > 15)) || (_local2.cr > 15)) || (_local2.dl > 15)) || (_local2.dr > 15);
if (hyperactive(_local2)) {
_local4 = _local4 + "hyperactive. This is normal behavior for the unexperienced.";
} else if (_local2.c > 90) {
_local4 = _local4 + "confidence building. You orgasmed alot.";
} else if (_local2.d > 90) {
_local4 = _local4 + "scary. Your fixation on the genital interaction was troubling.";
} else if (((((((_local2.ul > 75) || (_local2.u > 75)) || (_local2.ur > 75)) || (_local2.cl > 75)) || (_local2.cr > 75)) || (_local2.dl > 75)) || (_local2.dr > 75)) {
_local4 = _local4 + "awkward. What were you looking at the whole time?";
} else if (_local2.c > 60) {
_local4 = _local4 + "cute. Try harder next time to impress.";
} else if (_local2.d > 60) {
_local4 = _local4 + "intense. Have you been reading romantic fiction?";
} else if ((((((_local2.ul > 35) || (_local2.ur > 35)) || (_local2.cl > 35)) || (_local2.cr > 35)) || (_local2.dl > 35)) || (_local2.dr > 35)) {
_local4 = _local4 + "mediocre. There's no shame in a platonic relationship.";
} else if ((_local2.c > 20) && (_local2.d > 40)) {
_local4 = _local4 + "selfish. If you want to have sex alone then have sex alone.";
} else if ((_local2.c > 20) && (_local2.u > 40)) {
_local4 = _local4 + "romantic. You really know what you're doing.";
} else if ((_local2.d > 30) && (_local2.u > 30)) {
_local4 = _local4 + "earth-shattering. How is such a thing even possible?";
} else if ((_local2.c > 20) && _local5) {
_local4 = _local4 + "painful. Try to be kinder.";
} else if ((_local2.d > 35) && _local5) {
_local4 = _local4 + "rough. Not that it wasn't enjoyable.";
} else if ((_local2.u > 35) && _local5) {
_local4 = _local4 + "sensual. You showed unexpected skill.";
} else {
_local4 = _local4 + "confusing. Not even sure what happened.";
}
textbox(_local4, 2, 16716192);
clearphase();
}
}
function hyperactive(percents) {
for (var _local2 in percents) {
if (percents[_local2] > 20) {
return(0);
}
}
return(1);
}
function level_park(phase) {
var _local2 = _root.world;
switch (phase) {
case 0 :
snd_play("amb_park");
_local2.mc._visible = true;
_local2.npc.gotoAndStop(1);
_local2.npc.mouth.gotoAndStop("smile");
_local2.mc.mouth.gotoAndStop("smile");
_local2.bro._visible = false;
_local2.bro.mouth.gotoAndStop("d");
_local2.bash_bro._visible = false;
_local2.bash_mc._visible = false;
levelphase = 1;
textbox("Enjoy the more comfortable second date.", 0, 1179647);
break;
case 1 :
_local2.npc.gotoAndStop(4);
_local2.npc.mouth.gotoAndStop("smiletalk");
timed = getTimer() + 4000;
goals = [];
goals[0] = {type:"look", gaze:"c", time:1000, prog:0, goal:"fail", action:"d", inaction:"smile"};
goals[1] = {type:"look", gaze:"cl", time:1000, prog:0, goal:"fail", action:"d", inaction:"smile"};
goals[2] = {type:"look", gaze:"d", time:1000, prog:0, goal:"fail", action:"d"};
goals[3] = {type:"look", gaze:"dl", time:1000, prog:0, goal:"fail", action:"d"};
goals[4] = {type:"look", gaze:"dr", time:1000, prog:0, goal:"fail", action:"d", inaction:"smile"};
levelphase = 2;
break;
case "2_fail" :
clearphase();
textbox("Try to not be so bored with your date.", 1);
break;
case "2_timeout" :
_local2.npc.gotoAndStop(2);
_local2.npc.mouth.gotoAndStop("smile");
_local2.mc.mouth.gotoAndStop("smiletalk");
timed = getTimer() + 3000;
goals = [];
levelphase = 3;
break;
case "3_timeout" :
_local2.bro._visible = true;
_local2.bro.gotoAndStop(4);
_local2.bro.mouth.gotoAndStop("smiletalk");
_local2.npc.gotoAndStop(5);
_local2.npc.mouth.gotoAndStop("smile");
_local2.mc.mouth.gotoAndStop("d");
textbox("Your date is being interrupted!", 0, 1179647);
levelphase = 4;
break;
case 4 :
timed = getTimer() + 4000;
goals = [];
goals[0] = {type:"look", gaze:"ul", time:1000, prog:0, goal:"fail"};
goals[1] = {type:"look", gaze:"u", time:1000, prog:0, goal:"fail"};
goals[2] = {type:"look", gaze:"cl", time:1000, prog:0, goal:"fail"};
goals[3] = {type:"look", gaze:"c", time:1000, prog:0, goal:"fail"};
goals[4] = {type:"look", gaze:"dl", time:1000, prog:0, goal:"fail"};
goals[5] = {type:"look", gaze:"d", time:1000, prog:0, goal:"fail"};
goals[6] = {type:"look", gaze:"dr", time:1000, prog:0, goal:"fail"};
levelphase = 5;
break;
case "5_fail" :
clearphase();
textbox("Don't behave weakly in this situation.", 1);
break;
case "5_timeout" :
_local2.bro.gotoAndStop(3);
_local2.bro.mouth.gotoAndStop("frowntalk");
_local2.npc.gotoAndStop(5);
_local2.npc.mouth.gotoAndStop("d");
timed = getTimer() + 1000;
levelphase = 6;
break;
case "6_fail" :
clearphase();
textbox("Don't behave weakly in this situation.", 1);
break;
case "6_timeout" :
_local2.bro.gotoAndStop(3);
_local2.bro.mouth.gotoAndStop("frown");
_local2.npc.gotoAndStop(2);
_local2.npc.mouth.gotoAndStop("d");
_local2.mc.mouth.gotoAndStop("frown");
timed = getTimer() + 10000;
goals = [];
goals[0] = {type:"stare", gaze:"cr", time:2000, otime:2000, prog:0, goal:"strong", action:"frowntalk"};
goals[1] = {type:"stare", gaze:"d", time:2000, otime:2000, prog:0, goal:"weak", action:"dtalk", reaction:5, unreaction:2};
goals[2] = {type:"stare", gaze:"cl", time:2000, otime:2000, prog:0, goal:"smart", action:"smiletalk", inaction:"d"};
goals[3] = {type:"stare", gaze:"u", time:2000, otime:2000, prog:0, goal:"avoidant", action:"d", reaction:5, unreaction:2};
goals[4] = {type:"stare", gaze:"c", time:2000, otime:2000, prog:0, goal:"weirdo", reaction:5, unreaction:2};
levelphase = 7;
break;
case "7_weirdo" :
bashscene();
clearphase();
textbox("Now is really not the time to do that.", 1);
break;
case "7_timeout" :
case "7_avoidant" :
bashscene();
clearphase();
textbox("Avoiding the situation doesn't help.", 1);
break;
case "7_weak" :
_local2.npc.gotoAndStop(2);
_local2.npc.mouth.gotoAndStop("frown");
_local2.bro.gotoAndStop(3);
_local2.bro.mouth.gotoAndStop("smile");
_local2.mc.mouth.gotoAndStop("frown");
clearphase();
textbox("The date is ruined by your timidness.", 1);
break;
case "7_strong" :
bashscene();
clearphase();
textbox("You acted too strongly, the situation escalated.", 1);
break;
case "7_smart" :
_local2.bro._visible = false;
_local2.npc.gotoAndStop(2);
_local2.npc.mouth.gotoAndStop("smile");
_local2.mc.mouth.gotoAndStop("smile");
clearphase();
textbox("Good work!\nYou diffused the situation with humor.", 2, 1179647);
saveprogress(3);
}
}
function bashscene() {
var _local2 = _root.world;
_local2.bro._visible = false;
_local2.mc._visible = false;
_local2.bro.mouth.gotoAndStop("frown");
_local2.mc.mouth.gotoAndStop("frown");
_local2.bash_bro._visible = true;
_local2.bash_mc._visible = true;
_local2.bash_bro.gotoAndStop(3);
_local2.bash_bro.mouth.gotoAndStop("frown");
_local2.bash_mc.mouth.gotoAndStop("frown");
_local2.npc.gotoAndStop(4);
_local2.npc.mouth.gotoAndStop("frown");
snd_play("smash");
}
function level_coffee(phase) {
var _local2 = _root.world;
switch (phase) {
case 0 :
snd_play("amb_cafe");
_local2.npc.gotoAndStop(1);
_local2.npc.mouth.gotoAndStop("smile");
_local2.mc.mouth.gotoAndStop("smile");
levelphase = 1;
textbox("Make good impressions on the first date.", 0, 12221782);
break;
case 1 :
_local2.npc.gotoAndStop(2);
_local2.npc.mouth.gotoAndStop("smiletalk");
_local2.mc.mouth.gotoAndStop("smile");
timed = getTimer() + 6000;
goals = [];
goals[0] = {type:"look", gaze:"cr", time:5000, prog:0, goal:"goal"};
goals[1] = {type:"glance", gaze:"dr", count:8, prog:0, goal:"breastglance", phaseless:1};
goals[2] = {type:"stare", gaze:"dr", time:4000, otime:4000, prog:0, goal:"breaststare", phaseless:1};
goals[3] = copyobject(weirdogoal);
levelphase = 2;
break;
case "2_timeout" :
_local2.npc.gotoAndStop(3);
_local2.npc.mouth.gotoAndStop("d");
_local2.mc.mouth.gotoAndStop("d");
clearphase();
textbox("Remember to look at people when they talk.", 1);
break;
case "2_goal" :
_local2.npc.gotoAndStop(1);
_local2.npc.mouth.gotoAndStop("smile");
_local2.mc.mouth.gotoAndStop("smiletalk");
timed = getTimer() + 6000;
timedforce = 1;
goals[0] = {type:"stare", gaze:"cr", time:3000, otime:3000, prog:0, goal:"creep"};
goals[4] = {type:"stare", gaze:"ur", time:1500, otime:1500, prog:0, goal:"stare"};
goals[5] = {type:"stare", gaze:"u", time:1500, otime:1500, prog:0, goal:"stare"};
goals[6] = {type:"stare", gaze:"d", time:1500, otime:1500, prog:0, goal:"stare"};
goals[7] = {type:"stare", gaze:"dl", time:1500, otime:1500, prog:0, goal:"stare"};
goals[8] = {type:"stare", gaze:"ul", time:1500, otime:1500, prog:0, goal:"stare"};
goals[9] = {type:"stare", gaze:"cl", time:1500, otime:1500, prog:0, goal:"stare"};
levelphase = 3;
break;
case "3_creep" :
_local2.npc.gotoAndStop(3);
_local2.npc.mouth.gotoAndStop("d");
clearphase();
textbox("You were too intense.", 1);
break;
case "3_stare" :
_local2.npc.gotoAndStop(3);
_local2.npc.mouth.gotoAndStop("d");
clearphase();
textbox("Don't stare into space while talking, it's uncomfortable for those with you.", 1);
break;
case "3_timeout" :
_local2.npc.gotoAndStop(4);
_local2.npc.mouth.gotoAndStop("smile");
_local2.mc.mouth.gotoAndStop("smile");
timed = getTimer() + 2000;
goals[0] = undefined;
goals[3] = undefined;
goals[4] = undefined;
goals[5] = undefined;
goals[6] = undefined;
goals[7] = undefined;
goals[8] = undefined;
goals[9] = undefined;
levelphase = 4;
break;
case "4_timeout" :
_local2.npc.gotoAndStop(4);
_local2.npc.mouth.gotoAndStop("d");
_local2.mc.mouth.gotoAndStop("d");
timed = getTimer() + 7000;
goals[3] = {type:"look", gaze:"c", time:3000, otime:3000, prog:0, goal:"goal"};
levelphase = 5;
break;
case "5_timeout" :
clearphase();
textbox("There was tension you needed to break.", 1);
break;
case "5_goal" :
_local2.npc.gotoAndStop(5);
_local2.mc.mouth.gotoAndStop("smiletalk");
timed = getTimer() + 2000;
goals[3] = undefined;
levelphase = 6;
break;
case "6_timeout" :
_local2.mc.mouth.gotoAndStop("smile");
textbox(("That was a good date.\nYou glanced at the cleavage " + (8 - goals[1].count)) + " times.", 2, 12221782);
saveprogress(2);
clearphase();
break;
case "weirdo" :
_local2.npc.gotoAndStop(3);
_local2.npc.mouth.gotoAndStop("frown");
clearphase();
weirdotext();
break;
case "breastglance" :
_local2.npc.gotoAndStop(3);
_local2.npc.mouth.gotoAndStop("frown");
clearphase();
textbox("You looked at the cleavage too many times.", 1);
break;
case "breaststare" :
_local2.npc.gotoAndStop(3);
_local2.npc.mouth.gotoAndStop("frown");
clearphase();
textbox("It's impolite to stare at a person's breasts.", 1);
}
}
function level_transport(phase) {
var _local2 = _root.world;
switch (phase) {
case 0 :
snd_play("amb_train");
_local2.npc.gotoAndStop(1);
_local2.npc.mouth.gotoAndStop("d");
_local2.mc.mouth.gotoAndStop("d");
levelphase = 1;
textbox("Strike up a conversation with your transport partner.", 0, 16776977);
break;
case 1 :
goals = [];
goals[0] = {type:"look", gaze:"cr", time:2000, prog:0, goal:"creep", phaseless:1};
goals[1] = {type:"stare", gaze:"dr", time:3000, otime:3000, prog:0, goal:"goal"};
goals[2] = copyobject(weirdogoal);
goals[3] = {type:"stare", gaze:"cl", time:2000, otime:2000, prog:0, goal:"window", phaseless:1};
levelphase = 2;
break;
case "2_goal" :
_local2.npc.gotoAndStop(2);
_local2.npc.mouth.gotoAndStop("d");
timed = getTimer() + 2000;
goals = [];
goals[0] = {type:"look", gaze:"cr", time:500, prog:0, goal:"goal"};
goals[1] = {type:"look", gaze:"dr", time:500, prog:0, goal:"goal"};
levelphase = 3;
break;
case "3_timeout" :
_local2.npc.gotoAndStop(1);
_local2.npc.mouth.gotoAndStop("d");
clearphase();
textbox("She showed interest in your interest but you were too skiddish.", 1);
break;
case "3_goal" :
_local2.npc.gotoAndStop(3);
_local2.npc.mouth.gotoAndStop("smiletalk");
timed = getTimer() + 4000;
goals = [];
goals[0] = {type:"stare", gaze:"cr", time:2000, otime:2000, prog:0, goal:"goal", action:"dtalk", inaction:"d"};
goals[1] = copyobject(weirdogoal);
levelphase = 4;
break;
case "4_timeout" :
_local2.npc.mouth.gotoAndStop("frown");
clearphase();
textbox("You need to make eye contact with people when they talk to you.", 1);
break;
case "4_goal" :
_local2.npc.mouth.gotoAndStop("smile");
_local2.mc.mouth.gotoAndStop("smile");
clearphase();
textbox("Congratulations.\nYou gained a romantic interest.", 2, 16776977);
saveprogress(1);
break;
case "creep" :
_local2.npc.gotoAndStop(2);
_local2.npc.mouth.gotoAndStop("frown");
timed = getTimer() + 900;
goals = [];
levelphase = "creep1";
break;
case "creep1_timeout" :
_local2.npc.gotoAndStop(1);
_local2.npc.mouth.gotoAndStop("frown");
timed = getTimer() + 1000;
levelphase = "creep2";
break;
case "creep2_timeout" :
clearphase();
textbox("She was creeped out by your attempt at social interaction.", 1);
break;
case "weirdo" :
clearphase();
textbox("This behavior isn't unexpected on public transport but also not the best practice. Please restrain yourself in future.", 1);
break;
case "window" :
clearphase();
textbox("Staring out the window will not start a conversation.", 1);
}
}
function level_urinal(phase) {
var _local2 = _root.world;
switch (phase) {
case 0 :
snd_play("amb_toilet1");
_local2.npc.gotoAndStop(1);
_local2.npc.mouth.gotoAndStop("d");
_local2.mc.mouth.gotoAndStop("d");
levelphase = 1;
textbox("Politely use the public urinal alongside a urinating neighbor.", 0, 11163390);
break;
case 1 :
timed = getTimer() + 5000;
goals = [];
goals[0] = {type:"stare", gaze:"cr", time:2000, otime:2000, prog:0, goal:"creep", phaseless:1};
goals[1] = {type:"stare", gaze:"dr", time:2000, otime:2000, prog:0, goal:"starecock", phaseless:1, reaction:3, unreaction:1};
goals[2] = {type:"glance", gaze:"dr", count:4, prog:0, goal:"glancecock", phaseless:1};
goals[3] = {type:"look", gaze:"cr", time:3000, prog:0, goal:"stayfocused", phaseless:1};
goals[4] = {type:"look", gaze:"ur", time:3000, prog:0, goal:"stayfocused", phaseless:1};
goals[5] = {type:"look", gaze:"ul", time:3000, prog:0, goal:"stayfocused", phaseless:1};
goals[6] = {type:"look", gaze:"l", time:3000, prog:0, goal:"stayfocused", phaseless:1};
goals[7] = {type:"look", gaze:"dl", time:3000, prog:0, goal:"stayfocused", phaseless:1};
goals[8] = copyobject(weirdogoal);
levelphase = 2;
break;
case "2_timeout" :
clearphase();
_local2.npc.gotoAndStop(4);
_local2.npc.mouth.gotoAndStop("d");
timed = getTimer() + 500;
levelphase = 3;
break;
case "3_timeout" :
_local2.npc.gotoAndStop(2);
_local2.npc.mouth.gotoAndStop("d");
timed = getTimer() + 4000;
levelphase = 4;
goals = [];
goals[0] = {type:"stare", gaze:"cr", time:1000, otime:2000, prog:0, goal:"creep", phaseless:1};
goals[1] = {type:"stare", gaze:"dr", time:1000, otime:2000, prog:0, goal:"starecock", phaseless:1};
goals[2] = {type:"glance", gaze:"dr", count:3, prog:0, goal:"glancecock", phaseless:1};
goals[3] = {type:"look", gaze:"cr", time:2000, prog:0, goal:"stayfocused", phaseless:1};
goals[4] = {type:"look", gaze:"ur", time:2000, prog:0, goal:"stayfocused", phaseless:1};
goals[5] = {type:"look", gaze:"ul", time:2000, prog:0, goal:"stayfocused", phaseless:1, reaction:3, unreaction:2};
goals[6] = {type:"look", gaze:"l", time:2000, prog:0, goal:"stayfocused", phaseless:1, reaction:3, unreaction:2};
goals[7] = {type:"look", gaze:"dl", time:2000, prog:0, goal:"stayfocused", phaseless:1, reaction:3, unreaction:2};
goals[8] = copyobject(weirdogoal);
break;
case "4_timeout" :
snd_play("amb_toilet2");
snd_stop("amb_toilet1");
_local2.npc.mouth.gotoAndStop("frown");
clearphase();
textbox("Congratulations.\nYou've negotiated a social situation at a public urinal successfully.", 2, 11163390);
break;
case "creep" :
clearphase();
textbox("Maintaining eye contact is dissuaded in this situation.", 1);
break;
case "starecock" :
clearphase();
textbox("Staring at other's genitals is not encouraged.", 1);
break;
case "glancecock" :
clearphase();
textbox("Keep glances at other's genitals to a minimum.", 1);
break;
case "stayfocused" :
clearphase();
textbox("Do not allow your gaze to wander off from your task.", 1);
break;
case "weirdo" :
clearphase();
weirdotext();
}
}
function level_cashier(phase) {
var _local2 = _root.world;
switch (phase) {
case 0 :
snd_play("amb_grocery");
_local2.checkout.gotoAndStop(1);
_local2.npc.gotoAndStop(1);
_local2.npc.mouth.gotoAndStop("d");
_local2.mc.mouth.gotoAndStop("d");
levelphase = 1;
textbox("Use your gaze to socially interact with the cashier.", 0, 1179599);
break;
case 1 :
_local2.npc.mouth.gotoAndStop("dtalk");
timed = getTimer() + 5000;
goals = [];
goals[0] = {type:"look", gaze:"cr", time:2000, action:"dtalk", inaction:"d", prog:0, goal:"goal"};
goals[1] = {type:"glance", gaze:"cr", count:1, prog:0, goal:"thief1", phaseless:1};
goals[2] = copyobject(weirdogoal);
levelphase = 2;
break;
case "2_timeout" :
clearphase();
textbox("You must look at people when they speak to you.", 1);
break;
case "2_goal" :
snd_play("register");
_local2.checkout.gotoAndStop(2);
_local2.npc.gotoAndStop(3);
_local2.mc.mouth.gotoAndStop("d");
_local2.npc.mouth.gotoAndStop("d");
levelphase = 3;
timed = getTimer() + 5000;
goals = [];
goals[0] = {type:"stare", gaze:"cr", time:4000, otime:3000, prog:0, goal:"creep", reaction:2, unreaction:3};
goals[1] = {type:"glance", gaze:"cr", count:1, prog:0, goal:"thief1", phaseless:1};
goals[2] = copyobject(weirdogoal);
break;
case "3_timeout" :
snd_play("register");
_local2.checkout.gotoAndStop(3);
_local2.npc.gotoAndStop(1);
_local2.npc.mouth.gotoAndStop("smiletalk");
_local2.mc.mouth.gotoAndStop("d");
levelphase = 4;
timed = getTimer() + 5000;
goals = [];
goals[0] = {type:"look", gaze:"cr", time:2000, action:"smiletalk", inaction:"d", prog:0, goal:"goal"};
goals[1] = {type:"glance", gaze:"cr", count:1, prog:0, goal:"thief1", phaseless:1};
goals[2] = copyobject(weirdogoal);
break;
case "3_creep" :
clearphase();
textbox("Don't stare, it's impolite.", 1);
break;
case "4_goal" :
snd_play("register");
_local2.checkout.gotoAndStop(3);
_local2.npc.gotoAndStop(1);
_local2.npc.mouth.gotoAndStop("smile");
_local2.mc.mouth.gotoAndStop("smile");
clearphase();
textbox("Congratulations.\nYou've socially interacted with your cashier successfully.", 2, 1179599);
break;
case "4_timeout" :
clearphase();
textbox("Not looking at people speaking to you is impolite.", 1);
break;
case "thief1" :
case "thief2" :
case "thief3" :
case "thief4" :
case "thief5" :
case "thief6" :
var _local3 = phase.split("ief");
_local3 = Number(_local3[1]);
var _local4 = ((_local3 % 2) ? "cl" : "cr");
_local3++;
goals[1] = {type:"glance", gaze:_local4, count:1, prog:0, goal:"thief" + _local3, phaseless:1};
break;
case "thief7" :
clearphase();
textbox("You're behaving as if you've stolen something.", 1);
break;
case "weirdo" :
clearphase();
weirdotext();
}
}
function animationspecials(nam) {
var _local2 = _root.world;
switch (nam) {
case "romance" :
if ((levelphase > 5) && (levelphase < 10)) {
if (anmationvar.timer < getTimer()) {
switch (anmationvar.v) {
case 0 :
anmationvar.v = 1;
anmationvar.timer = getTimer() + 60;
_local2.mc._y = _local2.mc._y - 2;
if (levelphase == 8) {
snd_play("sex_fast" + (random(2) + 1), 50);
} else {
snd_play("sex_slow" + (random(2) + 1), 50);
}
break;
case 1 :
anmationvar.v = 2;
anmationvar.timer = getTimer() + 60;
_local2.mc._y = _local2.mc._y + 2;
_local2.npc._y = _local2.npc._y - 2;
if (levelphase != 8) {
snd_play("sex_slow" + (random(2) + 1), 50);
}
break;
case 2 :
anmationvar.v = 0;
anmationvar.timer = ((levelphase == 8) ? (getTimer() + 200) : (((levelphase == 7) ? (getTimer() + 400) : (getTimer() + 600))));
_local2.npc._y = _local2.npc._y + 2;
}
}
}
break;
case "transport" :
if (anmationvar.timer < getTimer()) {
if (anmationvar.v == 0) {
anmationvar.v = 1;
anmationvar.timer = getTimer() + 100;
_local2.mask._y = _local2.mask._y - 1;
_local2.seat._y = _local2.seat._y - 1;
_local2.mc._y = _local2.mc._y - 1;
_local2.npc._y = _local2.npc._y - 1;
} else {
anmationvar.v = 0;
anmationvar.timer = getTimer() + (random(15) * 100);
_local2.mask._y = _local2.mask._y + 1;
_local2.seat._y = _local2.seat._y + 1;
_local2.mc._y = _local2.mc._y + 1;
_local2.npc._y = _local2.npc._y + 1;
}
}
break;
case "park" :
_local2.cloud._x = _local2.cloud._x - 0.25;
if (_local2.cloud._x >= -805) {
break;
}
_local2.cloud._x = 800;
}
}
function talky(type, nam) {
var _local1 = "talk_";
if (nam == "npc") {
switch (levelnam) {
case "cashier" :
_local1 = _local1 + "cashier";
break;
case "urinal" :
_local1 = _local1 + "bro";
break;
case "transport" :
case "coffee" :
case "park" :
_local1 = _local1 + "li";
break;
case "romance" :
if (levelphase > 5) {
_local1 = _local1 + "li";
} else {
_local1 = _local1 + "cashier";
}
}
} else {
_local1 = _local1 + nam;
}
_local1 = _local1 + (("_" + type) + (random(2) + 1));
snd_play(_local1, 40 + ((random(10) + 1) * 3));
}
function loadmenu(success) {
snd_stop("amb_toilet1");
snd_stop("amb_toilet2");
snd_stop("amb_train");
snd_stop("amb_grocery");
snd_stop("amb_park");
snd_stop("amb_cafe");
snd_stop("amb_rainy");
var _local4 = _root.world;
_local4.gotoAndStop(1);
_local4.mc.mouth.gotoAndStop((success ? "smile" : "d"));
var _local5 = ["cashier", "urinal", "transport", "coffee", "park", "romance"];
var _local6 = [0, 0, 0, 1, 2, 3];
var _local3 = 0;
while (_local3 < _local5.length) {
_local4 = _root.world;
if (prog < _local6[_local3]) {
_local4[_local5[_local3]].onRollOver = function () {
_root.snd_play("buttonlocked");
};
} else {
_local4[_local5[_local3]].lock._visible = false;
_local4[_local5[_local3]].onRollOver = function () {
this.gotoAndStop(2);
_root.snd_play("buttonselect");
};
_local4[_local5[_local3]].onRollOut = function () {
this.gotoAndStop(1);
};
_local4[_local5[_local3]].onPress = function () {
this.gotoAndStop(1);
_root.snd_play("buttonpress");
_root.levelstart(this._name);
};
}
_local3++;
}
_local4.twit.onRollOver = function () {
this.gotoAndStop(2);
_root.snd_play("buttonselect");
};
_local4.twit.onRollOut = function () {
this.gotoAndStop(1);
};
_local4.twit.onPress = function () {
this.gotoAndStop(1);
_root.snd_play("buttonpress");
getURL ("http://twitter.com/googumproduce", "_blank");
};
levelnam = "menu";
}
function textbox(txt, end, color) {
var _local2 = _root.world.txtbox;
var _local3 = _root.world.rtrn;
if (txt == undefined) {
_local2._visible = false;
_local3._visible = false;
return(undefined);
}
_local2._visible = true;
_local2.output.text = txt;
_local2.output._width = 800;
_local2.output.textColor = ((color == undefined) ? 16777215 : (color));
_local2.output._width = _local2.output.textWidth + 64;
_local2.output._height = _local2.output.textHeight + 32;
_local2.output._x = -(_local2.output._width / 2);
_local2.back._width = _local2.output._width + 20;
_local2.back._height = _local2.output._height;
if (end == 2) {
snd_play("successmenu");
successend = 1;
}
if (end == 1) {
snd_play("failmenu");
_local3._visible = true;
_local3._x = (_local2._x + (_local2.back._width / 2)) - (_local3._width / 2);
_local3._y = (_local2._y + _local2._height) + (_local3._height / 2);
}
}
function levelstart(nam) {
var _local2 = _root.world;
_local2.gotoAndStop(nam);
levelnam = nam;
levelphase = 0;
_root["level_" + nam](0);
loadgazes();
}
function loadgazes() {
var _local5 = ["ul", "u", "ur", "cl", "c", "cr", "dl", "d", "dr"];
var _local3 = 0;
while (_local3 < _local5.length) {
var _local4 = _root.world;
_local4["view_" + _local5[_local3]].onRollOver = function () {
_root.gazechange(this._name);
};
_local4["view_" + _local5[_local3]].onDragOver = function () {
_root.gazechange(this._name);
};
_local4["view_" + _local5[_local3]].useHandCursor = false;
_local3++;
}
}
function gazechange(nam) {
nam = nam.split("_");
gaze = nam[1];
}
function goalcheck() {
var _local7 = 0;
var _local8 = 0;
var _local5 = 0;
var _local6 = 0;
var _local9 = 0;
var _local4 = _root.world;
var _local3 = 0;
while (_local3 < goals.length) {
var _local2 = goals[_local3];
if (_local2 == undefined) {
} else if (gaze != _local2.gaze) {
switch (_local2.type) {
case "glance" :
if (_local2.prog) {
_local2.prog = 0;
_local2.count--;
if (_local2.count == 0) {
goalreached(_local3);
return(1);
}
}
break;
case "look" :
_local2.prog = 0;
break;
case "stare" :
_local2.prog = 0;
_local2.time = _local2.otime;
}
if ((!_local8) && (_local2.inaction != undefined)) {
_local5 = _local2.inaction;
}
if ((!_local7) && (_local2.unreaction != undefined)) {
_local6 = _local2.unreaction;
}
} else {
if (_local2.action != undefined) {
_local8 = 1;
_local4.mc.mouth.gotoAndStop(_local2.action);
_local5 = 0;
}
if (_local2.reaction != undefined) {
_local7 = 1;
_local4.npc.gotoAndStop(_local2.reaction);
_local6 = 0;
}
switch (_local2.type) {
case "glance" :
_local2.prog = 1;
break;
case "stare" :
case "look" :
if (_local2.prog != 0) {
_local2.time = _local2.time - (getTimer() - _local2.prog);
if (_local2.time <= 0) {
goalreached(_local3);
return(1);
}
}
_local2.prog = getTimer();
_local9 = 1;
}
}
_local3++;
}
if (_local5 != 0) {
_local4.mc.mouth.gotoAndStop(_local5);
}
if (_local6 != 0) {
_local4.npc.gotoAndStop(_local6);
}
return(_local9);
}
function goalreached(id) {
var _local2 = goals[id];
if (_local2.phaseless) {
_root["level_" + levelnam](_local2.goal);
} else {
_root["level_" + levelnam]((levelphase + "_") + _local2.goal);
}
}
function copyobject(ob) {
var _local2 = new Object();
for (var _local3 in ob) {
_local2[_local3] = ob[_local3];
}
return(_local2);
}
function exportobject(obj) {
var _local2 = "{";
var _local4 = 0;
for (var _local5 in obj) {
if (_local4) {
_local2 = _local2 + ", ";
}
var _local3 = typeof(obj[_local5]);
if (obj[_local5] == undefined) {
_local2 = _local2 + ((_local5 + ":") + 0);
} else if (_local3 == "string") {
_local2 = _local2 + ((_local5 + ":") + exportstring(obj[_local5]));
} else if (_local3 == "number") {
_local2 = _local2 + ((_local5 + ":") + obj[_local5]);
}
_local4++;
}
_local2 = _local2 + "}";
return(_local2);
}
function snd_play(snd, vol) {
var _local2 = "aud_" + snd;
if (_root[_local2] == undefined) {
_root.attachMovie("empty", "mc" + _local2, _root.getNextHighestDepth());
_root[_local2] = new Sound(_root["mc" + _local2]);
_root[_local2].attachSound(snd);
}
if (vol) {
_root[_local2].setVolume(vol);
}
_root[_local2].stop();
_root[_local2].start();
}
function snd_stop(snd) {
var _local2 = "aud_" + snd;
_root[_local2].stop();
}
stop();
contextmenu = new ContextMenu();
contextmenu.hideBuiltInItems();
_root.menu = contextmenu;
sav = SharedObject.getLocal("x");
prog = ((sav.data.prog == undefined) ? 0 : (sav.data.prog));
weirdogoal = {type:"stare", gaze:"c", time:3000, otime:3000, prog:0, goal:"weirdo", phaseless:1};
anmationvar = {timer:0, v:0};
mouseListener = new Object();
var eyedist = 30;
mouseListener.onMouseMove = function () {
var _local2 = _root.world.mc;
var _local6 = trigmove_getangle(0, 0, _local2.eyeR._xmouse, _local2.eyeR._ymouse);
var _local5 = trigmove_getangle(0, 0, _local2.eyeL._xmouse, _local2.eyeL._ymouse);
var _local4 = trigmove_getdist(0, 0, _local2.eyeR._xmouse, _local2.eyeR._ymouse);
var _local3 = trigmove_getdist(0, 0, _local2.eyeL._xmouse, _local2.eyeL._ymouse);
_local4 = ((_local4 > eyedist) ? (eyedist) : (_local4));
_local3 = ((_local3 > eyedist) ? (eyedist) : (_local3));
var _local8 = trigmove_x(_local4, _local6);
var _local7 = trigmove_y(_local4, _local6);
var _local10 = trigmove_x(_local3, _local5);
var _local9 = trigmove_y(_local3, _local5);
tween_init(_local2.eyeR.mc, "out", 60, _local8, _local7);
tween_init(_local2.eyeL.mc, "out", 60, _local10, _local9);
};
Mouse.addListener(mouseListener);
timed = 0;
_root.onEnterFrame = function () {
var _local2 = _root.world.mc;
tween_move(_local2.eyeR.mc);
tween_move(_local2.eyeL.mc);
var _local3 = goalcheck();
if (((timed != 0) && (getTimer() > timed)) && ((!_local3) || (timedforce))) {
timed = 0;
timedforce = 0;
goal = undefined;
_root["level_" + levelnam](levelphase + "_timeout");
}
animationspecials(levelnam);
};
loadmenu();
textbox();
_root.world.txtbox.onPress = function () {
_root.snd_play("bigbuttonpress");
_root.textbox();
if (successend) {
_root.successend = 0;
_root.loadmenu(1);
return(undefined);
}
_root["level_" + _root.levelnam](_root.levelphase);
};
_root.world.txtbox.onRollOver = function () {
_root.snd_play("bigbuttonselect");
};
_root.world.rtrn.onPress = function () {
_root.snd_play("buttonpress");
_root.textbox();
_root.loadmenu();
};
_root.world.rtrn.onRollOver = function () {
_root.snd_play("buttonselect");
};
Frame 2
prevFrame();
Symbol 49 MovieClip Frame 1
stop();
Symbol 52 MovieClip Frame 1
stop();
Symbol 55 MovieClip Frame 1
stop();
Symbol 60 MovieClip Frame 1
stop();
Symbol 63 MovieClip Frame 1
stop();
Symbol 66 MovieClip Frame 1
stop();
Symbol 77 MovieClip Frame 1
_root.talky("d", _parent._parent._name);
Symbol 80 MovieClip Frame 1
_root.talky("smile", _parent._parent._name);
Symbol 83 MovieClip Frame 1
_root.talky("frown", _parent._parent._name);
Symbol 84 MovieClip Frame 1
stop();
Symbol 90 MovieClip Frame 1
stop();
Symbol 148 MovieClip Frame 1
_root.talky("d", "bro");
Symbol 151 MovieClip Frame 1
_root.talky("smile", "bro");
Symbol 154 MovieClip Frame 1
_root.talky("frown", "bro");
Symbol 155 MovieClip Frame 1
stop();
Symbol 172 MovieClip Frame 1
stop();
Symbol 180 MovieClip Frame 1
stop();
Symbol 183 MovieClip Frame 1
stop();
Symbol 195 MovieClip Frame 1
stop();