Defensive programming rides again.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2176 542714f4-19e9-0310-aa3c-eee0fc999fb1
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
//
|
||||
// $Id: Sprite.java,v 1.57 2003/01/13 23:53:34 mdb Exp $
|
||||
// $Id: Sprite.java,v 1.58 2003/01/17 03:44:20 mdb Exp $
|
||||
|
||||
package com.threerings.media.sprite;
|
||||
|
||||
@@ -215,8 +215,18 @@ public abstract class Sprite extends AbstractMedia
|
||||
*/
|
||||
public void move (Path path)
|
||||
{
|
||||
// if we already have a path, complain like the dickens
|
||||
if (_path != null) {
|
||||
Log.warning("Refusing to set path; we've already got one " +
|
||||
"[sprite=" + this + ", cpath=" + _path +
|
||||
", npath=" + path + "].");
|
||||
Thread.dumpStack();
|
||||
return;
|
||||
}
|
||||
|
||||
// save off this path
|
||||
_path = path;
|
||||
|
||||
// we'll initialize it on our next tick thanks to a zero path stamp
|
||||
_pathStamp = 0;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user