mirror of
https://github.com/photonstorm/phaser
synced 2025-02-18 15:08:31 +00:00
Console warning if frame doesn't exist
* `GenerateFrameNames` will now console.warn if the generated frame isn't present in the texture, which should help with debugging animation creation massively. * `GenerateFrameNumbers` will now console.warn if the generated frame isn't present in the texture, which should help with debugging animation creation massively.
This commit is contained in:
parent
d44fc88705
commit
70110825da
1 changed files with 16 additions and 0 deletions
|
@ -518,6 +518,10 @@ var AnimationManager = new Class({
|
||||||
{
|
{
|
||||||
out.push({ key: key, frame: frame });
|
out.push({ key: key, frame: frame });
|
||||||
}
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
console.warn('generateFrameNames: Frame missing: ' + frame + ' from texture: ' + key);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
@ -530,6 +534,10 @@ var AnimationManager = new Class({
|
||||||
{
|
{
|
||||||
out.push({ key: key, frame: frame });
|
out.push({ key: key, frame: frame });
|
||||||
}
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
console.warn('generateFrameNames: Frame missing: ' + frame + ' from texture: ' + key);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -582,6 +590,10 @@ var AnimationManager = new Class({
|
||||||
{
|
{
|
||||||
out.push({ key: key, frame: frames[i] });
|
out.push({ key: key, frame: frames[i] });
|
||||||
}
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
console.warn('generateFrameNumbers: Frame ' + i + ' missing from texture: ' + key);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
@ -603,6 +615,10 @@ var AnimationManager = new Class({
|
||||||
{
|
{
|
||||||
out.push({ key: key, frame: i });
|
out.push({ key: key, frame: i });
|
||||||
}
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
console.warn('generateFrameNumbers: Frame ' + i + ' missing from texture: ' + key);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue