// Code Of Zeus

var coz = {
	path: ""
};

coz.init = function() {
	var scripts = document.getElementsByTagName("script");
	for(var i = 0; i < scripts.length; i++) {
		var src = scripts[i].getAttribute("src");
		if(!src) { continue; }
		var m = src.match(/coz\.js$/);
		if(m) {
			coz.path = src.substring(0, m.index); break;
		}
	}
};

// COZ & FX

coz.fx = {};

coz.uFormats = function(node) {
	var uFormats = {};
	coz.forEach(coz.getClasses(node),function(uFormat){
		uFormat = uFormat.split(":");
		uKey = uFormat[0];
		uValue = uFormat[1];
		if (uValue) {
			if (uValue.match(/^[0-9]*(\.)?[0-9]+$/)) uValue = +uValue;
			else if (uValue.match(/^(true|false)$/)) uValue = uValue == "true";
			uFormats[uKey] = uValue;
		}
	});
	return uFormats;
};
