都市天际线吧 关注:244,996贴子:1,831,767

道路编辑器教程

取消只看楼主收藏回复

道路编辑器官方wiki翻译


IP属地:浙江1楼2017-10-20 14:50回复
    The road editor is a tool in Asset Editor used to modify and createroads.
    道路编辑器是一个在资产编辑器中打的新工具,用来修改和创造道路。
    This page is currently work in progress and might be missing someinformation. Please append it with any information, tips, or solutions tocommon problems you think might be relevant, and clarify any bits as you seefit.
    本文是现阶段能进行的工作,可能会有所遗漏。
    General[edit]
    总体
    The road modding tool can be used to customize many of the game’s“net”-objects, including roads, train/tram/monorail tracks, canals, quays etc.Since almost all properties of game’s net-objects can be edited, the amount ofvariables can seem confusing, some of them only make sense in certainsituations, and all configurations aren’t guaranteed to work. Editableproperties are explained here, and you can always refer to how things are setup in the templates. All nets will be referred to as roads here.
    道路编辑工具能被用来自定义任何游戏中的“交通网络”物件,包括道路,轨道,轮船和运河等。因为几乎所有交通网络物件都可以被编辑了,所以其多样性会多到某些道路只能在特定的情况下运行良好,并不能保证完美工作。你可以从示例中了解可编辑物件是如何设置的。所有的交通网络都能参考本文的道路。


    IP属地:浙江2楼2017-10-20 14:51
    回复
      Roads usually consist of 5 elevations. Basic refers to the ground levelelevation, Elevated is the elevated version used when having a few steps ofelevation, Bridge refers to higher elevations, Slope is the part leading fromground level to Tunnel, and Tunnel is the underground version of the road.Every elevation is edited independently and can contain multiple differentmodels used in different situations. You can choose the elevation you want toedit from road editor main panel’s tabs.
      道路资产由5种模式组成。Basic代表地面模式,Elevated是高架模式,Bridge是大桥模式,Slope是隧道口,tunnel是地下模式。
      每一种模式都可以单独编辑,并且能使用不同的模型,以适应不同情况。你能从编辑器主面板调整模式。
      3D models used by these elevations are divided into segments and nodes.Segments are used normally on continuous roads, and nodes are used inintersections, on transitions between different road types, and twisted intothe endings of roads. Segments and nodes also contain conditions on when to usewhich, and multiple models can be used on the same time such as a base segmentfor a tram, the tram tracks, and electric wires going over the tram track. Bothsegment and node models are simply straight road stubs, and the game takes careof bending and matching them. Tunnel elevation usually doesn’t require anyadditional modeling. Segment and node models don’t necessarily have to be justroads, and can be anything that you want to scale and bend along with the road.
      3D模型分为道路的连接段(segment)和节点(nodes)。连接段见于连续道路,而节点可能是与其他道路的连接点,或位于道路终点(也位于连续道路中间)。他们也可能用于当其他轨道(例如电车轨道)重合于道路上方的时候。连接段和节点都只是道路的一部分,游戏会根据链接段的弯曲结合他们。隧道一般不需要模型(才不是呢!)。连接段和节点不一定是道路,也可以是任何其他你想要用道路模式制作的东西
      Lanes contain information about lane’s position, accepted vehicle types,properties such as speed limits, and propping. Lanes don’t necessarily need toallow anything to use them, and can be set up as plain containers for proppingor middle platform etc. Lane props also contain additional properties for aprop and conditions on when the prop is used.
      Lanes包含着车道的信息,包括车道位置,可用车辆类型,限速,方向,和附加的prop.车道不一定需要有车使用,也可以用作prop或者平台或者什么别的。车道prop同样可以包含自定义prop,将于prop启用时自动添到路上


      IP属地:浙江3楼2017-10-20 14:51
      回复
        Modeling[edit]
        建模

        Example screenshot of the basic meshfor Two-Lane road
        Basic地面模式模型

        Example screenshot of the elevated/bridgemesh for Two-Lane Road
        高架模式模型

        Example screenshot of the slope meshfor Two-Lane Road
        入地段模型
        Roads are usually modeled as straight 64 units long and 16-32 units wideroad stubs. Any width and length can be used and set up in Half Width andSegment Length fields in Properties menu, although widths lesser than 8 areknown to cause issues. It’s important to have the model sliced in grid-likelayout and in the middle parallel to it’s length to have free vertices the gamecan move around. Make sure that the mesh is aligned parallel to z-axislength-wise and to center the mesh to scene origin. If your road has pavementmake it 0.3 units high to match built in roads, and set the pavement’s level to0 in y-axis so that the road is slightly sunken.
        道路一般制作64U长,16~32U宽的模型。长宽可以在面板上用Half Width半宽修改,当总宽度小于8m(1U)的时候,可能会产生问题。
        模型在平行于长度方向的中线上,需要与网格对其,并切出模型节点,以保证游戏能自由移动模型。
        保证模型对齐平行于Z轴(宽度轴)和视图原点。
        如果你的道路有人行道,让它比路面高0.3U,并且将它y轴(高度轴)坐标设置为0,这样道路可以轻微下沉(看情况做下沉)


        IP属地:浙江4楼2017-10-20 14:53
        收起回复

          The textures used by roads are
          · diffuse (_d, RGB)
          · normal (_n, RGB)
          · specular (_s, grayscale)
          · alpha (_a, grayscale)
          · pavement map (_p, grayscale)
          · road map (_r, grayscale)
          贴图类型
          漫反射(_d结尾RGB贴图)
          法线贴图(_n结尾,RGP贴图)
          反射贴图(_s,灰阶贴图)
          透明度贴图(_a,灰阶贴图)
          人行道贴图(_p,灰阶贴图)
          道路贴图(_r,灰阶贴图)
          White areas in pavement and road maps are used to automatically generatetexturing that is uniform from road type to another. Diffuse usually onlycontains some road markings and details, and can be blended in to the road andpavement textures by adding some gray to corresponding areas in these mappings.On elevated versions the diffuse is also used for areas such as the bottom ofthe bridge, and on slope the texturing for the tunnel opening. Alpha is usedfor grassy areas when using the Basic shader, and transparency on othershaders. Nodes are usually heavily stretched and bent so avoid using diffusedetails in those and instead use automatic texturing by road and pavement maps.
          人行道和道路贴图的白色区域将自动生成相应的贴图。
          Diffuse漫反射贴图通常只包含道路标识和细节,能通过灰阶贴图的灰色区域混入人行道和道路贴图。
          在高架模式,漫反射贴图还被用来表现桥板底部,在入地段表现隧道口。
          Alpha贴图用来表现草。
          Node节点经常被严重变形,所以避免使用漫反射贴图,而是自动产生道路或人行道贴图
          As a the mesh is stretched the UV-mappings “scroll” along the V-axis toavoid stretching the texels. Magenta vertex color (255, 0, 255) can be used todisable stretching the UV-mapping for bits where this is undesirable, forinstance in fence posts. It’s usually a good idea to split the textureshorizontally and add statically mapped UV-islands on their own side. Note that.obj-files don’t store vertex coloring, so you'll have to export your model as.fbx to use any vertex colors.
          模型的贴图被拉神时,uv贴图沿着V轴能卷展能避免贴图拉伸。
          磁性顶点颜色(255,0,255)能被用来禁用所标记顶点内的贴图拉伸。
          一般来说,从水平方向割裂贴图,选择性的在各自方向覆盖上几个uv岛,会是一个好方法。
          注意obj文件不会记录顶点颜色,所以需要保存为fbx格式


          IP属地:浙江5楼2017-10-20 14:56
          回复
            There are four different shaders to choose from. Basic is usually used onground level roads, and can be used to mix terrain textures to the model’spavement mapped area (pavement, gravel, or ruining, set in properties) or alphamapped areas (grass). Shadows are also optimized for ground level.
            有4种不同的覆盖器。Basic基础常用在地面道路,而且可以混合主题贴图。阴影为地表模式进行了优化。
            Rail and Bridge shaders work quite similarly to each other, but can differa bit on their look. Rail always produces gravel and Bridge produces pavementon pavement-mapped areas.
            Rail轨道和Bridge桥梁覆盖器很相似,但外观有所区别。轨道总是产生泥土,而桥梁总是产生人行道。
            The wire shader doesn’t use any textures, and models using it will sway inthe wind. The amount of sway can be set per vertex on the blue channel of thevertex color (0 for no sway, 255 for full), and the phase of the sway can be controlledwith the red channel.
            Wire覆盖器不使用任何纹理,使用它的模型将随风飘动。飘动量能被蓝色通道的顶点数量控制,方向能被红色通道控制。
            Automatic LOD generation is not currently supported for roads (1.9.0). Usecustom LOD models.
            自动LOD尚不支持,必须使用自定义LOD模型


            IP属地:浙江6楼2017-10-20 14:56
            回复
              Editor[edit]
              Here are listed all the different editable fields of the roads.
              编辑器
              这是所有可编辑项列表


              IP属地:浙江7楼2017-10-20 14:56
              回复
                Road Properties[edit]
                · Half Width: half the width of theroad. Having different width on the road’s base mesh can cause clipping orz-fighting around the road. Used to smoothly match road’s sides with other roadtypes and many other things.
                半宽:道路宽度的一半。与道路模型不一致可能导致蓝色空洞。用来微调道路宽度,用以对接其他道路类型或者其他东西
                · Pavement Width: width of thepavement of the road. Used to smoothly match pavements between different roadtypes. Pavement should be 0.3 units high in the mesh to match built in roads.
                人行道宽度:道路中人行道的宽度。用来微调不同道路的人行道宽度。有0.3Unit单位高度,来适配自带道路。
                · Segment Length: length of a segment,usually 64. Wrong sized mesh can result in clipping or z-fighting between thesegment meshes when they are tiled.
                连接段长度:连接段的长度,默认64。错误的大小可能导致蓝色空洞
                · Min Height / Max Height: thevertical bounds of the road. Used for collision detection for water when BlockWater is checked, and to prevent building other nets too low above the road.
                最小/最大高度:垂直方向的可接受高度。当选择挡住水体时可用来做水碰撞,并房子建筑或者其他东西距离道路太低。
                · Max Slope: maximum angle of a slopethat the road can be built on.
                最大坡度:修建道路时能接受的最大坡度
                · Max Build Angle: Maximum angle atwhich the road can connect to another.
                最大修建角度:当链接其他道路时的最大可接受角度
                · Max Turn Angle: Maximum angle of theroad until a node is used instead of segment. Can be overridden by checkingEnable Bending Nodes.
                最大转角:当产生node节点时的最大可接受角度
                · Min Corner Offset: amount to offset(or “smoothen”) corners towards the inside of the turn. Large numbers (> 40)can mess up collision detection and make the road hard to build.
                最小转角偏移量:当产生转角时向弯内最小的偏移量。大的数值(>40)能破坏碰撞检测,导致道路难以修建
                · Build Height: vertical offset of theroad from base line
                修建高度:垂直方向高于地基的默认偏移量
                · Surface Level: level of the road’ssurface. Used by vehicles and citizens to move at the correct height.Individual lanes can also be offset from this with their property VerticalOffset.
                表面高度:表面的高度,让车辆与行人位于正确的高度。每个车道可以从它的面板分别设置。
                · Create Pavement / Gravel / Ruining:Which terrain texture is used on pavement-mapped areas. Used by Basic shaderwhen Lower Terrain is unchecked. Bridge shader always generates pavement andRail shader always generates gravel.
                创造人行道,泥土:选择哪一种主题纹理将被在人行道纹理(灰阶贴图)中白色区域生成。当Lower Terrain降低地表选项被选择时,会使用basic覆盖器。桥梁覆盖器总生成人行道而轨道覆盖器总生成泥土。


                IP属地:浙江8楼2017-10-20 14:57
                收起回复
                  Lane Properties[edit]
                  车道特性面板
                  · Position: horizontal position of thelane along the width of the road, from the middle point of the road.
                  位置:车道水平位置。从道路中间开始算
                  · Width: width of the lane.
                  宽度:车道的宽度
                  · Vertical Offset: vertical positionof the lane from the road’s Surface Level.
                  高度偏移量:从地表开始的偏移量
                  · Stop Offset: position where avehicle can pull up to stop, calculated from lane’s Position.
                  车站偏移量:车辆从车道靠近进入车站的偏移量
                  · Speed Limit: for vehicles usuallyfrom 0.8 (two lane road) to 2 (highway). Usually 0.25 for pedestrian lanes.
                  速度限制。一般从0.8(40kmh)到2(100kmh),人行道一般0.25(12.5,推荐改到0.1约5km/h,更贴近现实)。
                  · Direction: forward for right handlanes, backward for left. Will be automatically flipped if using left-handtraffic.
                  方向:右行规则的道路方向,左行则相反,自动切换
                  ====================================================================
                  · Lane Type: General type of the road.Leave to None if the lane isn’t meant to be used, for example if you want thelane simply to be container for props or to represent the middle platform suchas in 4 lane roads. Any types that aren’t listed here are meant for internaluse and might not work in custom roads.
                  车道类型:道路的总体类型。如果不准备用来行车,留空,比如只是作为prop或者平台的容器。任何未在列表上的类型代表内部方式,尚不能用在自定义道路
                  · Vehicle: lane is used by vehicles.You can choose allowed vehicle types in Vehicle Types field.
                  车辆类型:车道是行车的。可以在Vehicle Types车辆类型中选择行车范围
                  · Pedestrian: allow only pedestrians
                  人行类型:只允许行人通过。
                  · Parking: lane is used for parking
                  停车类型:这条道用来停车
                  · CargoVehicle: allow vehicles thatmove cargo
                  货轮类型
                  · TransportVehicle: allow publictransport
                  公交类型
                  · EvacuationTransport: allowevacuation vehicles
                  应急疏散.
                  ===============================================================
                  · Vehicle Type: allowed vehicle typesif Lane Type is set to Vehicle.
                  车辆类型:可允许的车辆类型
                  · Stop Type: Vehicle types that canuse this lane for stopping.
                  站点类型:可以停站的车辆类型
                  · Allow Connect: –
                  · Use Terrain Height: overridevertical offset and surface level with terrain height
                  使用地表高度:覆盖垂直偏移量到地表高度
                  · Center Platform: is the lane used ascenter platform
                  中部平台:该车道用作中部平台
                  · Elevated: –


                  IP属地:浙江10楼2017-10-20 14:59
                  回复
                    Lane Prop Properties[edit]
                    车道prop属性
                    · Flags: conditions required for theprop to be used. Refer to templates.
                    折叠:当使用prop时可选。参考示例
                    · Color Mode: –
                    · Position: prop’s position from thelane’s middle point
                    位置:prop从车道中点开始的位置
                    · Angle: angle of the prop
                    角度:prop旋转的角度
                    · Segment Offset: –
                    · Repeat Distance: how often to repeatthe prop
                    重复距离:多远一个prop
                    · Min Length: –
                    · Corner Angle: –
                    · Probability: Probability of the propshowing
                    概率:出现几率


                    IP属地:浙江11楼2017-10-20 14:59
                    回复
                      Segment Properties[edit]
                      连接段属性
                      · Backward/Forward Required/Forbidden:conditions required for this segment model to be rendered. For example if youdon’t want this segment to be rendered when the next segment of placed road iscollapsed, check the Collapsed flag in Forward Forbidden. Check how templatesuse these to get general idea of how they work.
                      前后判断:显示此段模型需要的条件。例如,如果您不希望在下一段放置的道路崩溃时呈现此段,请选择前面禁止的折叠标志。参考模板如何使用这些来了解它们是如何工作的。
                      · Disable Bend Nodes: Check to disablethe segment from being used in sharp angles (Max Turn Angle in road’sProperties menu)
                      禁用弯曲节点:选中以禁止锐角情况显示该路段。
                      · Road Color: color applied to roadmapped areas
                      道路颜色:应用的颜色
                      · Shader: shader the segment modeluses
                      覆盖器:选择覆盖器类型
                      · Model: click to import model
                      ====【模型:导入模型】====


                      IP属地:浙江13楼2017-10-20 15:00
                      回复
                        Node Properties[edit]
                        节点属性
                        · Flags: conditions required for thisnode model to be shown. Refer to templates.
                        折叠:显示该节点模型的情况。参考示例
                        · Connect Group: which connect groupsto use this node with
                        链接组:选择哪种类型可以被链接
                        · Direct Connect: –


                        IP属地:浙江14楼2017-10-20 15:00
                        回复
                          这次的道路编辑器更新可以说是非常给力,完全超出了我们的预期。希望大家也能一起来做道路!
                          本教程后续可能还有更新


                          IP属地:浙江15楼2017-10-20 15:01
                          收起回复
                            现在想到能做的事情:
                            标准化车道:连接城市道路和高速再也没有标准差距
                            复杂的道路样式,道路系统
                            更好的高架:更小的人行道,更薄的桥板,更真实的栏杆
                            更好的隧道:隧道口优化,地下贴图
                            更好的河堤:自定义曲线河堤!不再是光秃秃的水泥堤,也不用担心河堤资产的曲线问题
                            不得不说这次co社**了


                            IP属地:浙江30楼2017-10-20 17:42
                            收起回复
                              稍微顶一下,有些人还在问呢


                              IP属地:浙江来自Android客户端39楼2017-10-23 01:44
                              回复