Frame 1
var JC = new Object();
JC.Mint = {list:new Array(), mintURL:new String(), register:function (sheets) {
i = 0;
while ((sheet = sheets[i])) {
this.list.push(sheet);
i++;
}
}, apply:function () {
i = 0;
while ((sheet = this.list[i])) {
this.onMousePress(sheet);
i++;
}
}, start:function () {
_global.JC_Mint_hashID = this.generateKey(50);
}, onMousePress:function (sheet) {
var _local1 = sheet[1];
_local1.onPress = function () {
JC.Mint.record(sheet);
};
}, generateKey:function (len) {
var _local3 = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789./0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz";
var _local4 = "";
var _local1 = 0;
while (_local1 < len) {
var _local2 = Math.floor(Math.random(0, _local3.length - 1) * 100);
_local4 = _local4 + _local3.substr(_local2, 1);
_local1++;
}
return(_local4);
}, record:function (sheet) {
var _local4 = new LoadVars();
var _local3 = new LoadVars();
_local3.platform = System.capabilities.os;
_local3.resource = sheet;
_local3.hash = _global.JC_Mint_hashID;
_local3.sendAndLoad(("" + this.mintURL) + "pepper/jamieconnolly/flashtracker/script.php", _local4, "POST");
}};
if (_global.JC_Mint_hashID) {
} else {
JC.Mint.start();
}
Mouse.addListener(JC);
JC.Mint.mintURL = "http://www.haveaslogan.com/mint/";
var xmlPath = "http://www.haveaslogan.com/flash/brands.xml";
var clicks = 0;
var thisStage = new Object();
thisStage.onResize = function () {
click_btn._width = Stage.width;
click_btn._height = Stage.height;
slogan_x.continueTo((Stage.width * 0.5) - (slogan_mc._width * 0.5), 0.8);
loader_mc._x = Stage.width * 0.5;
bg_mc._width = Stage.width;
};
Stage.scaleMode = "noScale";
Stage.align = "LT";
Stage.addListener(thisStage);
var slogan_x = (new mx.transitions.Tween(slogan_mc, "_x", mx.transitions.easing.Strong.easeInOut, (Stage.width * 0.5) - (slogan_mc._width * 0.5), (Stage.width * 0.5) - (slogan_mc._width * 0.5), 0, true));
var slogan_alpha = (new mx.transitions.Tween(slogan_mc, "_alpha", mx.transitions.easing.Regular.easeInOut, 0, 0, 0, true));
slogan_alpha.onMotionFinished = function () {
((slogan_mc._alpha == 100) ? ((click_btn.enabled = true)) : null);
slogan_mc.ting_mc.gotoAndPlay("firstRun");
};
var loader_alpha = (new mx.transitions.Tween(loader_mc, "_alpha", mx.transitions.easing.Regular.easeInOut, 0, 100, 1, true));
loader_alpha.onMotionFinished = function () {
((loader_mc._alpha == 0) ? (slogan_alpha.continueTo(100, 0.5)) : null);
};
var bg_alpha = (new mx.transitions.Tween(bg_mc, "_alpha", mx.transitions.easing.Regular.easeInOut, 0, 100, 2, true));
var loadXML = function (path) {
var _local2 = new XML();
_local2.ignoreWhite = true;
_local2.load(path);
_local2.onLoad = function (xmlFile) {
if (xmlFile) {
xmlNode = this;
numNouns = xmlNode.childNodes[0].childNodes.length;
numSlogans = xmlNode.childNodes[1].childNodes.length;
Noun = new Array();
Slogan = new Array();
i = 0;
while (i < numNouns) {
Noun[i] = xmlNode.childNodes[0].childNodes[i].attributes.value;
i++;
}
i = 0;
while (i < numSlogans) {
Slogan[i] = xmlNode.childNodes[1].childNodes[i].attributes.value;
i++;
}
loader_alpha.continueTo(0, 0.5);
} else {
trace("XML load :: failure");
}
};
};
loadXML(xmlPath);
var randomID = function (num) {
return(Math.round(Math.random() * (num - 1)));
};
var generateSlogan = function () {
var _local1 = randomID(numNouns);
var _local2 = randomID(numSlogans);
((Noun[_local1] == slogan_mc.brand_txt.text) ? (generateSlogan()) : ((slogan_mc.brand_txt.text = Noun[_local1])));
((Slogan[_local2] == slogan_mc.slogan_txt.text) ? (generateSlogan()) : ((slogan_mc.slogan_txt.text = Slogan[_local2])));
};
click_btn.enabled = false;
click_btn.onPress = function () {
generateSlogan();
clicks++;
JC.Mint.record("Site");
};
slogan_mc.murphy_mc.onPress = function () {
generateSlogan();
clicks++;
JC.Mint.record("Site");
slogan_mc.ting_mc.gotoAndPlay("click");
};
thisStage.onResize();
Symbol 63 MovieClip Frame 1
stop();
Symbol 63 MovieClip Frame 14
stop();
Symbol 65 MovieClip [__Packages.mx.transitions.OnEnterFrameBeacon] Frame 0
class mx.transitions.OnEnterFrameBeacon
{
function OnEnterFrameBeacon () {
}
static function init() {
var _local4 = _global.MovieClip;
if (!_root.__OnEnterFrameBeacon) {
mx.transitions.BroadcasterMX.initialize(_local4);
var _local3 = _root.createEmptyMovieClip("__OnEnterFrameBeacon", 9876);
_local3.onEnterFrame = function () {
_global.MovieClip.broadcastMessage("onEnterFrame");
};
}
}
static var version = "1.1.0.52";
}
Symbol 66 MovieClip [__Packages.mx.transitions.BroadcasterMX] Frame 0
class mx.transitions.BroadcasterMX
{
var _listeners;
function BroadcasterMX () {
}
static function initialize(o, dontCreateArray) {
if (o.broadcastMessage != undefined) {
delete o.broadcastMessage;
}
o.addListener = mx.transitions.BroadcasterMX.prototype.addListener;
o.removeListener = mx.transitions.BroadcasterMX.prototype.removeListener;
if (!dontCreateArray) {
o._listeners = new Array();
}
}
function addListener(o) {
removeListener(o);
if (broadcastMessage == undefined) {
broadcastMessage = mx.transitions.BroadcasterMX.prototype.broadcastMessage;
}
return(_listeners.push(o));
}
function removeListener(o) {
var _local2 = _listeners;
var _local3 = _local2.length;
while (_local3--) {
if (_local2[_local3] == o) {
_local2.splice(_local3, 1);
if (!_local2.length) {
broadcastMessage = undefined;
}
return(true);
}
}
return(false);
}
function broadcastMessage() {
var _local5 = String(arguments.shift());
var _local4 = _listeners.concat();
var _local6 = _local4.length;
var _local3 = 0;
while (_local3 < _local6) {
_local4[_local3][_local5].apply(_local4[_local3], arguments);
_local3++;
}
}
static var version = "1.1.0.52";
}
Symbol 67 MovieClip [__Packages.mx.transitions.Tween] Frame 0
class mx.transitions.Tween
{
var obj, prop, begin, useSeconds, _listeners, addListener, prevTime, _time, looping, _duration, broadcastMessage, isPlaying, _fps, prevPos, _pos, change, _intervalID, _startTime;
function Tween (obj, prop, func, begin, finish, duration, useSeconds) {
mx.transitions.OnEnterFrameBeacon.init();
if (!arguments.length) {
return;
}
this.obj = obj;
this.prop = prop;
this.begin = begin;
position = (begin);
this.duration = (duration);
this.useSeconds = useSeconds;
if (func) {
this.func = func;
}
this.finish = (finish);
_listeners = [];
addListener(this);
start();
}
function set time(t) {
prevTime = _time;
if (t > duration) {
if (looping) {
rewind(t - _duration);
update();
broadcastMessage("onMotionLooped", this);
} else {
if (useSeconds) {
_time = _duration;
update();
}
stop();
broadcastMessage("onMotionFinished", this);
}
} else if (t < 0) {
rewind();
update();
} else {
_time = t;
update();
}
//return(time);
}
function get time() {
return(_time);
}
function set duration(d) {
_duration = (((d == null) || (d <= 0)) ? (_global.Infinity) : (d));
//return(duration);
}
function get duration() {
return(_duration);
}
function set FPS(fps) {
var _local2 = isPlaying;
stopEnterFrame();
_fps = fps;
if (_local2) {
startEnterFrame();
}
//return(FPS);
}
function get FPS() {
return(_fps);
}
function set position(p) {
setPosition(p);
//return(position);
}
function setPosition(p) {
prevPos = _pos;
obj[prop] = (_pos = p);
broadcastMessage("onMotionChanged", this, _pos);
updateAfterEvent();
}
function get position() {
return(getPosition());
}
function getPosition(t) {
if (t == undefined) {
t = _time;
}
return(func(t, begin, change, _duration));
}
function set finish(f) {
change = f - begin;
//return(finish);
}
function get finish() {
return(begin + change);
}
function continueTo(finish, duration) {
begin = position;
this.finish = (finish);
if (duration != undefined) {
this.duration = (duration);
}
start();
}
function yoyo() {
continueTo(begin, time);
}
function startEnterFrame() {
if (_fps == undefined) {
_global.MovieClip.addListener(this);
} else {
_intervalID = setInterval(this, "onEnterFrame", 1000 / _fps);
}
isPlaying = true;
}
function stopEnterFrame() {
if (_fps == undefined) {
_global.MovieClip.removeListener(this);
} else {
clearInterval(_intervalID);
}
isPlaying = false;
}
function start() {
rewind();
startEnterFrame();
broadcastMessage("onMotionStarted", this);
}
function stop() {
stopEnterFrame();
broadcastMessage("onMotionStopped", this);
}
function resume() {
fixTime();
startEnterFrame();
broadcastMessage("onMotionResumed", this);
}
function rewind(t) {
_time = ((t == undefined) ? 0 : (t));
fixTime();
update();
}
function fforward() {
time = (_duration);
fixTime();
}
function nextFrame() {
if (useSeconds) {
time = ((getTimer() - _startTime) / 1000);
} else {
time = (_time + 1);
}
}
function onEnterFrame() {
nextFrame();
}
function prevFrame() {
if (!useSeconds) {
time = (_time - 1);
}
}
function toString() {
return("[Tween]");
}
function fixTime() {
if (useSeconds) {
_startTime = getTimer() - (_time * 1000);
}
}
function update() {
position = (getPosition(_time));
}
static var version = "1.1.0.52";
static var __initBeacon = mx.transitions.OnEnterFrameBeacon.init();
static var __initBroadcaster = mx.transitions.BroadcasterMX.initialize(mx.transitions.Tween.prototype, true);
function func(t, b, c, d) {
return(((c * t) / d) + b);
}
}
Symbol 68 MovieClip [__Packages.mx.transitions.easing.Strong] Frame 0
class mx.transitions.easing.Strong
{
function Strong () {
}
static function easeIn(t, b, c, d) {
t = t / d;
return((((((c * t) * t) * t) * t) * t) + b);
}
static function easeOut(t, b, c, d) {
t = (t / d) - 1;
return((c * (((((t * t) * t) * t) * t) + 1)) + b);
}
static function easeInOut(t, b, c, d) {
t = t / (d / 2);
if (t < 1) {
return(((((((c / 2) * t) * t) * t) * t) * t) + b);
}
t = t - 2;
return(((c / 2) * (((((t * t) * t) * t) * t) + 2)) + b);
}
static var version = "1.1.0.52";
}
Symbol 69 MovieClip [__Packages.mx.transitions.easing.Regular] Frame 0
class mx.transitions.easing.Regular
{
function Regular () {
}
static function easeIn(t, b, c, d) {
t = t / d;
return(((c * t) * t) + b);
}
static function easeOut(t, b, c, d) {
t = t / d;
return((((-c) * t) * (t - 2)) + b);
}
static function easeInOut(t, b, c, d) {
t = t / (d / 2);
if (t < 1) {
return((((c / 2) * t) * t) + b);
}
t--;
return((((-c) / 2) * ((t * (t - 2)) - 1)) + b);
}
static var version = "1.1.0.52";
}