DayZ 1.30
DayZ Explorer by KGB
 
Загрузка...
Поиск...
Не найдено

◆ UnplugCordFromSocket()

void ComponentEnergyManager::UnplugCordFromSocket ( int socket_to_unplug_ID)
inlineprotected

См. определение в файле ComponentEnergyManager.c строка 1693

1694 {
1695 EntityAI plug_owner = GetDeviceBySocketID(socket_to_unplug_ID);
1696
1697 if (m_ThisEntityAI && plug_owner)
1698 {
1699 SetDeviceBySocketID(socket_to_unplug_ID, NULL);
1700 string unplugged_selection = SOCKET_ + (socket_to_unplug_ID+1).ToString() + _AVAILABLE;
1701 m_ThisEntityAI.ShowSelection ( unplugged_selection );
1702
1703 string plugged_selection = SOCKET_ + (socket_to_unplug_ID+1).ToString() + _PLUGGED;
1704 m_ThisEntityAI.HideSelection ( plugged_selection );
1705 SetPlugOwner( plugged_selection, NULL );
1706 plug_owner.GetCompEM().SetMySocketID(-1);
1707 }
1708 }
class LogManager EntityAI
proto string ToString()
EntityAI m_ThisEntityAI
Определения Component.c:24
static const string SOCKET_
Определения ComponentEnergyManager.c:62
static const string _AVAILABLE
Определения ComponentEnergyManager.c:64
static const string _PLUGGED
Определения ComponentEnergyManager.c:63
void SetPlugOwner(string selection_name, EntityAI device)
Определения ComponentEnergyManager.c:1683
void SetDeviceBySocketID(int id, EntityAI plugged_device)
Energy manager: Stores the device which is plugged into the given socket ID.
Определения ComponentEnergyManager.c:681
EntityAI GetDeviceBySocketID(int id)
Energy manager: Returns the device which is plugged into the given socket ID.
Определения ComponentEnergyManager.c:1330

Перекрестные ссылки _AVAILABLE, _PLUGGED, GetDeviceBySocketID(), Component::m_ThisEntityAI, SetDeviceBySocketID(), SetPlugOwner(), SOCKET_ и ToString().

Используется в UnplugDevice().