---
title: "GetPlayer3DTextLabelColour | open.mp"
description: "获取玩家3D文本标签的颜色"
canonical: https://omp.itsneufox.com/zh-CN/docs/scripting/functions/GetPlayer3DTextLabelColour
language: zh-CN
---

# GetPlayer3DTextLabelColour

注意

这个函数是在omp v1.1.0.2612中添加的，在以前的版本中不起作用！

## 描述

获取玩家 3D 文本标签的颜色。

| 参数 | 说明 |
| --- | --- |
| playerid | 玩家的 ID |
| PlayerText3D:textid | 需要获取颜色的玩家 3D 文本标签 ID |

## 返回值

返回玩家 3D 文本标签的颜色值（ARGB 格式）。

## 示例代码

```c
new PlayerText3D:playerTextId;
new Float:x, Float:y, Float:z;
new colour;

GetPlayerPos(playerid, x, y, z);
playerTextId = CreatePlayer3DTextLabel(playerid, "Hello\nI'm at your position", 0x008080FF, x, y, z, 40.0);

colour = GetPlayer3DTextLabelColour(playerid, playerTextId);
// colour = 0x008080FF
```

## 相关函数

-   [Get3DTextLabelColour](https://omp.itsneufox.com/zh-CN/docs/scripting/functions/Get3DTextLabelColour): 获取 3D 文本标签颜色
