Garry's Mod

Garry's Mod

80 个评价
Traffic Lighter
   
奖励
收藏
已收藏
取消收藏
素材类型: 插件
插件类型: 服务器内容
插件标签: 角色扮演, 写实
文件大小
发表于
更新日期
1.061 MB
2015 年 12 月 31 日 上午 8:50
2016 年 1 月 15 日 下午 1:02
2 项改动说明 ( 查看 )

订阅以下载
Traffic Lighter

描述
Traffic Lighter is a lua script for automate traffic light.

2 traffic light model is supported :
- models/props_c17/traffic_light001a.mdl
- models/props/cs_assault/stoplight.mdl

  • Configuration traffic light :
    Create server-side lua script and use array variable
    TRAFFIC_LIGHTER_CONFIG["model link"] = {Timer = time for next light, TimerWait = time for wait light}

  • Exemple lua script :
    TRAFFIC_LIGHTER_CONFIG["models/props_c17/traffic_light001a.mdl"] = {Timer = 20, TimerWait = 5}

Lua Properties :

string color = ex :tostring(Color(255, 0, 0, 255))

ENTITY:SetTimer(int)
ENTITY:SetTimerWait(int)

ENTITY:SetLightStop(string color)
ENTITY:SetLightWait(string color)
ENTITY:SetLightStart(string color)

ENTITY:SetLight(string color)

Source Code : https://github.com/StidOfficial/Traffic-Lighter
热门讨论 查看全部(1)
2
2016 年 9 月 6 日 上午 10:56
Pole is an Error, fix it?
Sammysat
23 条留言
FoXikYtByHoww 2023 年 11 月 14 日 上午 1:07 
WARNING! Carry on reading! Or you will die, even if you only looked at the word warning! Once there was a little girl called Clarissa, she was ten-years-old and she lived in a mental hospital, because she killed her mom and her dad. She got so bad she went to kill all the staff in the hospital so the More- government decided that best idea was to get rid of her so they set up a special room to kill her, as humane as possible but it went wrong the machine they were using went wrong. And she sat there in agony for hours until she died. Now every week on the day of her death she returns to the person that reads this letter, on a monday night at 12:00a.m. She creeps into your room and kills you slowly, by cutting you and watching you bleed to death. Now send this to ten other profiles on this one site, and she will haunt someone else who doesn't. This isn't fake. apparently, if u copy and paste this to ten comments in the next ten minutes u will have the best of your life
MaxZemX 2018 年 10 月 5 日 上午 6:54 
Problem in green...
YeOl'Choppa 2018 年 6 月 30 日 上午 10:50 
well, i just found out that no matter how much i set the value for ''traffic light timer'', it will be the same timing if the ''traffic light wait'' isn't touched. this had a good chance of being a masterpiece...
Stid  [作者] 2017 年 8 月 23 日 下午 1:09 
Use lua scripting for more customization.
V I P E R S N E K 2017 年 8 月 23 日 下午 12:26 
can you get these to sync up if you have more than one?
JakeD24 2016 年 12 月 10 日 上午 12:48 
the lights breack after a long time
Stid  [作者] 2016 年 4 月 10 日 上午 1:13 
Use a lua and change TimeWait variable for you skin.
Item 9 2016 年 4 月 9 日 下午 9:39 
How do you make red light stay on longer?
Stid  [作者] 2016 年 3 月 9 日 上午 6:47 
ok, thanks