home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
CyberMycha 2003 October
/
cmycha200310.iso
/
NHL2004
/
NHL2004Demo.exe
/
fe
/
COMMON
/
js
/
NHL_Stats_Base.js
< prev
next >
Wrap
Text File
|
2003-08-20
|
2KB
|
82 lines
function NHL_Stats_Base()
{
if( !(this instanceof NHL_Stats_Base)) return new NHL_Stats_Base( );
var protect = this.createProtection(JAX_Object);
protect.gamePoints = "";
protect.otWins = "";
protect.otLosses = "";
protect.draws = "";
};
NHL_Stats_Base.prototype = new JAX_Object;
NHL_Stats_Base.prototype.getGamePoints = function()
{
try {
var protect = this.getProtection(NHL_Stats_Base);
return protect.gamePoints;
} catch (e) {
return -1;
};
};
NHL_Stats_Base.prototype.getOT_Wins = function()
{
try {
var protect = this.getProtection(NHL_Stats_Base);
return protect.otWins;
} catch (e) {
return -1;
};
};
NHL_Stats_Base.prototype.getOT_Losses = function()
{
try {
var protect = this.getProtection(NHL_Stats_Base);
return protect.otLosses;
} catch (e) {
return -1;
};
};
NHL_Stats_Base.prototype.getDraws = function()
{
try {
var protect = this.getProtection(NHL_Stats_Base);
return protect.draws;
} catch (e) {
return -1;
};
};
NHL_Stats_Base.prototype.setGamePoints = function(gamePoints)
{
var protect = this.getProtection(NHL_Stats_Base);
if ( !(isNaN(parseInt(gamePoints))) ) {
protect.gamePoints = gamePoints;
} else {
protect.gamePoints = 0;
};
};
NHL_Stats_Base.prototype.setOT_Wins = function(winCount)
{
var protect = this.getProtection(NHL_Stats_Base);
if ( !(isNaN(parseInt(winCount))) ) {
protect.otWins = winCount;
} else {
protect.otWins = 0;
};
};
NHL_Stats_Base.prototype.setOT_Losses = function(lossCount)
{
var protect = this.getProtection(NHL_Stats_Base);
if ( !(isNaN(parseInt(lossCount))) ) {
protect.otLosses = lossCount;
} else {
protect.otLosses = 0;
};
};
NHL_Stats_Base.prototype.setDraws = function(drawCount)
{
var protect = this.getProtection(NHL_Stats_Base);
if ( !(isNaN(parseInt(drawCount))) ) {
protect.draws = drawCount;
} else {
protect.draws = 0;
};
};