From 0317828b1dfcd9efeb77974ee979443122f0b822 Mon Sep 17 00:00:00 2001 From: Ray Greenwell Date: Fri, 14 Jun 2002 23:03:44 +0000 Subject: [PATCH] Clone the occupant info before updating the location. This fixes the beamed-in NPP problem- they were updating their location on the server before the element added event was even distributed to the clients. git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@1463 542714f4-19e9-0310-aa3c-eee0fc999fb1 --- .../threerings/whirled/spot/server/SpotSceneManager.java | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/java/com/threerings/whirled/spot/server/SpotSceneManager.java b/src/java/com/threerings/whirled/spot/server/SpotSceneManager.java index 095d568d0..c09892eb7 100644 --- a/src/java/com/threerings/whirled/spot/server/SpotSceneManager.java +++ b/src/java/com/threerings/whirled/spot/server/SpotSceneManager.java @@ -1,5 +1,5 @@ // -// $Id: SpotSceneManager.java,v 1.7 2002/06/12 07:05:55 ray Exp $ +// $Id: SpotSceneManager.java,v 1.8 2002/06/14 23:03:44 ray Exp $ package com.threerings.whirled.spot.server; @@ -165,7 +165,10 @@ public class SpotSceneManager extends SceneManager if (!_isPortal[locidx]) { _locationOccs[locidx] = bodyOid; } - // update their occupant info + // update a clone of their occupant info, we need to clone because + // the original could still be in the queue as part of another + // event going out to the clients. + soi = (SpotOccupantInfo) soi.clone(); soi.locationId = locationId; // and broadcast the update to the place _plobj.updateOccupantInfo(soi);