public void AddObject(SceneObject obj) { objects.Add(obj); }
private void updateGameObjectFromsceneData(int scene, GameObj go, SceneObject so) { if (so.Type == Constants.ROAD_BLOCK_T) { go.SpriteName = "road_block"; base.ObjectManager.AddGameObject(go, so.Lane); int offset = lastScreenOffset; go.UpdatePosition(so.X + offset, LanePositionY[so.Lane] - go.W / 2); } else if (so.Type == Constants.BARRICADE) { go.SpriteName = "barricade"; base.ObjectManager.AddGameObject(go, so.Lane); int offset = lastScreenOffset; go.UpdatePosition(so.X + offset, LanePositionY[so.Lane] - go.W / 2); } }