---
title: "IsPlayerInGangZone | open.mp"
description: "检测玩家是否处于帮派区域内"
canonical: https://omp.itsneufox.com/zh-CN/docs/scripting/functions/IsPlayerInGangZone
language: zh-CN
---

# IsPlayerInGangZone

注意

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

## 描述

检测玩家是否处于帮派区域内

| 参数名 | 说明 |
| --- | --- |
| playerid | 需要检测的玩家 ID |
| zoneid | 帮派区域 ID |

## 返回值

**true** - 玩家处于帮派区域内

**false** - 玩家未处于帮派区域内

## 注意事项

注意

-   此函数仅适用于 open.mp 平台，SA-MP 需使用[YSF 插件](https://github.com/IS4Code/YSF/releases)
-   必须预先调用[UseGangZoneCheck](https://omp.itsneufox.com/zh-CN/docs/scripting/functions/UseGangZoneCheck)函数方可使用本检测功能

## 相关函数

-   [GangZoneDestroy](https://omp.itsneufox.com/zh-CN/docs/scripting/functions/GangZoneDestroy): 销毁帮派区域
-   [GangZoneShowForPlayer](https://omp.itsneufox.com/zh-CN/docs/scripting/functions/GangZoneShowForPlayer): 为玩家显示帮派区域
-   [GangZoneShowForAll](https://omp.itsneufox.com/zh-CN/docs/scripting/functions/GangZoneShowForAll): 为全体玩家显示帮派区域
-   [GangZoneHideForPlayer](https://omp.itsneufox.com/zh-CN/docs/scripting/functions/GangZoneHideForPlayer): 为玩家隐藏帮派区域
-   [GangZoneHideForAll](https://omp.itsneufox.com/zh-CN/docs/scripting/functions/GangZoneHideForAll): 为全体玩家隐藏帮派区域
-   [GangZoneFlashForPlayer](https://omp.itsneufox.com/zh-CN/docs/scripting/functions/GangZoneFlashForPlayer): 使帮派区域对玩家闪烁
-   [GangZoneFlashForAll](https://omp.itsneufox.com/zh-CN/docs/scripting/functions/GangZoneFlashForAll): 使帮派区域对所有玩家闪烁
-   [GangZoneStopFlashForPlayer](https://omp.itsneufox.com/zh-CN/docs/scripting/functions/GangZoneStopFlashForPlayer): 停止帮派区域对玩家闪烁
-   [GangZoneStopFlashForAll](https://omp.itsneufox.com/zh-CN/docs/scripting/functions/GangZoneStopFlashForAll): 停止帮派区域对所有玩家闪烁
-   [IsValidGangZone](https://omp.itsneufox.com/zh-CN/docs/scripting/functions/IsValidGangZone): 验证帮派区域有效性
