SkepticalFox Posted March 5, 2018 Share Posted March 5, 2018 (edited) В WoT 1.0 CT добавили road_map.bin В enCore тесте производительности (также в WoT sandbox 1.0) он имел расширение xml дополню описание темы позже, а пока можете делиться соображениями по распаковке Edited March 6, 2018 by SkepticalFox 2 @ Quote Link to comment Short link Share on other sites More sharing options...
SkepticalFox Posted March 6, 2018 Author Share Posted March 6, 2018 (edited) from struct import unpack import zlib with open('road_map.bin', 'rb') as f: count = unpack('<I', f.read(4))[0] for i in range(count): size = unpack('<I', f.read(4))[0] data = f.read(size) assert data[:8] == b'\x00piz!\x90\xafB', data[:12] data = data[12:] unc_data = zlib.decompress(data) with open('road_map_unc_%d.bin' % i, 'wb') as fw: fw.write(unc_data) Первая попытка подойти к road_map.bin Edited March 6, 2018 by SkepticalFox 3 @ Quote Link to comment Short link Share on other sites More sharing options...
SkepticalFox Posted March 6, 2018 Author Share Posted March 6, 2018 (edited) bin-файлы, которые были получены скриптом выше имеют примерно такой формат(kaitai): meta: id: bin file-extension: bin endian: le seq: - id: decal_settings type: decal_settings - id: cnt type: u4 - id: testing type: test repeat: expr repeat-expr: cnt types: decal_settings: seq: - id: texture_am type: str encoding: ascii size: 256 - id: texture_nm type: str encoding: ascii size: 256 - id: texture_gmm type: str encoding: ascii size: 256 - id: skip size: 20 - id: unknown type: f4 - id: priority type: u1 - id: parallax_amplitude type: f4 - id: parallax_offset type: f4 test: seq: - id: wtf type: f4 repeat: expr repeat-expr: 29 Edited March 6, 2018 by SkepticalFox 2 @ Quote Link to comment Short link Share on other sites More sharing options...
SkepticalFox Posted March 7, 2018 Author Share Posted March 7, 2018 https://bitbucket.org/SkepticalFox/bigworld-blender-tools-wot-wowp-wows/src/9ea7ef9c19104f7cd626d64f070a4d6f32791b6c/road_map_bin/road_map_bin_utils.py?at=master&fileviewer=file-view-default Паковщик-распаковщик на питоне Пока не особо понятно, где это можно использовать =) 4 @ Quote Link to comment Short link Share on other sites More sharing options...
Pavel3333 Posted March 8, 2018 Share Posted March 8, 2018 17 часов назад, SkepticalFox сказал: Пока не особо понятно, где это можно использовать =) а с самого начала не понятно, что это и зачем ты это реверсишь объясни в двух словах хоть, что за файлик 1 @ Quote Link to comment Short link Share on other sites More sharing options...
SkepticalFox Posted March 8, 2018 Author Share Posted March 8, 2018 (edited) 5 hours ago, Pavel3333 said: объясни в двух словах хоть, что за файлик https://ru.wikipedia.org/wiki/Parallax_mapping я пока точно не уверен, но думаю, что благодаря нему на макс. настройках графики отображается реалистичная поверхность дорог (грязь, следы траков и прочее) в этом файле ссылки на текстуры и координаты дороги( и еще какие-то параметры ) Mud - грязь (англ.) Edited March 8, 2018 by SkepticalFox 1 @ Quote Link to comment Short link Share on other sites More sharing options...
Pavel3333 Posted March 8, 2018 Share Posted March 8, 2018 Прикольно, спасибо, плюсану. @ Quote Link to comment Short link Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.