Energy manager: Unplugs the given device from this one.
448 {
450 {
452 bool deviceFound = false;
453
454 for (int i = indexStart; i >= 0; --i)
455 {
457
458 if (plugged_device == device_to_unplug)
459 {
461 deviceFound = true;
462 break;
463 }
464 }
465
467 {
468 int socket_ID = device_to_unplug.GetCompEM().GetMySocketID();
470 device_to_unplug.GetCompEM().SetEnergySource(null);
471 device_to_unplug.GetCompEM().DeviceUpdate();
472 device_to_unplug.GetCompEM().StartUpdates();
474
476 {
479 }
480
485 }
486 }
487 }
static const string SEL_CORD_FOLDED
void UnplugCordFromSocket(int socket_to_unplug_ID)
int GetPluggedDevicesCount()
Energy manager: Returns the number of devices plugged into this one.
array< EntityAI > GetPluggedDevices()
Energy manager: Returns an array of devices which are plugged into this one.
static const string SEL_CORD_PLUGGED
void OnOwnSocketReleased(EntityAI device)