Remove references to GameMath, it's just Math now

Throw exceptions if wrong format given to tilemap or textureatlas. Previously, old onload remained active and error happened in the wrong (and hard to diagnose) place.
This commit is contained in:
TheJare
2013-11-20 00:12:37 +01:00
parent 40e1b4b9aa
commit f115a2dbf8
4 changed files with 12 additions and 4 deletions
+9 -1
View File
@@ -744,6 +744,10 @@ Phaser.Loader.prototype = {
return _this.csvLoadComplete(file.key);
};
}
else
{
throw new Error("Phaser.Loader. Invalid Tilemap format: " + file.format);
}
this._xhr.onerror = function () {
return _this.dataLoadError(file.key);
@@ -873,6 +877,10 @@ Phaser.Loader.prototype = {
return _this.xmlLoadComplete(file.key);
};
}
else
{
throw new Error("Phaser.Loader. Invalid Texture Atlas format: " + file.format);
}
this._xhr.onerror = function () {
return _this.dataLoadError(file.key);
@@ -1105,4 +1113,4 @@ Phaser.Loader.prototype = {
}
};
};