Garry's Mod

Garry's Mod

71 个评价
Team Gates/Walls
   
奖励
收藏
已收藏
取消收藏
素材类型: 插件
插件类型: 工具
插件标签: 建筑, 角色扮演
文件大小
发表于
更新日期
372.853 KB
2017 年 7 月 16 日 下午 1:23
2017 年 7 月 29 日 下午 2:47
3 项改动说明 ( 查看 )

订阅以下载
Team Gates/Walls

描述
This should work with any gamemode. But there is still a possibility that there can be some compatability issues.
Teams will only work if the gamemode is using the default team system in Garry's Mod

This addon has a configuration file accessible if you extract the workshop addon or get the source code from the git repository[github.com]

This is a system that allows players to spawn a gate which can be customised to allow only certain people (by team, ULX/ULib Group, SteamID), vehicles and NPCs through it.
I've tried to make the system as feature-rich by default as I could, but it allows for further customisation through hooks.
Very few values are hardcoded and values that aren't can be configured (Those that aren't can be found in the entity files themselves, however I can't guarantee the quality of the system staying the same if you modify any file but the config.lua) through the config.lua file included (located in team-gates/lua/entities/ent_ryn_team_gate/).
Further configuration of the gates can be done on a gate-by-gate basis by pressing E on a gate (if you're the one who spawned it, or if you're an admin pressing E on a non-personal team gate).
The gates are respawned after cleanup, map change and server restart, however, the gates are only saved to one map (e.g. spawning a gate on gm_construct wont spawn the same gate if you change to gm_flatgrass).

The gates can be bypassed using weapons (this can be disabled in the config.lua file), currently there's two weapons with two different goals.
One intended for admin use (can only be spawned by admins, but in e.g. DarkRP can be given with a job) that allows any player that has the swep equipped to bypass any gate (depending on the server configurations).
One with a keypad-cracker style to it, after X seconds (4 by default) of attempting to bypass (left clicking on a gate), the player can pass through that gate, for y seconds (default 2).

Do note that the menu uses the default Garry's Mod derma skin (or DarkRP if it's used on a DarkRP server and the configuration isn't set to do otherwise) and every player can change the derma skin that they want their panel to use to any loaded derma skin.

Guide

  • Extensive configuration is available through a lua file, either download the addon from the git repository[github.com] or extract the workshop addon
  • As the system allows quite extensive configuration, make sure you check the config.lua file to see if there's something you want to change before using the gates.
  • After installation the team gate can be spawned in three different ways
    • Through the entities tab in the Q menu, in the "Rynoxx" category click on the "Team Gate" entity.
    • Through a toolgun
    • Through a console command: rynteamgate_spawn
  • After you've spawned a Team Gate you can configure it by pressing the interact/use key (Default E) on it
    • Team gates are automatically saved and will respawn after cleanup, map change and server restart
    • All team gates are saved on a per-map basis (e.g. spawning a gate on gm_construct wont spawn the same gate on gm_flatgrass after a map change)

Use Cases
  • Creating a vehicle-free zone
  • Creating zones for certain teams
    • Could be used as spawn areas
    • Some kind of gang zone
  • Creating an admin room/area
  • NPC safe zone (on e.g. a zombie map)
  • Creating combine fences (e.g. for HL2RP) (comes with the option to automatically put combine fences on gates)

Credits

Source Code
The source code is available on GitHub[github.com] and is released under the GNU Affero General Public License v3 (AGPL-3.0)[github.com]
This is a public release of a script I previously published on ScriptFodder

Bug reporting/Suggestions
Any bugs/errors/suggestions should be posted on GitHub[github.com], I will not be looking at the workshop comments often.
26 条留言
jojomanovavidea 1 月 16 日 上午 10:17 
its creating lua errors
SeraFim 2023 年 12 月 13 日 上午 8:32 
Who has faced the problem that it does not work?
Rynoxx  [作者] 2023 年 6 月 4 日 下午 2:40 
If it uses the standard team function in GMod, yes
unlikeaboss 2023 年 6 月 4 日 下午 2:15 
hey is this compatible with sandbox team manager
Notispadiko 2022 年 7 月 21 日 上午 2:01 
it works thanks for the answer btw
Rynoxx  [作者] 2022 年 7 月 21 日 上午 12:09 
If it uses the regular team function in GMod, yes, otherwise I don't know.
Notispadiko 2022 年 7 月 20 日 下午 4:50 
does it works with team manager addon ?
Rynoxx  [作者] 2022 年 1 月 25 日 下午 1:55 
@notispadiko Yes, it should work with DarkRP jobs, at least it did when it was first created.
No clue if the way DarkRP jobs work have changed since then.
Notispadiko 2022 年 1 月 25 日 下午 12:50 
can i use it with dark rp jobs
??