env_fade
< Zh
Jump to navigation
Jump to search

env_fade
是一个点实体 ,可在所有的 起源 游戏中使用。 根据颜色来渐变。 添加Duration 和 Hold Time 一起使用才能使得实体有效果。
待完善: This template is currently using deprecated suf or {{Lang}}-based translations. Please use the main {{Code class}} instead, which uses {{Autolang}}.
在源代码中,它由 class
CEnvFade
代表,定义于 EnvFade.cpp
。
ConVars/指令
控制台变量/命令 | 参数或默认值 | 描述符 | 效果 |
---|---|---|---|
fadein | 浮点型 整数型 整数型 整数型 0 | 时间 (秒), 红, 绿, 蓝, [待完善] | 使屏幕淡入黑 (或者指定颜色)。 待完善: 为什么需要最后一个数字? |
fadeout | 浮点型 整数型 整数型 整数型 0 | 时间 (秒), 红, 绿, 蓝, [待完善] | 使屏幕淡出黑色 (或者指定颜色)。 待完善: 为什么需要最后一个数字? |
标签/Flags
- 1: Fade From - 使屏幕由指定颜色淡出而不是淡入。
- 2: Modulate - 使用衰减混合实现淡入淡出. 正常的淡入淡出会在屏幕和颜色渐变的时候增加一个加权混合。会衰减RGB通道。 例如, 一个颜色为
0 255 0
会使红蓝通道静音,并创建一个绿色夜视仪效果。 - 4: Triggering player only 不存在于FGD! - 只会影响!activator触发者.
!activator
应该是通过一个trigger 实体获取的。如果不指定会影响所有人。 - 8: Stay Out - 淡入淡出会一直存在除非被另一个效果禁用。
键值
- Duration (seconds) (duration) <字符串 >
- 淡入淡出持续时间。
- Hold Fade (seconds) (holdtime) <字符串 >
- 保持淡入淡出的状态的时间。
- Fade Alpha (renderamt) <整数 >
- 透明的,0为完全透明。
- Fade Color (R G B) (rendercolor) <color255 >
- 颜色。
- Reverse Fade Duration (seconds) (ReverseFadeDuration) <浮点型 > (存在于自
以来)
- 反向淡入淡出时间。

This article has been marked as a candidate for speedy deletion for the following reason:
Administrators / Moderators - Remember to check if anything links here and the page history before deleting.
The redirect page got deleted, therefore this page should too.
If you object to this decision, then please discuss why here (If you make a discussion section also create this redirect page). If this page doesn't meet the criteria for speedy deletion, then please remove this notice, but do not remove it from pages that you have created yourselfAdministrators / Moderators - Remember to check if anything links here and the page history before deleting.
输入
- Fade
- 开始屏幕淡入淡出。
- Alpha 不存在于FGD!
- 修改 Fade Alpha.
- Color 不存在于FGD!
- 修改 Fade Color.
Base:
- AddContext <字符串 >
- 添加到实体的 Response Contexts/响应上下文列表。格式是
<key>:<value>
。
展开 语法:
- ClearContext
- 从此实体的列表中删除所有上下文。
- ClearParent
- 从移动层次结构中删除该实体,使其可以自由移动。
- FireUser1 to FireUser4
- 触发相应的
OnUser
输出;详见 User Inputs and Outputs。
- Kill
- 从这个世界中删除此实体。
- KillHierarchy
- 功能类似
Kill
,尽管此实体与其父实体都被删除了,但比Kill
快一点。
- RemoveContext
- 从实体列表删除一个上下文。名字应与现有上下文进行匹配。
- SetParent <字符串 >
- 跟随此实体移动,详见 实体层级(依赖关系)。
- SetParentAttachmentMaintainOffset <字符串 >
- 同上,但没有传送。在接收到输入时,实体保持其相对于附件的位置。
- DispatchResponse <字符串 > 不存在于FGD!
- 向实体发送一个上下文。 详见 Response
和 Concept
.
- DispatchEffect <字符串 > (被移除于
以来) 不存在于FGD!
- 在实体的原点坐标设置一个特定效果;参见 List of Client Effects
。自从
求生之路后由粒子系统取代。
- RunScriptCode <字符串 > (存在于自
以来)
- 在接收输入的实体范围内执行一串 VScript 源代码。通过控制台触发时可能需要字符串引用。
修复:使用文本编辑器手动删除带有字符串的参数。
- SetLocalOrigin <coordinates > (存在于自
以来) 不存在于FGD!
- 将此实体设置到地图中的某个位置。如果此实体是某实体父级,那么它的子级也会随着移动。
Outputs
- OnBeginFade
- 当淡入淡出开始的时候触发。
Base/基础:
- OnUser1 to OnUser4
- 这些输出将分别响应于
FireUser1
到FireUser4
输入。 详见 User Inputs and Outputs。 - OnKilled (仅存在于
之中)
- 当实体被Kill输入时响应此输出。