Allow portals to have a targetPortalId of -1, which means simply
"whatever the default entrance is of the target scene". git-svn-id: svn+ssh://src.earth.threerings.net/vilya/trunk@12 c613c5cb-e716-0410-b11b-feb51c14d237
This commit is contained in:
@@ -91,7 +91,12 @@ public class SpotSceneManager extends SceneManager
|
||||
*/
|
||||
public void mapEnteringBody (BodyObject body, int portalId)
|
||||
{
|
||||
_enterers.put(body.getOid(), portalId);
|
||||
// small optimization: don't save portalId -1, because it simply means
|
||||
// "use the default entrance" and retrieving an unset value will
|
||||
// return -1 anyway
|
||||
if (portalId != -1) {
|
||||
_enterers.put(body.getOid(), portalId);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user