Change "readObject() as Type" to "Type(readObject())" for vilya for better error checking and faster failure
git-svn-id: svn+ssh://src.earth.threerings.net/vilya/trunk@758 c613c5cb-e716-0410-b11b-feb51c14d237
This commit is contained in:
@@ -102,7 +102,7 @@ public class SceneModel extends SimpleStreamableObject
|
||||
sceneId = ins.readInt();
|
||||
name = (ins.readField(String) as String);
|
||||
version = ins.readInt();
|
||||
auxModels = (ins.readObject() as TypedArray);
|
||||
auxModels = TypedArray(ins.readObject());
|
||||
}
|
||||
|
||||
// documentation inherited from interface Streamable
|
||||
|
||||
@@ -75,7 +75,7 @@ public class ClusterObject extends DObject
|
||||
{
|
||||
super.readObject(ins);
|
||||
|
||||
occupants = (ins.readObject() as OidList);
|
||||
occupants = OidList(ins.readObject());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -81,8 +81,8 @@ public class ModifyPortalsUpdate extends SceneUpdate
|
||||
override public function readObject (ins :ObjectInputStream) :void
|
||||
{
|
||||
super.readObject(ins);
|
||||
portalsRemoved = (ins.readObject() as TypedArray);
|
||||
portalsAdded = (ins.readObject() as TypedArray);
|
||||
portalsRemoved = TypedArray(ins.readObject());
|
||||
portalsAdded = TypedArray(ins.readObject());
|
||||
}
|
||||
|
||||
// from interface Streamable
|
||||
|
||||
@@ -127,7 +127,7 @@ public class Portal extends SimpleStreamableObject
|
||||
{
|
||||
super.readObject(ins);
|
||||
portalId = ins.readShort();
|
||||
loc = (ins.readObject() as Location);
|
||||
loc = Location(ins.readObject());
|
||||
targetSceneId = ins.readInt();
|
||||
targetPortalId = ins.readShort();
|
||||
}
|
||||
|
||||
@@ -75,7 +75,7 @@ public class SceneLocation extends SimpleStreamableObject
|
||||
{
|
||||
super.readObject(ins);
|
||||
bodyOid = ins.readInt();
|
||||
loc = (ins.readObject() as Location);
|
||||
loc = Location(ins.readObject());
|
||||
}
|
||||
|
||||
// documentation inherited from superinterface Streamable
|
||||
|
||||
@@ -102,7 +102,7 @@ public class SpotSceneModel extends SimpleStreamableObject
|
||||
override public function readObject (ins :ObjectInputStream) :void
|
||||
{
|
||||
super.readObject(ins);
|
||||
portals = (ins.readObject() as TypedArray);
|
||||
portals = TypedArray(ins.readObject());
|
||||
defaultEntranceId = ins.readInt();
|
||||
}
|
||||
|
||||
|
||||
@@ -158,8 +158,8 @@ public class SpotSceneObject extends SceneObject
|
||||
{
|
||||
super.readObject(ins);
|
||||
|
||||
occupantLocs = (ins.readObject() as DSet);
|
||||
clusters = (ins.readObject() as DSet);
|
||||
occupantLocs = DSet(ins.readObject());
|
||||
clusters = DSet(ins.readObject());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -66,8 +66,8 @@ public class SceneSummary
|
||||
{
|
||||
sceneId = ins.readInt();
|
||||
name = (ins.readField(String) as String);
|
||||
neighbors = (ins.readObject() as TypedArray);
|
||||
neighborDirs = (ins.readObject() as TypedArray);
|
||||
neighbors = TypedArray(ins.readObject());
|
||||
neighborDirs = TypedArray(ins.readObject());
|
||||
}
|
||||
|
||||
// from interface Streamable
|
||||
|
||||
@@ -62,8 +62,8 @@ public class ZoneSummary extends SimpleStreamableObject
|
||||
{
|
||||
super.readObject(ins);
|
||||
zoneId = ins.readInt();
|
||||
name = (ins.readObject() as Name);
|
||||
scenes = (ins.readObject() as TypedArray);
|
||||
name = Name(ins.readObject());
|
||||
scenes = TypedArray(ins.readObject());
|
||||
}
|
||||
|
||||
// from interface Streamable
|
||||
|
||||
Reference in New Issue
Block a user