生还者模式(L4D)

From Valve Developer Community
< Zh
Revision as of 06:53, 15 May 2021 by 1416006136 (talk | contribs)
Jump to navigation Jump to search

Template:Otherlang2

本简体中文界面由 大康 翻译。此页面正在翻译中……

本文包含有关为 Left 4 Dead 创建生存模式战役的基本说明。

开始生还者模式

生还回合从触发任何形式的恐慌事件开始。
任何能够告诉导演强迫发生恐慌事件的实体都可以工作。例如 func_buttonfunc_button_timedtrigger_finaletrigger_onceprop_car_alarm 或自动点唱机上的那首歌曲。
This is set up in the same method as starting a finale or crescendo event.设置方法与开始大结局或渐强事件的方法相同。

导航

所有生存模式地图都依赖于导航网格物体上的 BATTLEFIELD 或 FINALE 属性来定义生还者模式的游玩空间。 在Nav 编辑模式下,使用 BATTLEFIELD 或 FINALE 标记将用于生还者模式空间的空间。同样,BATTLESTATION 属性可用于为生还者机器人定义良好的保留点,然后,幸存者将更喜欢坚持该区域。设置方法与结局或渐强事件相同。 另外,使用 PLAYER_START 属性标记玩家开始的区域。

对于纯生存地图,可以通过用 FINALE 和 BATTLEFIELD 标记所有区域,然后从区域中删除 FINALE 属性以来控制感染者可以在哪些区域生成。未标记 FINALE 属性的导航将无法生成感染者。请注意,这将中断其他游戏模式的导航。
进入 Nav 编辑模式 并使用控制台命令“nav_select_radius 1000000000”,然后再输入“mark battlefield”和“mark finale”,就可以开始标记整个网格。

info_survivor_position

生还者出生在 info_survivor_position 实体。
不幸的是,终局地图在接近逃生车辆时使用同一实体将幸存者“传送”出去。如果您的生存地图也是战役的结局,或者您的地图将 info_survivor_position 用于生存衍生点以外的任何内容,则需要删除这些生存点。否则,玩家可能会在错误的位置生成。
使用输出,通过 Info_gamemode 实体删除多余的 info_survivor position 实体:

  My Output Target Entity Target Input Parameter Delay Only Once
Io11.png OnSurival info_survivor_position used by finale Kill   0.00 No

物品

在L4D中,无论其他模式所允许的正常密度如何,地图中所有放置的物品都会以生存模式生成。 如果您想更改物品放置或编号,可以使用 info_gamemode 生成或杀死物品。

在L4D2中,所有物品生成都以生存模式被移除。
为了生成物品,您必须给每个预期的生存物品取一个名字。 您可以给所有这些物品起相同的名字,以使其变得更容易。
添加一个 point_template 实体,为其指定一个唯一名称,该名称在其“Template”行中列出所有生存物品名称。
添加一个 info_gamemode 实体,并添加以下输出:

  My Output Target Entity Target Input Parameter Delay Only Once
Io11.png OnSurvivalPostIO Point_template ForceSpawn   0.00 No

Add a info_gamemode entity with the output "OnSurvivalPostIO - Point_template - ForceSpawn". Using "OnSurvival" instead of "OnSurvivalPostIO" will cause ammo and ammo upgrade spawnpoints not to be spawned.
Director controlled entities such as weapon_spawn and weapon_item_spawn do not work.

info_gamemode - other uses

Maps are able to load different entities, depending on which gamemode the map is run in. As mentioned in the previous section, survival gamemodes in L4D2 require a info_gamemode and point_template to spawn any items in survival gamemode at all.
The same two entities can be used to load func_brush walls, clip brushes, prop_dynamic, items, or any other sort of entity into your map for survival gamemodes. Like adding barricade props to stop players from reaching the end map saferoom.
Alternatively, you could use info_gamemode along with a logic_relay to delete items you do not wish to have in survival, like Alarm cars which when shot would start the survival round prematurely.

Mission file and testing

Before you can test your map in survival mode, you must add your map to the mission files "survival" mode section.

Example:

"modes"
{
 	"survival"
 	{
 		"1"
 		{
 		"Map" "mymap"
 		"DisplayName" "My survival Map"
 		"Image" "maps/preview_01"	
 		}
 	}
}

The map can be loaded into survival either through the main menu, or using the console via the Command "map mapname_here survival". The latter allows you to use sv_cheats 1 while on survival mode.

See also