GetTooltip
Returns the tooltip text for the object with the given ObjID as a single concatenated string.
This method is a synonym of GetCliloc — both call the same implementation.
ObjID — ID of the object or mobile.
If the tooltip has not been received yet, the method sends a tooltip request to the server and waits briefly (up to ~200 ms) for the response.
Returns an empty string if the object does not exist, the character is disconnected, or the client version does not support tooltips.
For structured access to individual cliloc IDs and parameters, use GetToolTipRec instead.
Возвращает текст тултипа для объекта с указанным ObjID в виде одной строки.
Этот метод является синонимом GetCliloc — оба вызывают одну и ту же реализацию.
ObjID — ID объекта или мобила.
Если тултип ещё не получен, метод отправляет запрос серверу и кратковременно ожидает ответа (до ~200 мс).
Возвращает пустую строку, если объект не существует, персонаж не подключён или версия клиента не поддерживает тултипы.
Для структурированного доступа к отдельным cliloc-идентификаторам и параметрам используйте GetToolTipRec.
function GetTooltip(ObjID: Cardinal): String;
def GetTooltip(ObjID: int) -> str: ...
begin
if FindType($0F0E, Backpack) > 0 then
AddToSystemJournal('Tooltip: ' + GetTooltip(FindItem));
end.
if FindType(0x0F0E, Backpack()) > 0:
AddToSystemJournal(f'Tooltip: {GetTooltip(FindItem())}')