模拟城市中文网

 找回密码
 入住
搜索
查看: 5509|回复: 7

[新闻] Under the Hood of SimCity's Traffic.....那个英文好的帮忙翻译一下

 关闭 [复制链接]
头像被屏蔽
发表于 2013-3-25 14:01 | 显示全部楼层 |阅读模式
本帖最后由 紅塵市長 于 2013-12-25 15:52 编辑

Under the Hood of SimCity's Traffic.....那个英文好的帮忙翻译一下
译文:
http://www.simcity.cn/forum.php?mod=redirect&goto=findpost&ptid=117303&pid=1756410&fromuid=501441

http://www.simcity.com/en_US/blog/article/under-the-hood-of-simcitys-traffic


Mar 23, 2013
Software Engineer Alexander Harkness

Hello, I’m Alexander Harkness, and I’m a Software Engineer working in the transportation team of SimCity. I’ve primarily been working on implementing the behaviors for the vehicles, rail, boats, and helicopters during my amazing time here at Maxis. I wanted to take some time out of my usual duties to explain to you all how the traffic system works and how you can make the most of it.
Vehicle Behaviors
Basic Information
Every vehicle in the game has a basic set of performance characteristics such as top speed, acceleration, and deceleration. The values assigned to each vehicle vary on the type of vehicle (scooter, car, and truck), the wealth value of the vehicle, or where the weight has changed after a delivery is made.
Lane Changing
Vehicles will always try and get into the correct lane for the next turn they are required to make. So when turning right, they will attempt to get into the right lane. And when turning left, they will attempt to be in the left lane. Vehicles travelling straight through an intersection can be in any lane. Vehicles will also overtake vehicles in front using the lane to the left if the vehicle in front is travelling slower and there is space for them to do so. Emergency vehicles can undertake and overtake using any available lane. When the vehicle is expecting to enter a building on the current section of road, the vehicle will always try and be in the right most lanes, they will only move out of that lane if there is an obstruction such as a stationary fire truck.
Limitations
We tend to be quite strict in cases such as U-turning where we found very early on that letting vehicles U-turn wherever they thought was best caused so many traffic problems that we had to restrict them to U-turns at intersections only. Other limitations imposed are vehicles not being allowed to cross the median to enter buildings on avenues and emergency/service vehicles stopping outside of building only. This means vehicles must travel much farther when their destination is on the opposite side of the road, since they will need to U-turn at the next available intersection. Of course, from this you can see that it is not always wise to immediately upgrade all your roads to avenues in an attempt to solve congestion.
Emergency Vehicles
Driving to emergency
All emergency vehicles have the ability to change the traffic lights in their path to green. This is so by the time they reach those lights, they should have changed, and any traffic at the set of lights should have started to flow. During periods of heavy traffic, it could be that there is some gridlock where traffic is not moving, even after the emergency vehicle has changed the light to green. In this case, it will remove the lock on the green light, as this can potentially be the cause of the gridlock.
Stopping outside buildings
All emergency vehicles will stop outside their destination while they are attending to the situation at hand. This causes a temporary blockage on the lane immediately outside the building and can last a variable amount of time depending on the emergency. On two lane roads, this causes an issue with traffic being permanently blocked until the emergency is over, however, on four or six lane roads, the vehicles should flow around unless they are interested in entering the building that the emergency is at.
New additions
In a recent update, we added some new functionality that prioritizes emergency vehicles over all other vehicles. The first change was to ensure that these vehicles could exit their garages and get onto the road as quickly as possible and deal with the emergency. This means that they will immediately reserve a spot on the lane outside the garage and drive straight onto it. Previously they would have to wait for a spot to open up which may never have happened during times of congestion. The second change was allowing them to use any lane on the road regardless of whether they were required to turn left/right at the next intersection, which as previously mentioned, would normally force the vehicle to attempt to get into that lane.
Intersections
All way stops
At these types of intersections, vehicles obey the rules of first to arrive is the first to move. This rule is broken for two different scenarios. The first is where we can improve traffic flow by allowing multiple vehicles that will not cross paths to move at the same time. And the second is where the vehicle is unable to move because the road is blocked. In the latter case, the next vehicle to arrive is promoted to the top of the queue and the blocked vehicle is moved to the back.
Traffic lights
Traffic lights can be used to improve the flow of traffic at intersections dramatically over all way stops. During testing, it was seen that there was a 4-5x improvement in the amount of traffic travelling through the intersection. Traffic lights also have knowledge of traffic whether it is vehicles or pedestrians that are waiting at the lights. In the case where there is zero traffic waiting or approaching, the intersection light will switch to allow traffic from the opposite set of lights to proceed. The traffic light will then stay green in that direction until traffic from the crossing direction approaches/arrives at the intersection. When there is traffic from both crossing directions, the lights work on a timer countdown. This countdown is differs in length depending on the combination of the joining roads at the intersection, but the length the light stays green is longer the wider and higher density the road is.
Side street stops
This setup can be incredibly useful to create corridors through the city where traffic can flow freely without interruption from stop signs or traffic lights (vehicles will only stop to let pedestrians cross). These can be created by using any four lane road or greater in combination with a two lane street or dirt road as the side roads.
Creating intersections
To achieve better flow through the city it is much better to use T-Junctions than four way intersections. This is simply because there will be fewer vehicles trying to cross the path of oncoming traffic for which they have to wait until it passed. You may have noticed that often queues will form where traffic is waiting to turn left across the path of traffic. Intersections that are too close together are another thing to avoid. This is because the flow of traffic during the green phase of one of the intersections towards the next intersection will be very small due to the area available for the vehicles to wait and most of the green phase will have been wasted as no cars are moving.
Routing
Overview
To understand how the routing system works, I’ll talk a bit about how roads are created, how routing propagates values through it, and how you can influence these values.
Roads
Roads are constructed from many paths and paths are constructed from one or more segments. A path is the road between two intersections. Each path is made from segments and the number of these can vary depending on the curvature of the path or the terrain the path is crossing. So flat areas paths will tend to be only one single segment.

Assigning weights
Where there is any capacity on a segment, we assign a value to that segment based on the capacity. In this example, the work place has ten open jobs so we assign a base value of ten at each point on the ends of segment four. This value then propagates out through the network adding on the length of the segment that the vehicle will have to traverse. So in this case we say that segment two and three are fifty meters in length, and segment one is two hundred meters long.

In addition to this, we also add on congestion values that are calculated continuously. These values are only applied to the network when they reach certain thresholds that we have set at 25%, 50%, and 75% of road capacity. We do this to avoid the overhead in continually updating the complete network of paths. You have to know that we have many hundreds of these networks to update to cover the many different destinations vehicles have. As an example, say that segment 2 becomes 50% congested. We would then take the length of that segment and multiply it by a set amount, say 10 times. This would mean that the values would then become 10, 10, 510, 560 and 760.
Influencing the values
Let us look at the scenario below which has been seen in a video posted on YouTube. I marked each of the segments and the values at each end of the segment as before. With this layout, the vehicles will all initially exit their houses and use segments 5, 6, 2, and 1 to get to their jobs. As segment 6 becomes congested due to the traffic, the additional congestion weight will be applied to influence the value so that vehicles will route around using segments 4 and 3. However, in this case, because there is only one segment on the path where segment 6 is, and the value at the end is shared between segment 2, 3, and 6, the value will not actually change from its current value of 60 since the distance from segment 3 to segment 2 is still only an additional 50 meters and during the propagation the lowest value is always applied.

You can however influence the network by forcing a path to split into multiple segments. The cheapest way to do this is by drawing a dirt road midway along the path and then bulldozing this path. This then changes how the values are applied and would make the vehicles take the alternative longer but less congested route.

Obviously, this is not an ideal solution for you as a player since you can’t see how the paths are split up, so we are of course working hard at improving the routing.
Final Tips
Mass Transit
Traffic should generally be at an absolute minimum around an hour before the shift changes start at 6am and 6pm. When I start to see the congestion building up and lasting closer to this point I start to plan ahead and think about my mass transit options. Remember, when picking stops, the green overlays show you how far Sims are willing to walk to the bus stop, which can be a handy guide to helping space them out. This is important when strategically placing bus stops. Since busses don’t follow set routes, it’s a good idea to place them closely spaced in lines on the same side of the road to encourage the busses to go to the next stop in the line. This way, they won’t have to make a U-turn to reach the next stop. In addition to busses, you can also upgrade your avenues to allow for street cars. Street cars are always my preference as it can’t get stuck in traffic jams like the buses can, however don’t go crazy with lots of avenues as this can cause extra traffic itself as I mentioned before. Plan out a route that will cover your highest density population areas and places of work then place rail stops that will allow those Sims to get out of their car and walk to the nearest stop instead.
Thanks for listening everyone. I really hope these tips help you out in designing your perfect city and getting that traffic flowing. Just remember, avenues won’t solve all your traffic woes. And look out for those telltale signs your road network can no longer cope with current volume of vehicles.

发表于 2013-3-25 15:37 | 显示全部楼层
在原帖看完了。乍一看没问题,仔细想想国内网游在此方面的的造诣,我只能说:大家挽尊。
回复 支持 反对

使用道具 举报

发表于 2013-3-26 03:20 | 显示全部楼层
现在正在翻译
回复 支持 反对

使用道具 举报

发表于 2013-3-26 04:00 | 显示全部楼层

Under the Hood of SimCity's Traffic 翻译

原文可以在官网的Blog里看见
原文有Vehicle Behaviors ,Emergency Vehicle ,Intersections ,Routing , FinalTips几个部分,但是我只翻译Emergency Vehicle Intersections,也就是紧急车辆和交叉路口。


Emergency Vehicle 紧急车辆
Driving to emergency
开去紧急事件地点

All emergency vehicles have the ability tochange the traffic lights in their path to green. This is so by the time theyreach those lights, they should have changed, and any traffic at the set oflights should have started to flow. During periods of heavy traffic, it couldbe that there is some gridlock where traffic is not moving, even after theemergency vehicle has changed the light to green. In this case, it will removethe lock on the green light, as this can potentially be the cause of thegridlock.

所有的紧急车辆都有改变红绿灯的能力。在他们经过红绿灯时,就会变成绿灯,使前方的交通得以缓解。在一些交通流量比较大的情况下,绿灯反而可能导致堵塞。在这种情况下,它会自动取消那个导致堵塞路段的绿灯锁定。



Stopping outside buildings
停在事故地点
All emergency vehicles will stop outsidetheir destination while they are attending to the situation at hand. Thiscauses a temporary blockage on the lane immediately outside the building andcan last a variable amount of time depending on the emergency. On two laneroads, this causes an issue with traffic being permanently blocked until theemergency is over, however, on four or six lane roads, the vehicles should flowaround unless they are interested in entering the building that the emergencyis at.
所有的紧急车辆都会停在事故地点的旁边,然后他们去处理事故。在这时候会导致一个交通堵塞,直到事故处理完毕。在双车道的公路上,会导致严重的交通堵塞。而四车道或六车道,后面的车就可以绕过去。


New additions

更新
In a recent update, we added some newfunctionality that prioritizes emergency vehicles over all other vehicles. Thefirst change was to ensure that these vehicles could exit their garages and getonto the road as quickly as possible and deal with the emergency. This meansthat they will immediately reserve a spot on the lane outside the garage anddrive straight onto it. Previously they would have to wait for a spot to open upwhich may never have happened during times of congestion. The second change wasallowing them to use any lane on the road regardless of whether they wererequired to turn left/right at the next intersection, which as previouslymentioned, would normally force the vehicle to attempt to get into that lane.
在最近的更新中,我们(指Maxis)给紧急车辆增加了一些新功能。第一个改变,紧急车辆可以更容易的从车库里出去。他们会直接从车库里出去,而不是像以前要等外面的车经过后才出去。第二个改变,紧急车辆可以从任何车道转弯,例如从左转道上右转。


Intersections 交叉路口
All way stops

四方向stop
At these types of intersections, vehiclesobey the rules of first to arrive is the first to move. This rule is broken fortwo different scenarios. The first is where we can improve traffic flow byallowing multiple vehicles that will not cross paths to move at the same time.And the second is where the vehicle is unable to move because the road isblocked. In the latter case, the next vehicle to arrive is promoted to the topof the queue and the blocked vehicle is moved to the back.
这种类型的所有路口,车辆都遵守先到先走的原则。这个规则可以分为两种情况。在平时,绝对不会出现多辆车同时走的情况。在堵车时,如果第一辆车想走的路线堵住了,他就会自动掉头,让给第二辆车走。


Traffic lights
交通灯
Traffic lights can be used to improve theflow of traffic at intersections dramatically over all way stops. Duringtesting, it was seen that there was a 4-5x improvement in the amount of traffictravelling through the intersection. Traffic lights also have knowledge oftraffic whether it is vehicles or pedestrians that are waiting at the lights.In the case where there is zero traffic waiting or approaching, the intersectionlight will switch to allow traffic from the opposite set of lights to proceed.The traffic light will then stay green in that direction until traffic from thecrossing direction approaches/arrives at the intersection. When there istraffic from both crossing directions, the lights work on a timer countdown.This countdown is differs in length depending on the combination of the joiningroads at the intersection, but the length the light stays green is longer thewider and higher density the road is.
交通灯可以用来改进All way stops的效率,它可以把车辆通过十字路口的效率提高4-5倍。这是一个非常智能的交通灯系统,可以根据流量改变。如果对面没有任何车等待或接近,交通灯就会一直给绿灯直到对面有车出现。如果两边都有车,交通灯就会跟现实一样开始倒计时。倒计时的时间跟道路的类型有关系,红绿灯会给更宽更高密度的道路更多绿灯时间。


Side street stops
辅道
This setup can be incredibly useful tocreate corridors through the city where traffic can flow freely withoutinterruption from stop signs or traffic lights (vehicles will only stop to letpedestrians cross). These can be created by using any four lane road or greaterin combination with a two lane street or dirt road as the side roads.
使用这个方法可以使车辆非常自由的穿过城市,不用因为红绿灯或stop牌停下。可以使用两车道或泥路作为四车道或更宽的道路的辅路。


Creating intersections
设计路口
To achieve better flow through the city itis much better to use T-Junctions than four way intersections. This is simplybecause there will be fewer vehicles trying to cross the path of oncomingtraffic for which they have to wait until it passed. You may have noticed thatoften queues will form where traffic is waiting to turn left across the path oftraffic. Intersections that are too close together are another thing to avoid.This is because the flow of traffic during the green phase of one of theintersections towards the next intersection will be very small due to the areaavailable for the vehicles to wait and most of the green phase will have beenwasted as no cars are moving.
使用T型路口的效率比十字路口高。因为车辆经常会被来往的车辆挡住,你可以留意到有许多车辆在等待左转。两个红绿灯靠的太近也是要阻止的,当车辆从一个红绿灯开往下一个很近的红绿灯时,只有很小一块道路可以等待。这会导致很多绿灯因为没有车辆通过而浪费。


因为没有使用电脑翻译,所以很多地方加入了自己的理解并非逐字翻译。由于还在等待Mac版,所以有错误的地方,希望指出和谅解。可能会感觉中文翻译很短,但是要点都翻译到了。


[ 本帖最后由 EdwGx 于 2013-3-26 04:10 编辑 ]

评分

参与人数 1威望 +1 模拟币 +60 收起 理由
zhseven + 1 + 60 热心助人

查看全部评分

回复 支持 反对

使用道具 举报

发表于 2013-3-26 04:37 | 显示全部楼层
什么是STOP牌(Stop sign)?
你可能从来都没有在中国看见过,但是在欧美国家STOP牌到处都是。Stop牌一般是放在道路之间的交汇处,有字和图标的方向是朝着低等级道路的方向,高等级道路(也就是主干道)完全可以无视掉。如果是同等级道路交汇,一般四个方向都会有Stop牌,这时遵循先到先动的原则。无论在任何情况下,车辆都必须在Stop牌前停3秒,这3秒就是给驾驶员有充分的时间观察周围的情况。如果不停的话,就会有人举报你,然后就是罚款和扣分。这样的规则可以带来的主要好处是,你可以不用担心一辆车突然从旁边的小道里冲出来。


[ 本帖最后由 EdwGx 于 2013-3-26 04:40 编辑 ]
回复 支持 反对

使用道具 举报

发表于 2013-3-26 09:02 | 显示全部楼层
感觉在吹牛皮啊
没觉得交通灯系统智能在哪里
楼主不是机翻,版主给加分呗
回复 支持 反对

使用道具 举报

发表于 2013-3-26 09:41 | 显示全部楼层
游戏里面的感觉没有文章里面写的那么好。
回复 支持 反对

使用道具 举报

发表于 2013-3-26 10:14 | 显示全部楼层
原帖由 EdwGx 于 2013-3-26 04:37 发表
什么是STOP牌(Stop sign)?
你可能从来都没有在中国看见过,但是在欧美国家STOP牌到处都是。Stop牌一般是放在道路之间的交汇处,有字和图标的方向是朝着低等级道路的方向,高等级道路(也就是主干道)完全可以无视掉。如果是同 ...
這東西在香港存在,也是駕駛考試的必考項目之一,其實和讓路牌大同小異,就是必須停車而已,不論有車無車

http://www.td.gov.hk/tc/road_safety/road_users_code/index/chapter_5_for_all_drivers/stop_and_give_way_junctions_/index.html


停車標誌及道路標記──即使大路上並無其他車輛,你也必須在停車綫前停車。等待至車流出現安全的空檔時,才可開車前進。如有行人正在橫過或等候橫過小路,必須讓路。

本帖子中包含更多资源

您需要 登录 才可以下载或查看,没有帐号?入住

x
回复 支持 反对

使用道具 举报

您需要登录后才可以回帖 登录 | 入住

本版积分规则

小黑屋|手机版|模拟城市中文网

GMT+8, 2024-4-25 16:07 , Processed in 0.028338 second(s), 21 queries .

Powered by Discuz! X3.4

© 2001-2017 Comsenz Inc.

快速回复 返回顶部 返回列表