public void connectSpotLight(SpotLight a_spotlight) { if (!a_spotlight.isDead() && !m_connectedSpotLights.Contains(a_spotlight)) { m_connectedSpotLights.AddLast(a_spotlight); m_connectedSpotLightsId.AddLast(a_spotlight.getId()); } }
public bool isConnectedTo(SpotLight a_spotLight) { foreach (SpotLight t_spotLight in m_connectedSpotLights) { if (a_spotLight == t_spotLight) { return true; } } return false; }
public void disconnectSpotLight(SpotLight a_spotlight) { m_connectedSpotLights.Remove(a_spotlight); m_connectedSpotLightsId.Remove(a_spotlight.getId()); }
private void connectSpotLight(SpotLight a_spotLight, LampSwitch a_lightSwitch) { a_lightSwitch.connectSpotLight(a_spotLight); }