三小白角钢

角钢
分享不同类型角钢的相关知识
三好角钢-国内优秀角钢生产厂家与产品分享

钢铁雄心4开发日志 | 6/12 技术向总结其二钢铁雄心4开发日志 | 12/11 情报系统

更新时间:2021-10-14 15:31:13点击:

牧游社 牧有汉化翻译

 

牧游社 牧有汉化翻译

HOI4 Dev Diary – Intel

podcat, Oberkommando HOI4

钢铁雄心4开发日志 | 6/12 技术向总结其二钢铁雄心4开发日志 | 12/11 情报系统(图1)

Hi everyone! Next to last dev diary before christmas, and today we are going to talk about intel. We have been talking about ways to get intel a bit in previous diaries, like code cracking, scout planes and spies but not really talked about the system as a whole. So lets get to it!

 

HOI4 Dev Diary - Tech bugaloo II – Dragonslaying

大家吼哇!这是圣诞节前倒数第二篇的开发日志,今天我们要聊的是情报Intel。在以往的日志中我们已经讨论过一些获取情报的方法了,比如破译密码、侦察机和间谍,但并没有认真地讲解过整个情报系统。所以让我们开始吧!

podcat, Oberkommando HOI4

 

Andy Gainey, Corporal

Before intel was based essentially on comparing two nations crypto tech levels and it was a flat value covering everything. To make this more interesting we are splitting it into 4 separate values: Civilian/Industry Intel, Army Intel, Navy Intel, Air Intel. These affect what you can see in our new intel ledger, that replaces the little intel bit in the diplomacy interface from before for people with La Resistance:

之前的情报系统基本上是在比较两个国家之间的加密科技水平,用单一的数值代表了全部内容。为了使它变得更有趣,我们将它分成4个不同的数值:民用/工业情报、陆军情报、海军情报、空军情报。你在新的情报统计表格中能看到的内容也就因此而受到影响,对于拥有抵抗运动La Resistance的玩家来说,它们取代了以往只在外交界面中出现的少许情报信息:

钢铁雄心4开发日志 | 6/12 技术向总结其二钢铁雄心4开发日志 | 12/11 情报系统(图2)

podcat: Hi guys! Today's Diary is going to be a bit of a short one as I am away at a conference (it has free breakfast! Two most magic words!)

podcat:嗨,大家好!今天的日志会有点短,因为我正离社参加一个会议。(它竟然有免费早餐!这真是两个最魔法的词语了!)

钢铁雄心4开发日志 | 6/12 技术向总结其二钢铁雄心4开发日志 | 12/11 情报系统(图3)

 

Each of the tabs cover each type of intel (here we have civilian/industry selected), and they also come with mapmode information. As an example in the one above we aggregate building values as you zoom out (if you zoom in you see the same by state). This can help you when figuring out where to bomb or where and what kind of sabotage can be most effective.

每个选项卡都包含了一个种类的所有情报(这里我们选择了民用/工业情报),而且数据信息还附带地图模式的信息。用上面的截图举例的话,你们在缩小地图的时候就能看到我们统计了建筑数值(如果放大,则按地区显示相同的信息)。这有助于你找出轰炸的地点,以及进行怎样的破坏活动最为有效。

Last week we celebrated HOI4’s 3 year anniversary and released 1.7 ‘Hydra’ along with Radio Pack and Axis Armor. I hope you enjoyed them.

 

The more intel you have the more information is displayed, we break down the levels in a tooltip per category:

你拥有的情报越多,所显示的信息就越多,我们在各个情报类别的提示框中细分出不同的显示信息等级:

钢铁雄心4开发日志 | 6/12 技术向总结其二钢铁雄心4开发日志 | 12/11 情报系统(图4)

So right now I can see how many army techs have been researched, but not specifically which. That requires 70% but then you can look at their tech tree. If I had 5% more I could see roughly how many of each division template the other nation had. At the moment I can only see that they exist but no real info about what they contain.

所以现在我就可以看到对方已经研究过多少陆军科技了,但却不能看到具体研究过哪些。这需要你有70%的陆军情报,但届时你就可以看到他们的科技树了。如果我再多有5%的陆军情报,我可以看到其他国家每个部队模板大约有多少军队。目前我只能看到它们存在,但部队模版实际内容是什么却是看不到的。

 

上周我们庆祝了钢铁雄心4的三周年庆典,并发布了1.7版本号九头蛇Hydra,以及电台音乐包Radio Pack和轴心国装甲包Axis Armor Pack。我希望你能喜欢它们。

The army intel tab also lets you get a breakdown of the enemy stockpile of equipment.

陆军情报选项卡还可以让你获得关于敌军装备库存量的细分信息。

 

After the weekend we looked at our telemetry data after 1.7 released and noticed that the amount of multiplayer out of syncs were more common than before. This indicates that we introduced a new OOS problem. While HOI4 has resync and hotjoin its still pretty annoying when you out of sync so we are currently investigating this for a small hotfix patch (1.7.1). Out of syncs can be really tricky to find and nail down so no definite ETA yet on when the patch is ready as we are still hunting. But we acquired a solid lead on the problem just yesterday, and we're currently working out a good solution.

在周末之后,我们查看了1.7版本号发布之后的遥测数据,并注意到多人游戏失去同步OOS(Out of Syncs)的情况比之前更为常见。这意味着我们又引入了一个新的失去同步问题。虽然钢铁雄心4具有再同步Resync和热加入Hotjoin功能,但你失去同步的时候仍然很烦人,所以我们正在研究这个小型热修复补丁(1.7.1版本号)。失去同步问题是很难查出并确定缘由的,因此我们不能敲定该补丁何时准备就绪,毕竟我们还在寻找问题所在。但在昨天我们刚刚在该问题上取得了坚实的进展,我们目前正在鼓捣一个很好的解决方案。

 

Naval and air are similar:

 

海军和空军的也类似:

Technical section(warning!): What is an Out of Sync?

钢铁雄心4开发日志 | 6/12 技术向总结其二钢铁雄心4开发日志 | 12/11 情报系统(图5)

技术环节(警告!):什么是失去同步?

钢铁雄心4开发日志 | 6/12 技术向总结其二钢铁雄心4开发日志 | 12/11 情报系统(图6)

For those interested what an out of sync is I figured I’d dig into it a bit. Feel free to skip this if you are a... normal human being, I guess.

我觉得应该为那些对“什么是失去同步”感兴趣的人做一点深入发掘。但俺寻思你要是个...正常人,请随意跳过这部分。

 

Naval intel mapmode is quite powerful and at high intel levels will let you see where the enemy is placing certain missions

海军情报地图模式的功能非常强大,在情报等级高的情况下,你甚至可以看到敌人正在哪里执行某些特定的任务。

钢铁雄心4开发日志 | 6/12 技术向总结其二钢铁雄心4开发日志 | 12/11 情报系统(图7)

有3个特遣舰队被派往该地区执行巡逻任务,目前有1个特遣舰队正在该地区积极执行任务。

An Out of Sync (OOS) happens when the host and clients in a multiplayer game start acting differently. This could for example be something like a battle ending in the favor of Germany on one of the computers and in the favor of Soviets on the other. Usually though its nothing that big as the state difference is usually spotted earlier at say one of those units having a 1% higher organization than the other or the like. Once it happens everyone’s experience will very quickly start diverging, so we stop and alert the players. At this point the host can click a ‘Resync’ button to bring the game back into sync. Resyncing will reset the state of the game, send the current host state over as a savegame and have everyone load that, and then things can resume.

Intel can come from many different sources, for example:

情报的获取有许多不同的来源,例如:

- Spy networks

当多人游戏中的主机端和联机端开始采取不同的行为时,失去同步OOS即会发生。举个栗子,可能会有一台电脑的战斗计算结果对德国有利,而另一台电脑则是苏联占优。不过一般情况下不会严重到这种国家之差的地步,通常也是很容易在早期便注意到的差别,例如某个单位比其他单位高1%的组织度之类。一旦出现失去同步便会导致每个玩家的体验立刻开始分化,所以我们会暂停游戏并提醒玩家。此时主机可以单击“重新同步Resync”按钮以使游戏恢复同步。重新同步将重置游戏状态,将当前主机状态作为游戏存档来分发并让每个玩家加载它,然后一切就可以继续进行。

 

- 间谍网络

- Infiltrated spy assets

- 被渗透的间谍线人

So what can cause an OOS? This is where it gets tricky, and its pretty much always a new reason when a problem appears. Some good candidates are multiplayer between different platforms because underlying code libraries can behave differently in some cases. Other common reasons are multithreading. We thread a lot of our code, yet to stay in sync we must assure that events still happen in the same order on all machines in the end if they affect the world. There can also be issues like touching illegal memory or the like that can alter the game state in unplanned ways (or crash… but those are easy to spot and fix!).

那什么可能会导致失去同步OOS呢?这就是这个问题变得棘手的地方,基本上每个出现的问题都有一个对应的新源头。一些好的可能原因是在不同平台间的多人游戏,因为底层代码库不同在某些情况下可能表现不同。其他常见原因是多线程。我们多线程执行许多代码,但为了保持同步,我们必须确保具有全局影响的事件仍会在所有电脑上以相同的顺序发生。还会有一些问题,比如接触非法内存,或其他可能以不在计划内的方式改变游戏状态的问题(或是崩溃...但那些算是比较容易定位和解决的问题!)。

 

- Captured enemy spies

Finding and fixing an OOS can be a long process simply because they are often quite rare occurances and it usually takes many steps and iteration to home in on exactly what it is. To find them we run multiplayer tests with QA with special settings that spit out giant log files (which makes everything horribly slow generally) and once and OOS happens we compare log files and savegames to see what differs. This will usually give us an area to start looking at. Lets say for example that you have a unit’s org being different. This could be due to many reasons - battle damage, weather, bad supply etc. So we add more logging to the relevant code areas and do another test. Hopefully this will tell us which of our guesses was right, and we repeat again with more logs and more details for this area. Of course the most fun-to-find OOS errors disappears when you add logging and framerate slows.

查找并修复一个失去同步OOS问题会是一个漫长的过程,单纯是因为它们很少发生,并且它一般会需要很多步骤和迭代来定位到它到底是由什么导致的。为了找到它们,我们和品控组运行多人游戏测试,并使用特殊设置吐出巨大的日志文件(使得一切都变得非常缓慢),一旦发生失去同步,我们会比较日志文件和游戏存档,看看有什么不同。这通常会给我们一个起始检阅的范围。举例来说,你有一个组织度不同的单位。这可能是由于各种原因造成的——战损,天气,补给不良等。因此我们在相关代码区域添加更多日志记录并进行另一次测试。希望这会告诉我们哪些猜测是正确的,我们将在这个范围再次重复更多日志和更多细节。当然,那些“找起来最有意思”的失去同步问题却会在你添加日志和慢速低帧运行时消失不见。

- 俘获的敌军间谍

 

- Radar

Some of this can be done automatically over night as well if the problem is unrelated to players, but this is often not the case.

- 雷达

如果问题与玩家无关,那么其中一些是可以在运行游戏中的一天后自动修复的,但通常情况并非如此。

Once found and fixed this is usually the stage we make an open beta patch to verify that it is indeed fixed, or if we deem it sure that we found the problem we will go straight to regular patch. Speaking of beta patches, thanks for the help testing 1.7! we got something like 30k game sessions of testing on the weekend before the final build which was a great help!

- Broken Ciphers

- 破译密码

- Scout planes

一旦找到并修复后,我们通常会在这个阶段制作一个公开测试版补丁,以验证它确实已经修复了,或者在对确信已发现问题源头时直接进入常规补丁阶段。说到测试补丁,感谢帮助测试1.7版本号的各位工具人!在最终完工之前的周末,我们得到了大约三万份游戏测试材料,这帮了很大的忙!

- 侦察机

- Fighting the enemy in land combat

 

- 陆战中与敌军作战

Hopefully this little look into some of the technicalities behind working on HOI4 was interesting. If you got questions feel free to ask away!

希望各位觉得这篇关于钢铁雄心4开发背后的一些技术细节的小介绍还是有点趣味。如果你有问题,尽管问吧!

- Fighting the enemy in air combat

 

- 空战中与敌军作战

- Fighting the enemy in naval combat

- 海战中与敌军作战

The part of the team that isn’t trying to solve this OOS has now moved fully on to 1.8 ‘Husky’ and next expansion work, but its early days and its going to be a while until we have things to show off. So this will be the last dev diary in a while as we go into radio silence (and soon glorious socialist swedish summer vacation!) until we have things that are ready to show off.

- And probably some I forgot.

- 可能还有一些我忘了。

Each source has a max it can contribute and may affect different intel values in different ways. For example if you have a spy network over the enemies coast, or scout naval areas with traffic you will get more naval intel. Each source also decays over time so its important to actively do things to keep your intel levels current and make sure you combine many sources to get as much intel as possible.

那些没有在尝试解决失去同步问题的开发团队成员,现在已经完全转移到1.8版本号“哈士奇Husky”和下一次扩展包的开发工作上去了,但现在还处于早期阶段,在我们有东西可以展示之前还需要一段时间。因此,当我们进入无线电静默(以及即将到来的光荣的瑞典社会主义暑假期间!)时,这将成为最后一篇开发日志,直到我们有准备展示的东西为止。

每个来源都有一个它可以贡献的最大值,并且可能以不同的方式影响不同的情报值。例如,如果你在敌军海岸处建立起了一个间谍网络,或者在有交通流量的海军区域进行侦察,你就会得到更多的海军情报。每个来源也会随着时间的推移而衰减,因此就需要积极采取措施来将情报级别维持在当前的水平,并确保尽可能地将多个来源组合起来以获得尽可能多的情报。

 

 

See you on the other side! And keep an eye on the forum for announcement about the 1.7.1 hotfix when that is ready.

Here I have multiple sources:

待到那时见!请关注论坛上的关于1.7.1版本号热修复补丁的公告,就绪后就会放出。

这里我列举了多种来源:

Andy Gainey: I'm the programmer who's been tackling this particular OOS, so I can add some further technical details, for those nerdy enough in just the right way to actual enjoy it.

钢铁雄心4开发日志 | 6/12 技术向总结其二钢铁雄心4开发日志 | 12/11 情报系统(图8)

Andy Gainey:我是一直在处理这个特定的失去同步问题的程序猿,所以我可以在此添加一些更深入的技术细节,让那些够怪癖的玩家们能以正确的方式享受这些内容。

During this round of OOS hunting, we've improved our sync debugging tools in multiple ways:

在本轮搜索失去同步问题的过程中,我们用多种方式改进了同步调试工具:

 

1.We've reworked the verbose logging system that we turn on when trying to catch an OOS in the act and figure out what the game was doing at the exact moment that the machines begin to diverge, but before any machine is aware of the divergence. Since we only care about the most recent data written to the log, we now just discard all the older data on a regular basis, and thereby avoid multiple gigabytes of logs. This allows us to be far more verbose with our logging, without fear of filling up our team's hard drives.

1、我们重新设计了在尝试捕捉失去同步问题时打开的详细日志系统,并在电脑开始偏离同步,但没有任何端口意识到自己偏离了同步时,弄清楚游戏正在做什么。由于我们只关心写入日志的最新数据,因此我们现在只是定期丢弃所有的旧数据,从而避免很多的几千兆字节的日志。这让我们能够更加详细地记录我们的日志,而不用担心会塞满团队的硬盘。

民用情报总数:8.0(上限为10.0)

 

2.We've streamlined the process for collecting logs and save files, so that when the team or QA get an OOS during a multiplayer session, each machine automatically zips up all the relevant files, so that it's easy for everyone to add their data to a bug report or send it directly to whichever programmer is currently leading the charge on the OOSattack.

事件:2.6(今天的变化:-0.04)(软上限:4硬上限:5)

2、我们简化了收集日志和保存文件的过程,这样当开发组或品控组在多人游戏期间出现失去同步问题时,每台电脑都会自动压缩所有相关文件,这样每个人都可以轻松地将数据添加到错误报告或直接发送给当前负责处理失去同步问题的程序员。

 

空中侦察:1.3(今天变化:0.29)(软上限:2硬上限:3)

目标修正:4.0

出口焦点:+2.0

3.We've increased the miscellaneous scattering of data from a variety systems that we track every game hour, so that there is a higher likelihood of noticing the OOS as quickly as possible. Many out of syncs will firs touch some tiny little piece of data that isn't frequently checked, and this slowly avalanches into more and more data getting out of sync. Once the game is finally aware that something is off between machines, so much data is different that it is almost impossible to identify what was the piece of data that went out of sync first. So the faster we spot an OOS, the better chance we have of understanding and fixing it.

3、我们增加了每个游戏时间内我们在各种系统内追踪的散落数据数量,以便尽快地注意到失去同步问题。许多的失去同步问题都会触及到一些不经常检查的小数据,这会慢慢地导致越来越多的数据失去同步。一旦游戏终于意识到各个电脑之间存在某些问题时,已经有很多数据差异导致几乎不可能确定首先失去同步的数据是什么。因此,我们发现失去同步问题的速度越快,我们就越有可能理解并修复它。

 

民主主义国家:+2.0

4.We're now able to include checks in our internal developer build of the game to validate that we avoid reading or writing data in one thread that is potentially being modified in another thread at the same time. This will run even in single player games, and will alert the programmer exactly at the moment that a piece of code did something naughty that could cause an OOS. It still requires that we scatter the checks around in relevant places, but as we get more coverage, we'll get more protection againsts neaky OOS risks.

Do note that the biggest chunk here is me doing some quick events with rewards of intel to cheat my way to quick screenshots. Also note that simply being democratic and having open trade laws make hiding the civilian part of your intel hard.

要留意的是这里最大部分的情报贡献够来源于我做的一些能够带来情报奖励的快速事件,这样的话我就能在截图的时候假装场面好看些啦。还要注意的是,仅仅是民主体制和开放贸易政策就会使得难隐藏民用情报信息变得更加困难。

 

Knowing what kind of build strategy, templates, tech and stockpile an enemy has can be very useful allowing you to counter and attack them in the best way possible, but there is also direct advantage from relative intel which replaces the crypto level comparison from before.

4、我们现在能够在游戏的内部开发版本中包含检测系统,以验证我们是否避开在同

了解敌人拥有什么样的建筑策略、模板、科技和库存非常有用,可以让你以尽可能最好的方式反击和攻击敌人,而且情报数值的对比还能带来直接优势,它取代了以前的加密等级对比。

钢铁雄心4开发日志 | 6/12 技术向总结其二钢铁雄心4开发日志 | 12/11 情报系统(图9)

软攻:95.4

基础值:97.7

修正至97.60%基于:

堡垒:-5.00%

经验:+25.00%

情报优势:+10.90%

地形:-35.70%

指挥官技能:+10.00%

进攻战术伤害:+5%

See you next week for more cool stuff, and don't forget to tune into twitch at 16:00CET where we will be showing of France for the first time (aka watch Daniel accidentally leak stuff).

下周带着更多酷酷的东西再和大家见面啦,不要忘了关注CET16:00的Twitch,我们将在那里第一次展示法国(又名“来看Daniel不小心泄漏游戏内容”)。

 

 

翻译:北安

校对:斯普特尼克 三等文官猹中堂

 

欢迎关注斗鱼主播小牧Phenix!

欢迎关注牧游社微信公众号和知乎专栏!微信公众号近期改版为信息流,欢迎置顶订阅不迷路,即时获得推送消息!

欢迎加入牧有汉化,致力于为玩家社群提供优质内容!翻译人员募集中!