Clausewitz engine 2 язык программирования

Содержание

Проблемы оптимизации Clausewitz

Здравствуйте, сегодня я хочу задеть такую животрепещущую тему, как оптимизация игрового движка Clausewitz Engine (Движок всех игр Paradox), я расскажу какие проблемы существуют.

Потоки

Итак, начнем с того что знают все. Движок не умеет работать с потоками и ядрами, на этом можно было бы закончить. В официальной группе Paradox была даже статья об этом (https://vk.com/@pdxint-stellaris-27082020), однако разработчики стремительно опровергают тезисы, высказанные в ней.

Многие мододелы не согласны, но мы согласимся с данным утверждением разработчиков. Действительно, потоки работают если ты играешь на Linux ОС, никаких проблем с оптимизацией не возникает.
Также игра умеет определять количество логических и физических ядер, и у всех имеется возможность ручного указания количество используемых потоков аргументом запуска -threads= (устанавливает верхний предел размера пула потоков, установка значения 1 — отключает). К сожалению, эффект прироста производительности при этом не наблюдается.

Единственное, о чём мы можем сказать — об абсолютной безграмотности авторов текста в данном вопросе, которые затем переходят на другую тему, почему-то, синхронизацию.

Ещё в 2003-м году была написана статья с описанием эффектов и преимуществ оптимизации через потоки — клик
Есть более интересная и новая статья — клик

Мы согласимся с данным утверждением и для потоков, и для мультиплеера ( который идет дальше):

Думаю, вы понимаете, что куда проще сразу разрабатывать систему с оглядкой на многопоточность, чем подстраивать под неё старую систему. Если не верите, то просто обратите внимание, сколько времени вы тратите на переделывание своих флотилий, я подожду.

Мультиплеер

Тут мы разделим на две причины:
1. Нет дедик-версии сервера для возможности играть без нагрузки на свой компьютер.

Проблема говорит сама за себя, это именно возможность запустить сервер HOI4 на VDS/Dedicate server, чтобы расчеты не накладывались на пк игрока-хостера. Плюс это гораздо надежнее, т.к интернет у хостинг-провайдеров гораздо лучше чем для обычного пользователя.

2. Синхронизация и алгоритмы при плохом интернет соединении.

Точнее его алгоритм работы синхронизации и решение рассинхронов. У Paradox это выглядит очень нелепо в плане синхронизации, т.к. исследуя как ведет игра при различных статусах интернета и возможности пропускной способности обнаружено, что сервер (или хост) будет замедлять у других для попытки синхронизации времени, хотя это очень губительно влияет на остальных игроков, иногда это может привести обратному эффекту, когда из-за замедления игры может произойти так, что на сервере будет получена критическая ошибка из-за неверного просчета из-за замедления.
При этом, каждый игрок используется в качестве сервера и все данные передаются друг другу, а значит, что в случае краша у одного, это может вызвать краш у всей цепи. За примером далеко идти не надо, старая хойка и Виктория 2 страдают данной проблемой.

Мы думаем, что стоит перенять опыт от … Factorio! Эта игра пример, где происходит гораздо больше вычислений, чем в HOI4, т.к. все имеет очень много параметров, но при этом в МП является очень оптимизированной и шустрой.

1 миллион 113 тысяч сущностей, которые обновляются 60 раз в секунду. Каждая из этих сущностей имеет свою логику. И самое главное — оно совершенно не тормозит. Игра обрабатывает миллионы объектов (а у некоторых людей и миллиарды) каждые 16 мс и при этом она играбельная.

Если вы захотите прочитать как работает мегапакет в Factorio — есть отдельная статья на хабре

Сохранения

Перейдём к проблеме сохранений, даже в оригинальной игре сохранения создают определённое провисание на несколько секунд, особенно сильно подобное чувствуется в масштабных модификаций, например нашей.
Обратим внимание, что Paradox обещают улучшить процесс сохранений, мы действительно видим качественное улучшение системы сохранений по сравнению с 1.5 версией.
Корень проблемы мы сможем увидеть в самих сохранений, если отключим бинарный формат настройкой save_as_binary=no

При ручном сохранении сразу бросается в глаза гигантский вес сохранения — 36мб при бинарном формате, 59мб без него.

Итак, перейдём к рассмотрению файла.

Игра сохраняет каждую пустую провинцию. Мы видим максимально нерациональное использование мощностей. Почему бы не записывать провинциям значение null по умолчанию, а сохранять исключительно те, что были изменены? В данных строках сохраняются все постройки и значение «очков победы», но зачем сохранять даже пустое значение?

Читайте также:  Виды норм современного русского языка

А теперь перейдём к более интересным находкам.

Игра сохраняет каждую технологию для каждой страны. Казалось бы правильно, однако куда рациональнее было бы единожды вводить тэг технологии и вносить все страны, которые её изучили. Сейчас же игра создаёт по блоку для каждой технологии каждой страны, это щитпост на миллионы строк. В нашем моде 360 стран, а значит 9 строк будет дублироваться каждой страной.

Подобные строки мы даже не будем комментировать.

Поэтому мы надеемся, что Paradox исправит данные недоразумения и сделает вес файлов сохранений еще меньше, а пока что сейвы являются большим больным местом, где явно можно было сделать сразу лучше.

Моддинг

А точнее, его формат. В моддинге отсутствует компиляция, как подсказывает Википедия, компиляция — это «трансляция программы, составленной на исходном языке высокого уровня, в эквивалентную программу на низкоуровневом языке, близком машинному коду (абсолютный код, объектный модуль, иногда на язык ассемблера), выполняемая компилятором». Все мододелы пишут на высокоуровневом языке, однако PDX в реальном времени преобразуют код в набор команд и выделяемое ОЗУ это подтверждает. На момент запуска диспетчер задач выделяет HOI необходимое количество ОЗУ, в нашей модификации запрос составляет свыше двух гигабайт.

Обычно, именно так и выглядит процесс работы, однако, если мы скомпилируем код, то процесс изрядно сократится.

Это фича позволяющая упростить работу, но в это-же время это убивает оптимизацию.

Решения!

Кажется, это очень хороший и удобный инструмент, не требующих особых затрат от художников, и огромный простор для работы скриптера. Однако, тут все не так просто.
Решения проверяются дважды в игровой час для каждой доступной страны, таким образом создается гигантская нагрузка. Радует, что существуют способы ограничения проверок и свести их к минимуму.

Переполнение пула

Скажите, вы встречались с тем что у вас число населения, или ресурсов, или ещё чего уходило в минус, хотя мгновение назад было с запасом? Думаю часто.

Это очень частая напасть, и она встречается во всех играх PDX. Помните Ганди из цивилизации? Абсолютно тот же тип проблемы.

Частично, Paradox это поправили — частично, но у скриптеров с этим проблемы никуда не делись. И ничто не предвещает того, что что-то изменится. Данной проблеме больше шести лет.
У населения, это 2.100 миллиарда, у техники это 2.7 миллиона. В случае, если ваши скрипты считывают население, или, считывают иной тип переменной, вы имеете очень большие шансы об это пострадать.

Почему это так страшно?
Чем больше алгоритмы натыкаются на подобные места, тем больше проблем это может вызвать, вплоть до просадок FPS. Простой краш будет самым лучшим исходом.

DirectX9

Страшно подумать, но HOI4 по сей день не умеет в более новый DirectX, а в новый DirectX по традиции, завозят хорошие инструменты по оптимизации, притом, с возможностями улучшить картинку без какого-либо вреда для оптимизации.
Командой rendertype в консоли игры можно узнать тип рендера.

Вывод:

К сожалению, движок хойки как и все игры Парадоксов на нём дико устарели и находятся на этапе 2003-о года и 2010-о года.

Мы не учитывали мелочи, сродни неиспользованных битов в bool типах, подобные масштабы в современности не играют никакой роли.

Скриптерам
Конечно, вы можете заморочиться и попытаться решать проблемы начала нулевых, базируясь на уменьшении проверок, урезании контента, и, ограничение всех операций ввода/вывода.
Это, может быть даст результат, в лучшем случае прирост на несколько процентов. Однако, проблема изначально не в вас. Исправив свои ошибки, Paradox смогут увеличить прирост в разы и сделать свои игры лучше. За это скажут спасибо и коммьюнити, и мододелы.

Источник

Clausewitz engine 2 язык программирования

Hearts of Iron IV

Is it possbile to download the engine itself to make a game? If not, what other engine is good for making a strategy game HOI 4 style?

I think you’d have to license the Clausewitz engine, since it’s owned by Paradox, but Unreal or unity would suffice

Is it possbile to download the engine itself to make a game? If not, what other engine is good for making a strategy game HOI 4 style?

If by «donwload» you mean «purchase at full price» then yeah, you can totally «download it and make a game with it».

Any engine if you are crafty enough, really.
Unreal is the most oblivious choice though. From what I know Unity doesn’t handle a large quantity of game objects that well.

Any engine if you are crafty enough, really.
Unreal is the most oblivious choice though. From what I know Unity doesn’t handle a large quantity of game objects that well.

So your suggesting using the Unreal Engine, not unity?

Источник

Clausewitz Engine

Clausewitz Engine

Paradox Development Studio | Released 2007

Originally developed for Europa Universalis III, it has been used in every game developed by Paradox Development Studio since. The engine provides a 3D view of part or the totality of the world map, depending on the played game. In 2012 it was announced that Europa Universalis IV will be the first game utilizing the Clausewitz 2.5 engine.

Paradox To Host Mod Teams At PDXCON 2017

In a press release issued today, grand strategy game developer and publisher Paradox announced that, for the first time, it would be hosting mod teams at its convention – PDXCON 2017. Held at Gamla Riksarkivet in Stockholm, Sweden, on May 13-14 this year, PDXCON is a celebration of the company’s current and upcoming deep and complex grand strategy titles.

This year, the two mod teams that will be in attendance are the folks behind the Kaiserreich mod for Hearts of Iron IV and the MEIOU and Taxes mod for Europa Universalis IV.

Paradox describes how the mod teams will be positioned within PDXCON 2017:

“Attendees to PDXCON 2017 will have a chance to meet with some real veterans of the Grand Strategy modding scene, with both group’s work having been present in some form or another since the very beginning. Not only will visitors be able to talk to the creators and play-test the mods at dedicated booth space during PDXCON, but there will also be seminars hosted by both teams.”

Paradox’s CEO, Fredrik Wester, commented on the inclusion of modders for the first time, saying:

“Replayability has always been a critical factor when deciding which games we release, as such we have fans which have invested thousands of hours into just the base versions of our games alone! Mod creators through their dedication are then able to create yet even more content for our fans to enjoy, we are very happy that our games can provide a baseline for such creativity!”

Standard PDXCON tickets are, for the first time, open to the general public, and can be purchased for US$100. Tickets grant attendees access to the convention’s seminars, panels, playable game builds, and meet and greets with Paradox developers.

Читайте также:  Встроенные стандартные функции языка

HoI IV expansion Together for Victory to land soon

History forged the ties. Empire made them tighter. Can war tear them apart?

Dan and Jakob shows you how to mod Hearts of Iron IV & Discover whats in the «Secret DLC».

UPDATE: Stellaris Giveaway

Paradox’s most mod-friendly game to date & Full Conversion Mods Made Possible for older titles!

Europa Universalis IV: Cossacks

The awesomely moddable Grand Strategy gets its 6th expansion with new mechanics and features.

Post article | More articles >>

No articles were found matching the criteria specified. We suggest you try the article list with no filter applied, to browse all available. Post article and help us achieve our mission of showcasing the best content from all developers. Join now to share your own content, we welcome creators and consumers alike and look forward to your comments.

Crusader Kings III

Prepare yourself to secure the throne. Crusader Kings III is the latest in Paradox Development Studio’s beloved grand strategy games lineage. Whether.

Victoria II

Carefully guide your nation from the era of absolute monarchies in the early 19th century, through expansion and colonization, to finally become a truly.

Crusader Kings II

Europe is in turmoil. The lands are fragmented into petty fiefs, the emperor struggles with the Pope, and the Holy Father declares that all those who.

Hearts of Iron IV

The ultimate WWII strategy game From the heart of the battlefield to the command center, you will guide your nation to glory and wage war, negotiate or.

Europa Universalis IV

Gives you control of a nation to guide it through the years of early Colonialism and create a dominant global empire and will provide you unprecedented.

Hearts of Iron III: Their Finest Hour

Victory at all costs. It’s time to take command and lead your nation through World War II, the largest conflict in world history. Hearts of Iron III.

Victoria II: A House Divided

Carefully guide your nation from the era of absolute monarchies in the early 19th century, through expansion and colonization, to finally become a truly.

Rise to power in Feudal Japan with your Samurai family in the epic Grand Strategy Sengoku. In this deep character driven strategy game, you play as the.

Europa Universalis III: Divine Wind

At the demand of the devout fanbase, this is the 4th expansion of the classic historical strategy game Europa Universalis III. Enhancing every aspect.

Europa Universalis III

Europa Universalis III delves deeply into the areas of exploration, trade, warfare and diplomacy. This epic strategy game lets players take control of.

Add game | More games >>

No games were found matching the criteria specified. We suggest you try the game list with no filter applied, to browse all available. Add game and help us achieve our mission of showcasing the best content from all developers. Join now to share your own content, we welcome creators and consumers alike and look forward to your comments.

Источник

Clausewitz Engine

Paradox Development Studio | Released 2007

Originally developed for Europa Universalis III, it has been used in every game developed by Paradox Development Studio since. The engine provides a 3D view of part or the totality of the world map, depending on the played game. In 2012 it was announced that Europa Universalis IV will be the first game utilizing the Clausewitz 2.5 engine.

This Week In Mods: April 6 2018

The biggest mod stories for the week of April 6 2018.

this week in mods: april 6 2018

Paradox To Host Mod Teams At PDXCON 2017

Hearts of Iron IV and Europa Universalis IV modders will be in attendance.

paradox to host mod teams at pdxcon 2017

HoI IV expansion Together for Victory to land soon

History forged the ties. Empire made them tighter. Can war tear them apart?

hoi iv expansion together for victory to land soon

Dan and Jakob shows you how to mod Hearts of Iron IV & Discover whats in the «Secret DLC».

UPDATE: Stellaris Giveaway

Paradox’s most mod-friendly game to date & Full Conversion Mods Made Possible for older titles!

update: stellaris giveaway

Europa Universalis IV: Cossacks

The awesomely moddable Grand Strategy gets its 6th expansion with new mechanics and features.

europa universalis iv: cossacks

The Alaska Bundle

5 great Indie games never bundled before including Electronic Super Joy and March of the Eagles.

Europa Universalis III: Chronicles Released on Desura

Take control of a nation and guide it through the ages to become a dominant global empire.

europa universalis iii: chronicles released on desura

Rise to power in Feudal Japan with your Samurai family in the epic Grand Strategy Sengoku. In this deep character driven strategy game, you play as the.

Paradox Catalogue on sale now!

The annual Paradox Catalogue sale has rolled around once more for 2011!

Читайте также:  Английский язык выбери нужное прилагательное

paradox catalogue on sale now!

Hearts of Iron III on Desura

Hearts of Iron III lets you play the most engaging conflict in world history, World War 2, on all fronts as any country and through multiple different.

hearts of iron iii on desura

Europa Universalis III on Desura

Europa Universalis III delves deeply into the areas of exploration, trade, warfare and diplomacy.

europa universalis iii on desura

No articles were found matching the criteria specified. We suggest you try the article list with no filter applied, to browse all available. Post article and help us achieve our mission of showcasing the best content from all developers. Join now to share your own content, we welcome creators and consumers alike and look forward to your comments.

Источник

Clausewitz Engine

Paradox Development Studio | Released 2007

Originally developed for Europa Universalis III, it has been used in every game developed by Paradox Development Studio since. The engine provides a 3D view of part or the totality of the world map, depending on the played game. In 2012 it was announced that Europa Universalis IV will be the first game utilizing the Clausewitz 2.5 engine.

Milić mod: Destroy Holdings

To install extract zip file into your mod folder.(Documents/ParadoxInteractive/Crusader Kings II/Mod) With this Mod you will unlock option for destroying.

In the Name of the Tsar Official Mod Download Page

Steam version of the INOT mod. Beware this page is not yet ready, more description and info will be added eventually. If issues occur please contact our.

Strangereal World map source art/asset for Hearts of Iron 4 map generator tool.

The untimely death of Franklin Delano Roosevelt on December 1944 marked the beginning of a grim chapter in the history of mankind. As the Second World.

Dungeon Master (Updated 28/08!)

Meet the Dungeon Master, a cruel benevolent and sadistic peaceful character who will be sure to liven up your Crusader Kings II experience! But what exactly.

Beginning of the End: A 15th Century Mod

Initial release. Includes history for half the map, plus preliminary Renaissance content.

TSK Dragon Engine for Vanilla CK2

Have you ever wanted to unleash dragonfire upon Europe but realized that you could never get it done? Fear not, through the power of cannibalizing and.

AGOT [FIXED] Faces Modification for 2.2

For melius/meljar’s mod this is a patch which makes it compatible with AGOT 2.2

Historical Immersion Event Pack For Beautiful States Reborn

This mod make Historical Immersion Event Pack compatible with Beautiful State Reborn

ViconomicNGTR (NoGoldTaxRefund)

Addresses Victoria’s late game economic liquidity problem for Vanilla. Code from NGTR-HPMpatch by Bearhobag of Reddit Originally presented as an economic.

HFM master

HFM with more content such as anglo irish, british african, scot irish, welsh irish and more to come

Ultimate Cheat Mod Improved

A perfect cheat mod for those who wish to make their life easier and have fun in HOI4.

Sound King

Sound replacement mod for Crusader Kings 2. No DLC required. Sounds from iconic Heroes strategy game.

CK2 Bloodlines, Sketchy Cheat submod

If you’ve ever wanted to add or remove bloodlines from your character at will, this is the mod for you. made to work alongside the Sketchy Cheat menu.

AGOT: George R. R. Martin Overhaul

RP Mod

RP Mod Ce mod vise à ajouter du contenu pour le RP entre les joueurs, Il sera mis à jour et du contenu sera ajouté si nécessaire.

Send Prisoner Hide

Version Cacher = Masquer le bouton quand aucun prisonnier n’est disponible. Send Prisoner Ce mod vous permet de demander et donner des prisonniers. Vous.

Salazar’s Portrait of La Resistance 1.1

Salazar’s Portrait of La Resistance is the portrait the new Portrait of António de Oliveira Salazar for La Resistance DLC

Events

(Disclaimer this mod is still not complete so expect it to be boring/bad and buggy mod) This mod add events (that’s it. ) Germany is the only country.

AI Assistant

AI Assistant Ce mod vous permet d’avoir un assistant AI qui vous aide en exécutant à l’arrière-plan certaines affaires et tâches dans votre domaine.

Send Courtier

Send Courtier Ce mod vous permet d’envoyer vos courtisans. (clic droit sur le portrait)

Roll’s Personality Driven Education and Focus Revamp Roleplaying Mod (PDEAFRRM)

Roll’s Community Traits Mod Max Compatibility

Featuring 35 new inheritable and lifestyle traits, with some offering unique gameplay. Even rarer, heightened forms of Genius and Strong. Once-in-a-playthrough.

Rolls Community Traits Mod AGOT

35 new inheritable and lifestyle traits, with some offering unique gameplay. Even rarer heightened forms of Genius and Strong. Once-in-a-playthrough random.

Blood Elf Society

Суб мод для моды варкрафта к CK2. Делалось для эльфов.

Half Life 3 Soundtrack Replacement + bonuses

Replaces the music and some other tidbits in HOI3, TFH

Trade Improve

Trade Improve Ce mod a pour but de reproduire les routes commerciales historique Européenne et Scandinave toute en gardant un équilibre dans le jeu.

Send Prisoner

Send Prisoner Ce mod vous permet de demander et donner des prisonniers. Vous pouvez également envoyer plusieurs prisonniers en une fois.

Plotting To Kill Your Kids

Plotting To Kill Your Kids Ce mod vous permet de comploter pour tuer vos enfants.

Castrate and Blind

Castrate and Blind Permet à tous les dirigeants cruels de castrer et d’aveugler les prisonniers.

No files were found matching the criteria specified. We suggest you try the file list with no filter applied, to browse all available. Add file and help us achieve our mission of showcasing the best content from all developers. Join now to share your own content, we welcome creators and consumers alike and look forward to your comments.

Источник

Поделиться с друзьями
Расскажем обо всем понемногу
Adblock
detector