Tile - YEnergy - Is Energy Port Connected – Ylands

From Bohemia Interactive Community
Jump to navigation Jump to search

Is Energy Port Connected(Entity, Port)

YlandsTile-341.png

static isEnergyPortConnected(entity: YEntity, port: number): boolean;

Parameters

entity

Target entity

port

Target port

Returns

boolean

Availability

Client, Server

Description

Returns whether selected port is connected to the power grid.

Notes

  • Energy ports are numbered from 0, e.g: ports of entity with 3 ports are numbered 0, 1, 2.